Boost logo

Boost Users :

From: Ben Hutchings (ben.hutchings_at_[hidden])
Date: 2004-04-30 09:59:20


John Maddock <john_at_[hidden]> wrote:
<snip>
> The g++ linker is pretty brain-dead - the libraries have to appear
> on the command line *after* the source files that use them.

This is not brain-dead. It is useful to be able to control the order
in which symbols are looked for since they may be defined in more
than one library. It is a bit weird that -l is not placed before
the file names as is the Unix convention for options, but it *isn't*
an option - it is a shortcut for specifying a file in the library
search path that follows the usual library name convention
(lib<name>.a) and is exactly equivalent to specifying the full file
name (AFAIK).

Secondly, there is no g++ linker. g++ can use various Unix linkers
though it is most commonly used together with the linker from GNU
binutils. However, all Unix linkers should behave this way.

Ben.


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net