From: Jonathan Wakely (cow_at_[hidden])
Date: 2004-12-16 10:08:52
On Thu, Dec 16, 2004 at 09:50:36AM -0500, Caleb Epstein wrote:
> On Thu, 16 Dec 2004 08:44:20 -0500, Stefan Seefeld <seefeld_at_[hidden]> wrote:
> > There are a number of flags that have to be made public, such as
> > what type of runtime to use (that could mean, among others, the definition
> > of __REENTRANT or the '-pthread' compiler flag). Also, on some platforms
> > the dependency on dynamic libraries isn't well encapsulated, i.e. if libA.so
> > depends on libB.so, an executable linking against libB.so also needs to be
> > linked (explicitely) against libA.so.
> > There is quite some variation between different platforms, and pkg-config
> > tries to make life a bit easier for developers of portable code.
> I understand all this. I was following up to Jon asking what the
> differnce would be between: "the flags that /should/be/ used to
> compile against Boost, not the flags the /were/ used to compile Boost
Sorry, I hadn't had a chance to think of anything.
You might have compiled Boost with a certain level of optimisation, say
by setting GXX="g++ -O3" (for the GCC toolset) but you don't necessarily
want to optimise your code at that level (if at all) so --cflags should
not emit -O3. Similarly for -ansi, -pedantic, -W and other switches that
don't affect the ABI or whether you can link to a library safely.
Or is that irrelevant?
-- "The optimist believes this is the best of all possible worlds, and the pessimist fears this is so..." - H. Allen Smith
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk