C error?
Hi @ll, When I try to run any configure file obtaind the following message checking build system type... i586-pc-linux-gnu checking host system type... i586-pc-linux-gnu checking target system type... i586-pc-linux-gnu checking for a BSD compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for mawk... no checking for gawk... gawk checking whether make sets ${MAKE}... yes checking for gcc... gcc checking for C compiler default output... configure: error: C compiler cannot create executables My machine RH6.2 whit this package: cpp-1.1.2-30 make-3.78.1-4 compat-egcs-c++-5.2-1.0.3a.1 compat-egcs-objc-5.2-1.0.3a.1 egcs-c++-1.1.2-30 egcs-objc-1.1.2-30 compat-egcs-5.2-1.0.3a.1 compat-egcs-g77-5.2-1.0.3a.1 egcs-1.1.2-30 egcs-g77-1.1.2-30 I'm not C expert, any idea? TIA Miguel Rosales. ___ Redhat-list mailing list [EMAIL PROTECTED] https://listman.redhat.com/mailman/listinfo/redhat-list
Re: C error?
At 10:52 AM 3/4/02 -0300, [EMAIL PROTECTED] wrote: checking for C compiler default output... configure: error: C compiler cannot create executables I typically get this error when I have configured GCC as a cross compiler of some sort (for a different set of system libraries or for a different CPU/Architecture). If it's a typical configure script then it means just what it says it means, the script tried to compile a program (and probably it compiled correctly) but then was unable to execute the output. Another common cause of this is if for some reason your C compiler is not producing output with the execute bit set by default. This can happen either if you have a umask problem, or if you are running a script on a mounted filesystem that doesn't support it (any read-only filesystem, any FAT (DOS/Windows) filesystem, etc.). A good way to test this is to create a little hello world program that requires dynamic linking, and see if you can compile it and execute in the current directory. Something like: --- CUT HERE --- #include stdio.h #include math.h int main() { double foo; foo = 4.3; foo = sin( foo ); printf( Sin(4.3) = %lf\n, foo ); return 0; } --- CUT HERE --- Save that (in the same dir as the configure script) as hello.c then run gcc -Wall -g -lm hello.c To compile it and link it against the math library. It should create an executable file called a.out, so you should then be able to run ./a.out And see the output: Sin(4.3) = -0.916166 And then you can safely delete hello.c and a.out. If all of this works then the configure script you're trying to run is broken. Typical places I can think of where it would fail: If the compiler says something about being unable to include math.h, or tells you that you have an implicit definition of anything, then your header files and/or libraries are not installed correctly. If the compiler tells you it is unable to resolve the reference to the sin() function then your header files are probably fine, but your linker and/or library files are screwed up. If the program compiles successfully and when you run it you get an error like file not found then you are probably configured to link (at compile time) against a different set of libraries from those actually available at run-time (usually because you've been cross-compiling for some other machine). ls -al a.out should show you something like: -rwxr-xr-x1 cnww users 21975 Mar 4 17:25 a.out If the program compiles, but doesn't appear executable (i.e. the x bits are not set in ls output) then you have a problem with the configuration of the current directory. -- The difference between genius and stupidity is that genius has its limits. ___ Redhat-list mailing list [EMAIL PROTECTED] https://listman.redhat.com/mailman/listinfo/redhat-list
Re: C error?
On Mon, 2002-03-04 at 05:52, [EMAIL PROTECTED] wrote: ... checking for gcc... gcc checking for C compiler default output... configure: error: C compiler cannot create executables My machine RH6.2 whit this package: cpp-1.1.2-30 make-3.78.1-4 compat-egcs-c++-5.2-1.0.3a.1 compat-egcs-objc-5.2-1.0.3a.1 egcs-c++-1.1.2-30 egcs-objc-1.1.2-30 compat-egcs-5.2-1.0.3a.1 compat-egcs-g77-5.2-1.0.3a.1 egcs-1.1.2-30 egcs-g77-1.1.2-30 I'm not C expert, any idea? You also need a number of -devel packages. At least get glibc-devel and kernel-headers installed and try again. ___ Redhat-list mailing list [EMAIL PROTECTED] https://listman.redhat.com/mailman/listinfo/redhat-list
Re: C error?
I'm not C expert, any idea? I don't think it has anything to do with C, but rather your environment. Could be a umask issue (just a thought). Your environment might prefent you from setting files as executable. ___ Redhat-list mailing list [EMAIL PROTECTED] https://listman.redhat.com/mailman/listinfo/redhat-list
Re: C error?
March 4, 2002 To me, it looks like you're missing the package that contains the assembler, In RedHat 7.1 it's called dev86-0.15.0-5. Regards, Mike Anderson On Mon, 4 Mar 2002 [EMAIL PROTECTED] wrote: Hi @ll, When I try to run any configure file obtaind the following message checking build system type... i586-pc-linux-gnu checking host system type... i586-pc-linux-gnu checking target system type... i586-pc-linux-gnu checking for a BSD compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for mawk... no checking for gawk... gawk checking whether make sets ${MAKE}... yes checking for gcc... gcc checking for C compiler default output... configure: error: C compiler cannot create executables My machine RH6.2 whit this package: cpp-1.1.2-30 make-3.78.1-4 compat-egcs-c++-5.2-1.0.3a.1 compat-egcs-objc-5.2-1.0.3a.1 egcs-c++-1.1.2-30 egcs-objc-1.1.2-30 compat-egcs-5.2-1.0.3a.1 compat-egcs-g77-5.2-1.0.3a.1 egcs-1.1.2-30 egcs-g77-1.1.2-30 I'm not C expert, any idea? TIA Miguel Rosales. ___ Redhat-list mailing list [EMAIL PROTECTED] https://listman.redhat.com/mailman/listinfo/redhat-list ___ Redhat-list mailing list [EMAIL PROTECTED] https://listman.redhat.com/mailman/listinfo/redhat-list