Boost logo

Boost :

From: David Abrahams (david.abrahams_at_[hidden])
Date: 2001-11-08 09:14:45


----- Original Message -----
From: "Thomas Witt" <witt_at_[hidden]>

> On Monday 05 November 2001 10:57, you wrote:
> >
> > Unix developers are used to just say -lm if they want libm.a. Windows
> > developers (at least MSVC users) are used to explicitly say
> > kernel32.lib or user32.lib. In other words, unix developers are used
> > to smart name deduction, windows developers are not.
> >
>
> I think even windows developers can differentiate between library name and
> suffix. (At least those I know can) :-).

Interestingly, different windows toolsets work differently in this respect.
It appears that Metrowerks' linker supports the libXXX.ext format:

  -l+file # cased; add a library by searching access
paths
                             # for file named lib<file>.<ext> where <ext>
is
                             # a typical library extension; added before
                             # system libraries (see '-defaults')

> > On the other hand, if the build system supports windows and unix
> > platforms, you should be able to say <find-library>foo and it works
> > for unix and windows.
>
> I agree. Though to have real platfom independent library name handling the
> build system still needs something like PREFLIB in analogy to SUFLIB.
>
> When specifying a lib target you would say :
>
> $(PREFLIB)AName$(SUFLIB)

Well, users shouldn't have to say that explicitly. We could arrange for all
libraries built under Unix to be prefixed with "lib".

> This way windows libraries would not end up with a name like
"libAName.lib"
> and UNIX naming conventions can still be preserved.

On the other hand, some people building under Cygwin want to generate names
with the "lib" prefix. It isn't strictly target-platform specific, but also
depends on the toolset.

-Dave


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk