-fno-inline -O1 breaks ntohs()
Stefan Traby
stefan@hello-penguin.com
Sun Sep 17 20:11:00 GMT 2006
Hi!
Testcase:
------------------------------
#include <arpa/inet.h>
int main()
{
volatile short s = 33, t;
t = ntohs(s);
return 0;
}
------------------------------
> i686-pc-cygwin-gcc -fno-inline -o test test.c
> i686-pc-cygwin-gcc -O1 -fno-inline -o test test.c
/tmp/ccswmuY9.o:test.c:(.text+0x27): undefined reference to `___ntohs'
collect2: ld returned 1 exit status
>
This is my crosscompiler (gcc-4.1.1) but it breaks with gcc-3.4.4
(included in cygwin) exactly the same way (it compiles without -O1
and breaks otherwise).
If -fno-inline is not supported under cygwin sorry for wasting your time.
--
ciao -
Stefan
" Whip me. Beat me. Make me maintain VMS. "
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
More information about the Cygwin
mailing list