Boost logo

Boost-Build :

Subject: Re: [Boost-build] gcc precompiled headers
From: J. van der Wulp (jwulp_at_[hidden])
Date: 2008-11-17 05:40:59


> This is recent breakage from the 'make source files with same name
> in different directories work' patch. I've checked in a fix:
>
> https://svn.boost.org/trac/boost/changeset/49800
>

Thanks a lot. It was this very patch for which I imported the changes
from trunk. It allowed me to tidy some Jamfiles. During testing after
the changes I noticed that precompiled headers were no longer working.

> Are either libraries or executables static? Because when link=static, which
> is the default, -fPIC is added everywhere.
>

I always try to test with either link=static or link=shared on the
command line. We have lots of tools and only a few libraries so shared
linking is usually preferred.

>> Can I also solve this problem by setting -fpic for all compilations in
>> the project? For what platforms/gcc versions can this work and does this
>> have any unwanted side-effects?
>
> -fPIC will work everywhere. It has some performance penalty, though I'm not
> sure anybody considers it significant nowdays.

Sounds as an acceptable offer using precompiled headers to speed up
compilation is more of a developer feature anyway.

Thanks again,

Jeroen


Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk