Clean Compile! (ESIX - gcc)
Steve Bleazard
steve at robobar.co.uk
Fri Jun 8 03:49:00 AEST 1990
In article <5637 at aplcen.apl.jhu.edu> trw at aplcen.apl.jhu.edu (Weil timothy) writes:
>After several days of going nowhere with compile command
>lines such as
> * gcc -ansi -B -c -o file.o file.c
>OR, * gcc -ansi -B -o file file.c
>OR, * gcc -ansi -B file.c
>
>I mostly ran into the following error message -
> "ld: malformed input file (not rel or archive) file.o
>
>SO, like most good experimenters I stumbled onto a Makefile
>which resulted in -
> * gcc -O -c file.c
> * cc file.o -o file
>
>and THIS ONE WORKED! (and I've got no idea why).
>
>From your earlier postings I got the impression that you were using a
binary only distribution of gcc (ie you didn't compile gcc yourself)
is this the case? If it is then there's a very good chance you are
running my Xenix port of GCC / GAS, in which case the .o files are
in OMF format. I must admit to being puzzled by the fact cc manages
to link the file - does it invoke a more intelligent linker ie one
that understands OMF? it is possible that your standard ld (the one
invoked by gcc) does not. If this is the case, ln(C)-ing the more
intelligent ld to /usr/local/lib/gcc-ld will allow gcc to link as well.
Steve.
--
Steve.Bleazard at RoboBar.Co.Uk | Phone: +44 81 991 1142 x153
Snr Software Engineer, Robobar Ltd. | Fax: +44 81 998 8343 (G3)
22 Wadsworth Road, Perivale. |
Middx., UB6 7JD ENGLAND. | ...!ukc!robobar!steve
More information about the Comp.unix.i386
mailing list