./configure: no acceptable C compiler found in $PATH

I am a recovering Windows user (and linux newbie) trying to install and compile pgAdmin3 for postgresql on open SuSE 11.3, I get “no acceptable C compiler found in $PATH”

I have used yast to install botth gnu45 (c compiler) gnu45-c++ compiler.

My question: where did they install?

When I run rpm -ga >aplist.txt and search it for ‘gcc’ I find:
gcc45-c+±4.5.0_20100604-1.12.i586
libgcc45-4.5.0_20100604-1.12.i586
gcc45-4.5.0_20100604-1.12.i586
libstlport_gcc4-4.6.2-6.1.i586

So it seems something installed. But where is it so I can add it to the path?
And if I think I have located a likely subdirectory, how do I tell if it is the one? Is there a characteristic compiler file I would find in the correct directory?

There is a file named gcc-4.5 under /usr/bin, but /usr/bin is in the path, do I need to do something to tell ‘configure’ the name of the c compiler?

Thanks in advance for any help. Fred

welcome new poster!

it should automatically go to the “right place” and therefore
automatically be in the path and usuable–if you used YaST, and you
said you did…

so, i can only guess that you didn’t get all the bits and pieces
needed for your effort…

try this: open yast, go Software > Software Repositories and make sure
you have enable ONLY four repos: oss, non-oss, update and
packman…just disable the others…and, mark those four for auto-update

then, go to Software > Software Management and spin the “Filter” from
“Search” to “Patterns”, scroll down to the “Development” section and
single left click (to place a check mark in the box–if, it is already
checked do NOT uncheck it) in:

Base Development
C/C++ Development

and what others you KNOW you need (maybe not any…don’t load yourself
down with junk you will never use…unless you want to)…

but, let me ask why do you want to compile it yourself? that is, it is
already available…go to http://software.opensuse.org/search enter
“pgAdmin3” and spin the dial to match your version…then carefully
pick the one you need and click on the “1-Click Install” link…it
should just install…WARNING most of those “1-Click Install”
should ask you if you want to leave the repos added to your system,
my best advice is to say NO…my best advice is (until you understand
how it all works) to keep just the previously mention FOUR repos
enabled…these fora are just packed with folks having all kinds of
problems AND 10, 15, 20 or more repos all enabled all the time…

good luck, and Have a lot of fun!


DenverD
CAVEAT: http://is.gd/bpoMD [posted via NNTP w/openSUSE 10.3]

When I run rpm -ga >aplist.txt and search it for ‘gcc’ I find:
gcc45-c+±4.5.0_20100604-1.12.i586
libgcc45-4.5.0_20100604-1.12.i586
gcc45-4.5.0_20100604-1.12.i586
libstlport_gcc4-4.6.2-6.1.i586

=>

su -c "zypper install gcc"

Reason:

Most “configure”-scripts search for “cc” or “gcc” in $PATH, none of the above packages contains that file (which is only a symlink but there for exactly this reason).

BTW:

Easier way to search for installed packages containing $STRING in their name:


rpm -qa "*STRING*"

so in this case

rpm -qa "*gcc*"

Hello,
I was advised elsewhere in these Forums for a different situation to add GCC43 compilers, it was good advice. Apparently there’s alot of code out there that hasn’t upgraded compilers.

Re compiling from source instead of using the SuSE RPM, currently the SuSE RPMs don’t have the latest version of PostgreSQL, and the latest has some significant new features as well as bundling the latest version of pgAdmin.

HTH,
Tony

HTH,
Tony

tsu2 wrote:

>
> Re compiling from source instead of using the SuSE RPM, currently the
> SuSE RPMs don’t have the latest version of PostgreSQL, and the latest
> has some significant new features as well as bundling the latest version
> of pgAdmin.
>
Did you also look at the opensuse build service, the
server:database:postgresql:9.0 has newer packgaes than the standard
repositories?
http://download.opensuse.org/repositories/server:/database:/postgresql:/9.0/openSUSE_11.3


openSUSE 11.3 64 bit | Intel Core2 Quad Q8300@2.50GHz | KDE 4.5 | GeForce
9600 GT | 4GB Ram
openSUSE 11.3 64 bit | Intel Core2 Duo T9300@2.50GHz | KDE 4.5 | Quadro FX
3600M | 4GB Ram

Hello,
Would probably be nice if there was an easy and quick way to search the Repository and get a positive hit.

Did a search on the OSB for “postgresql 9” and “postgresql reinhard” (According to the PostgreSQL website, Reinhard is supposed to be the official maintainer) which return nothing (The search appears to have correctly guessed that v.9 was requested).

Searching just “postgresql” returns numerous projects, I’d hate to go through all of them on the chance maybe (or maybe not) the latest version is available.

v9.0.1 was released 10/4/2010

Tony

Sorry my message wasn’t deleted… I missed the ready OBS link provided in the previous post by Martin…
As of this writing only a minor update was released approximately 3 weeks after the version in OBS (latest version as of this writing is v9.0.1)

Tony

installing gcc 4.3 is very good advice
most programs that i build from source need to be hacked to use 4.5 beta
most of the time it is just a very minor one or two line hack .
i also have 3.4 installed and use a neat trick ( not the" alternatives " way )
a small script to change the LINK gcc to point it to 4.5 or 4.3 or 3.4
set_compiler_4.5.sh


