On Wed, 2 Apr 2008, Carsten Sørensen wrote:
On Tue, Apr 1, 2008 at 6:06 PM, Tijl Vercaemer <[EMAIL PROTECTED]> wrote:
This works, and it helped me to figure out why my code didn't link.
Apparently, the -lws2 option should be at the end of the command. I
had my -lws2 in between the -o option and the input file. Moving it
after the input file, solved my problem.
That's a general gcc feature, the order of libraries and objects is
important.
that order is important only on Windows (gcc for windows). On linux, ou
can put the static libs in any order you want. If I'm not mistaken, the
problem is the format of the executable files (ELF on linux and COFF or a
variant on Windows).
regards
Vincent
When gcc sees a library on the commandline, only those
parts of it that have already been referenced by a previous library
or object file are included. In your case the library was skipped
completely since nothing had referenced any of its functions yet.
Kind regards,
Carsten Sorensen
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
Cegcc-devel mailing list
Cegcc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cegcc-devel
--
Ce message a été vérifié par MailScanner
pour des virus ou des polluriels et rien de
suspect n'a été trouvé.
Message délivré par le serveur de messagerie de l'Université d'Evry.
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
Cegcc-devel mailing list
Cegcc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cegcc-devel