Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
07-04-2004, 10:58 AM
|
#1
|
LQ Newbie
Registered: Jul 2004
Posts: 5
Rep:
|
Need help! error: C compiler cannot create executables
i want to install gtk+2.4.3
when i run ./configure after uncompress the tarball, i get
error: C compiler cannot create executables
what is the problem?
|
|
|
07-04-2004, 11:12 AM
|
#2
|
LQ Newbie
Registered: Jul 2004
Posts: 5
Original Poster
Rep:
|
here is config.log
code:
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by gtk+ configure 2.4.3, which was
generated by GNU Autoconf 2.59. Invocation command line was
$ ./configure
## --------- ##
## Platform. ##
## --------- ##
hostname = Cuiyt
uname -m = i686
uname -r = 2.6.3-7mdk
uname -s = Linux
uname -v = #1 Wed Mar 17 15:56:42 CET 2004
/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: /sbin
PATH: /usr/sbin
PATH: /bin
PATH: /usr/bin
PATH: /usr/X11R6/bin
PATH: /usr/local/bin
PATH: /usr/local/sbin
## ----------- ##
## Core tests. ##
## ----------- ##
configure:1601: checking for a BSD-compatible install
configure:1656: result: /usr/bin/install -c
configure:1667: checking whether build environment is sane
configure:1710: result: yes
configure:1743: checking for gawk
configure:1759: found /bin/gawk
configure:1769: result: gawk
configure:1779: checking whether make sets $(MAKE)
configure:1799: result: yes
configure:2027: checking build system type
configure:2045: result: i686-pc-linux-gnu
configure:2053: checking host system type
configure:2067: result: i686-pc-linux-gnu
configure:2077: checking for native Win32
configure:2088: result: no
configure:2137: checking for gcc
configure:2153: found /usr/bin/gcc
configure:2163: result: gcc
configure:2407: checking for C compiler version
configure:2410: gcc --version </dev/null >&5
gcc (GCC) 3.4.1 (Mandrake Linux (Cooker) 3.4.1-0.1mdk)
Copyright (C) 2004 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
configure:2413: $? = 0
configure:2415: gcc -v </dev/null >&5
Reading specs from /usr/lib/gcc/i586-mandrake-linux-gnu/3.4.1/specs
Configured with: ../configure --prefix=/usr --libdir=/usr/lib --with-slibdir=/lib --mandir=/usr/share/man --in
fodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --enable-long-long --enable-__
cxa_atexit --enable-clocale=gnu --disable-libunwind-exceptions --enable-languages=c,c++,f77,objc,java --host=i
586-mandrake-linux-gnu --with-system-zlib
Thread model: posix
gcc version 3.4.1 (Mandrake Linux (Cooker) 3.4.1-0.1mdk)
configure:2418: $? = 0
configure:2420: gcc -V </dev/null >&5
gcc: `-V' option must have argument
configure:2423: $? = 1
configure:2446: checking for C compiler default output file name
configure:2449: gcc conftest.c >&5
/usr/bin/ld: unrecognized option '--as-needed'
/usr/bin/ld: use the --help option for usage information
collect2: ld returned 1 exit status
configure:2452: $? = 1
configure: failed program was:
| /* confdefs.h. */
|
| #define PACKAGE_NAME "gtk+"
| #define PACKAGE_TARNAME "gtk+"
| #define PACKAGE_VERSION "2.4.3"
| #define PACKAGE_STRING "gtk+ 2.4.3"
| #define PACKAGE_BUGREPORT "http://bugzilla.gnome.org/enter_bug.cgi?product=gtk+"
| #define GETTEXT_PACKAGE "gtk20"
| /* end confdefs.h. */
|
| int
| main ()
| {
|
| ;
| return 0;
| }
configure:2491: error: C compiler cannot create executables
See `config.log' for more details.
|
|
|
07-04-2004, 04:31 PM
|
#3
|
Senior Member
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,290
|
Looks like the problem is with ld, the linker. What version of ld do you have? Looks like it's choking on one of the options passed to it. Can you compile this simple C program:
#include <stdio.h>
int main(void)
{
puts("Hello");
return 0;
}
Copy it into a file foo.c and do "gcc foo.c -o foo" (no quotes) and see if it produces an executable called foo that you can run. If it reports a linker error, there's some problem between your compiler and your linker.
|
|
|
07-05-2004, 12:53 AM
|
#4
|
LQ Newbie
Registered: Jul 2004
Posts: 5
Original Poster
Rep:
|
yeah, it reports the error
then how to solve the problem
thanks
|
|
|
07-05-2004, 01:15 AM
|
#5
|
LQ Newbie
Registered: Jul 2004
Posts: 5
Original Poster
Rep:
|
got it
i upgrade my gcc to a proper version and all is ok now
|
|
|
All times are GMT -5. The time now is 04:00 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|