[Scons-users] Library configuration

Daniel Russel drussel at gmail.com
Thu Jun 21 12:58:29 EDT 2012


On Wed, Jun 20, 2012 at 6:12 PM, Evan Driscoll <driscoll at cs.wisc.edu> wrote:


> **

>

> On Wednesday, June 20, 2012 05:59:07 PM Daniel Russel wrote:

>

> > We went with just having flags "includepath", "libpath" in which the

> users

>

> > put all the places to have the compiler look for includes/libs separated

> by

>

> > ":"s. I'm personally not a big fan of specifying the includepath/libpath

>

> > for each library as it is

>

> > - misleading as the compilation will end up being like "gcc

>

> > -I/path/to/a/include -I/path/to/b/include" so all headers are searched

> for

>

> > in all places and having a big directory that includes several packages

> is

>

> > not unusual

>

> > - the order of search is unspecified (sometimes you have multiple

> versions

>

> > around and you want to make sure one is found instead of the other)

>

> > - and verbose:

>

> > includepath="/path/to/a/include:/path/to/b/include"

>

> > vs

>

> > A_include="/path/to/a/include" B_include="/path/to/b/include"

>

>

>

> To play devil's advocate for a moment for a moment:

>

>

>

> 1) If your script follows the usual autoconf convention of looking at

> CFLAGS,

>

> LDFLAGS, etc., then your way can be emulated:

>

> CPPFLAGS="-I/path/to/a/include -I/path/to/b/include"

>

> instead of

>

> includepath="/path/to/a/include:/path/to/b/include"

>

>

>

> This is something I want to do anyway, regardless of other mechanisms.

>

Yes, that would have the same result. We ignore environment variables for
various reasons and make people explicitly pass them to the scons call.
Ignoring them is kind of nice for long term developers as one sets up a
config file and has everything listed explicitly, but, I think, it is less
nice for users who want to build are project as it is a bit weird to have
your PATH ignored.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://four.pairlist.net/pipermail/scons-users/attachments/20120621/4f93a325/attachment.html>


More information about the Scons-users mailing list