#!/bin/bash
rm /usr/bin/cpp
ln -s /usr/bin/cpp-4.5 /usr/bin/cpp
echo ln -s cpp-4.5 cpp
rm /usr/bin/gcc
ln -s /usr/bin/gcc-4.5 /usr/bin/gcc
echo ln -s gcc-4.5 gcc
rm /usr/bin/g++
ln -s /usr/bin/g++-4.5 /usr/bin/g++
echo ln -s g++-4.5 g++

one for each compiler 3.3,4.1,4.3,and 4.5
** WARNING - make sure you know 100% what you are doing first BEFORE using that script
and that /usr/bin/gcc IS A LINK **

Wow, what a great series of replies!
As a newbie to the Unix/GNU/Linux world I can tell you it looks huge, so any help like “Look over there—>” is greatly appreciated.

So, responding to the link in the first reply, I fired up my I.E. in windows, browsed to the site indicated, downloaded the file, then realized “Oops! Bad Fred!”, returned to my Linux instance, fired up Firefox, browsed to the site, downloaded the file, choose ‘install’ and proceeded like Windows was a thing of the past. And it worked!
However, I have a bone to pick with ‘automatically go to the right place’. If it doesn’t work ‘automatically’ you are hosed unless you know what exactly happens ‘automatically’, and learning that has been the biggest challange of Linux.

As for the compile, I see getting that to work as part of my education, so the rest of the posts that discuss this problem will be carefully inspected and suggestions followed as I learn more about how this thing you call ‘Linux’ works.

but in the meantime I can proceed and use pgadmin now thanks to your great help.

Fred

fredrated wrote:
> If it doesn’t work ‘automatically’ you are hosed unless you
> know what exactly happens ‘automatically’, and learning that has been
> the biggest challange of Linux.

i’ve used linux since about 97/8 and nothing else since about 2002 and
i am a long way from knowing how to sort out “it didn’t work
automatically”, but background, generic linux file system knowledge
will go a LONG way toward understanding such…and, a great place
(imHo) to get a foundation in that is here:

“Rute User’s Tutorial and Exposition” a free, online book that is to
be studied front to back, and THEN used as a reference…front to
back because it builds on what you learn as you go…start here:
http://rute.2038bug.com/

and, an old post of mine for folks like you is here:
http://tinyurl.com/3a5rong

unfortunately ‘they’ upgraded both the wiki and the forum since i
wrote that so some of the links are broken and directions are off…


DenverD
CAVEAT: http://is.gd/bpoMD [posted via NNTP w/openSUSE 10.3]

that rute book is good . A bit old but the basics have not changed
a bit newer ,and about the terminal only
Bash Guide for Beginners
these are good
Linux Online - Linux Courses

as for installing things
from experience i would stick with installing rpm’s and “prebuilt” programs for the BASE operation system

and get experience building programs with , say, some games
here is a fun one
Word War vi
and read the
wordwarvi-0.26/wordwarvi_hacking.html
and read the file README
that is in the source folder
but it also builds just fine on opensuse 11.3 64 bit
HOWEVER installing – that is a bit different –
some work on your part on figuring out how to get the sound to work
" make install" installs but NO sound ( sound dose work - but it is fun to figure it out )

things like this i think of as " a challenge " and a puzzle to solve

Sorry for changing the subject but I have a similar problem with gcc.

11.2 comes with 2.6.31 kernel and gcc44 by default, in this case; vmware installs just fine.
After updating the kernel (2.6.36) from :HEAD repo, everything works except vmware, seems it requires a newer gcc.
I wouldn’t bother with a factory kernel but 2.6.36 is marked “stable” so I thought update wouldn’t be a problem.

Got a few questions about it:

Is there a 11.2 repo where I could get gcc that’s compatible with 2.6.36 kernel? Can’t find it on webpin.
Is it safe to install it in 11.2 or there is something that explicitly depends on gcc44?
Is it possible to have both 44 and 45 installed at the same time?

@finders,

104 views and no one answered!

you are gonna have a lot better luck at attracting someone who knows
something about gcc 44/45 on 11.2 if you ask in a new thread with a
descriptive subject…as far as i can see you have no question
needing someone who would look in on “./configure: no acceptable C
compiler found in $PATH” as i did to find a very slightly related
question i can’t help at all with so . . .


DenverD
CAVEAT: http://is.gd/bpoMD [posted via NNTP w/openSUSE 10.3]

finders wrote:

> Got a few questions about it:
>
> Is there a 11.2 repo where I could get gcc that’s compatible with
> 2.6.36 kernel? Can’t find it on webpin.
> Is it safe to install it in 11.2 or there is something that explicitly
> depends on gcc44?
> Is it possible to have both 44 and 45 installed at the same time?
>
You can have a 4.5 gcc on 11.2 by using this repository
http://download.opensuse.org/repositories/devel:/gcc/openSUSE_11.2

It is possible to have multiple versions of gcc (and the other compilers of
the gnu compiler collection) in parallel on your opensuse.
If you need then a special compiler for a special software to
install/compile you have of course to look into the documentation what
special switches you have to set that said software or configure script
finds exactly th correct version you need for it.

The default compiler for the system can be set with update-alternatives (but
I never change it that way, I just set the variables for the configure
script I run so that it uses a different compiler during the compile
process).


openSUSE 11.3 64 bit | Intel Core2 Quad Q8300@2.50GHz | KDE 4.5 | GeForce
9600 GT | 4GB Ram
openSUSE 11.3 64 bit | Intel Core2 Duo T9300@2.50GHz | KDE 4.5 | Quadro FX
3600M | 4GB Ram

Thank you for this information sir Martin, very helpful.
Will try the repo this weekend, before my workstation 7 trial runs out.
I sure hope it’ll run on this new kernel.
Once again, sorry for changing the subject.