can't install g++ so I can't compile and install any programs
I'm trying to install Python 2.4.1 on Fedora 4 linux. I downloaded and unzipped the files. I then tried to ./configure, but there was a problem with the gcc. I configured the gcc, but now when I type ./configure, I get this message
[benjamin@dhcppc0 Python-2.4.1]$ ./configure checking MACHDEP... linux2 checking EXTRAPLATDIR... checking for --without-gcc... no checking for --with-cxx=<compiler>... no checking for c++... no checking for g++... no checking for gcc... gcc checking for C++ compiler default output file name... configure: error: C++ compiler cannot create executables See `config.log' for more details. It appears my problem is I don't have c++ or g++. Is that my only issue? If so, how do I install these two compilers? Any help is appreciated, as I'm new to this. |
print the output of config.log lst 10 lines should be fine. :)
|
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake. It was created by python configure 2.4, which was generated by GNU Autoconf 2.59. Invocation command line was $ ./configure ## --------- ## ## Platform. ## ## --------- ## hostname = dhcppc0 uname -m = i686 uname -r = 2.6.11-1.1369_FC4 uname -s = Linux uname -v = #1 Thu Jun 2 22:55:56 EDT 2005 /usr/bin/uname -p = unknown /bin/uname -X = unknown /bin/arch = i686 /usr/bin/arch -k = unknown /usr/convex/getsysinfo = unknown hostinfo = unknown /bin/machine = unknown /usr/bin/oslevel = unknown /bin/universe = unknown PATH: /usr/kerberos/bin PATH: /usr/local/bin PATH: /usr/bin PATH: /bin PATH: /usr/X11R6/bin PATH: /home/benjamin/bin ## ----------- ## ## Core tests. ## ## ----------- ## configure:1444: checking MACHDEP configure:1578: result: linux2 configure:1584: checking EXTRAPLATDIR configure:1599: result: configure:1618: checking for --without-gcc configure:1667: result: no configure:1673: checking for --with-cxx=<compiler> configure:1694: result: no configure:1713: checking for c++ configure:1742: result: no configure:1713: checking for g++ configure:1742: result: no configure:1713: checking for gcc configure:1729: found /usr/bin/gcc configure:1739: result: gcc configure:1779: checking for C++ compiler default output file name configure:1782: gcc conftest.cc >&5 gcc: installation problem, cannot exec 'cc1plus': No such file or directory configure:1785: $? = 1 configure: failed program was: If you need more I can email it to you. Thanks for your help! |
do a:
"which gcc" if it returns a path then check that the path is in your path: "echo $PATH" if not add it "PATH=$PATH:/usr/bin/gcc" Try running ./configure again if which doesnt return anyting do a find to check it is on the system "find / -name gcc" might take a while if it returns nothing then you need to install it, howerver it is unlikley that you dont have gcc every distro iv'e used comes with it, unless you built your own and in that case you would have struggled to compile progs. if you do find it add a soft link to /usr/bin "ln -s /wherever/it/is/gcc /usr/bin/gcc" The run configure agian. if your still having probs let me know :) |
Okay, here's what happened. gcc wasn't in my path. I added it, but ./configure still won't run. Look at this:
[benjamin@dhcppc0 Python-2.4.1]$ which gcc /usr/bin/gcc [benjamin@dhcppc0 Python-2.4.1]$ ./configure checking MACHDEP... linux2 checking EXTRAPLATDIR... checking for --without-gcc... no checking for --with-cxx=<compiler>... no checking for c++... no checking for g++... no checking for gcc... gcc checking for C++ compiler default output file name... configure: error: C++ compiler cannot create executables See `config.log' for more details. Here's the latest log configure:1444: checking MACHDEP configure:1578: result: linux2 configure:1584: checking EXTRAPLATDIR configure:1599: result: configure:1618: checking for --without-gcc configure:1667: result: no configure:1673: checking for --with-cxx=<compiler> configure:1694: result: no configure:1713: checking for c++ configure:1742: result: no configure:1713: checking for g++ configure:1742: result: no configure:1713: checking for gcc configure:1729: found /usr/bin/gcc configure:1739: result: gcc configure:1779: checking for C++ compiler default output file name configure:1782: gcc conftest.cc >&5 gcc: installation problem, cannot exec 'cc1plus': Not a directory configure:1785: $? = 1 configure: failed program was: |
Fixed it. Just logged in as root and typed
#yum install gcc-c++ Thanks for all the help! |
How about just using the FC4 python packages?
|
I have the same problem, but with RedHat 9.0
the error message is the same as well the "yum install" code does not work |
What happens when you type "gcc" in the terminal?
|
Quote:
|
g++ help
Hi,
I have a similar problem. I can't install, by manual, programs with the command "./configure". My System is Ubuntu 7.10 Gutsy Gibbon. xxx@xxx-desktop:~/Spiele/OTTD-source-nightly-r11814$ ./configure checking awk... awk checking build system type... i486-linux-gnu checking host system type... i486-linux-gnu detecting OS... UNIX checking universal build... no checking build cc... gcc checking host cc... gcc checking build c++... g++ not found I couldn't detect any g++ binary on your system please define the CC/CXX environment to where it is located xxx@xxx-desktop:~/Spiele/OTTD-source-nightly-r11814$ I tryied to install g++, but I can't: It want even more packages. The last is libc6-dev but this needs libc6 (= 2.6.1-1ubuntu9). My system wants to install 2.6.1-1ubuntu10. So I can't install it. Has anyone an idee what's going on??? |
Quote:
|
Re: configure fails to find g++.
Quote:
|
All times are GMT -5. The time now is 03:04 PM. |