This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

1.7.9 gcc linking fails after cygwin update

Hi Folks:

After a recent update of Cygwin on XP Professional my previously
working C/C++ programs suddenly quit compiling under gcc/g++.
Actually they pass all stages of compilation except the final link
stage.  This goes for the simplest of programs such as

   /* simple.c */
   int main(){ return 0; }

The ouput of gcc simple.c is:

/usr/lib/gcc/i686-pc-cygwin/4.3.4/../../../../i686-pc-cygwin/bin/ld: unrecognized -a option `ware'
collect2: ld returned 1 exit status

I've attached the output of  gcc --verbose simple.c to this message,
along with the output of cygcheck -s -v -r.  I believe only the last
4 lines of the --verbose output are relevant, and I quote them here:

COLLECT_GCC_OPTIONS='-v' '-mtune=generic' '-march=i686'
/usr/lib/gcc/i686-pc-cygwin/4.3.4/collect2.exe -tsaware --wrap _Znwj --wrap _Znaj --wrap _ZdlPv --wrap _ZdaPv --wrap _ZnwjRKSt9nothrow_t --wrap _ZnajRKSt9nothrow_t --wrap _ZdlPvRKSt9nothrow_t --wrap _ZdaPvRKSt9nothrow_t -Bdynamic --dll-search-prefix=cyg -u ___register_frame_info -u ___deregister_frame_info /usr/lib/gcc/i686-pc-cygwin/4.3.4/../../../crt0.o /usr/lib/gcc/i686-pc-cygwin/4.3.4/crtbegin.o -L/usr/lib/gcc/i686-pc-cygwin/4.3.4 -L/usr/lib/gcc/i686-pc-cygwin/4.3.4 -L/usr/lib/gcc/i686-pc-cygwin/4.3.4/../../.. /tmp/cc3YVRya.o -lgcc_s -lgcc -lgcc_eh -lcygwin -luser32 -lkernel32 -ladvapi32 -lshell32 -lgcc_s -lgcc -lgcc_eh /usr/lib/gcc/i686-pc-cygwin/4.3.4/crtend.o
/usr/lib/gcc/i686-pc-cygwin/4.3.4/../../../../i686-pc-cygwin/bin/ld: unrecognized -a option `ware'
collect2: ld returned 1 exit status

(This really is 4 lines, though it may wrap on your display).  I went
so far as to completely uninstall cygwin, move all old files to another
directory, then perform a fresh install of 1.7.9, with no luck.

It appears from the above that collect2.exe is being passed an option
-tsaware (Terminal Server Aware?) which is being wrongly interpreted
by ld as three separate options -t (--trace), -s (--strip-all), both
of which are accepted, followed by -a with the invalid argument "ware".
This is the only way I can make sense of the odd error message

/usr/...../ld: unrecognized -a option `ware'

As I understand it, collect2 renames itself ld, then calls the so called
real-ld, but apparently somebody is getting the wrong arguments.  I was
hoping someone more knowledgeable than myself could look at my cycheck
output and find out what's in the wrong place. Perhaps something in the
Registry persists through the uninstall/install.


Patrick Tantalo

Attachment: verbose.txt
Description: Text document

Attachment: cygcheck.txt
Description: Text document

Problem reports:
Unsubscribe info:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]