[Scons-users] rebuilding

TOM TANNER (BLOOMBERG/ LONDON) ttanner2 at bloomberg.net
Tue Jun 26 12:10:45 EDT 2012


I went for the 2nd one, as we already do this for solaris and linux, and the RPATH isn't quite the same as the LIBPATH (and it'll be no worse than our existing build system).

Cheers

TT
----- Original Message -----
From: scons-users at scons.org
To: scons-users at scons.org
At: 6/26 16:32:19

On 06/26/2012 10:07 AM, TOM TANNER (BLOOMBERG/ LONDON) wrote:

> Ah, yes, that's the problem. I'll have a look at using RPATH - aix linker doesn't have an equivalent and you have to use -L to make the executable pick libraries up from the right place...


So I'm not an SCons dev, but my initial reaction is that either of the
following fixes seems reasonable:

- Change env["_LIBDIRFLAGS"] so that, for the Aix linker, it leaves in
$( $)

- Change env["RPATHPREFIX"] to be "-L" (by default, "-Wl,-rpath=")
and then use env["RPATH"] to add stuff.

The latter approach has the advantage that you can just use env["RPATH"]
across systems (well, any systems that behave like Linux and, after your
fix, Aix :-)) to set the runtime lookup paths, but has the disadvantage
that env["RPATH"] and env["LIBPATH"] now do the same thing.

Evan




>

> ----- Original Message -----

> From: scons-users at scons.org

> To: scons-users at scons.org

> At: 6/26 15:31:24

>

> [If you get this twice, I apologize]

>

> On Tuesday, June 26, 2012 08:24:36 AM TOM TANNER wrote:

>> relinks then. but it should have caused a lot of them, not zero.

>

> Actually, with a little prompting, I'd only have expected relinks if adding

> the directory caused a different library to get picked up.

>

> And here's why that happens:

>

> The default LINKCOM (Linux) is

> $LINK -o $TARGET $LINKFLAGS $__RPATH $SOURCES $_LIBDIRFLAGS $_LIBFLAGS

>

> _LIBDIRFLAGS is where the -L flags are included, programatically builtup from

> LIBDIRS:

> $( ${_concat(LIBDIRPREFIX, LIBPATH, LIBDIRSUFFIX, __env__, RDirs,

> TARGET, SOURCE)} $)

>

> The $( and $) say omit the stuff that comes in here from a file's signature (the

> thing that causes it something to rebuild if it changes). It's unnecessary

> because the library files are found independently by SCons anyway so that it

> can take the MD5 hash (or look at the timestamp, or Decide however) so if the

> libraries change it will rebuild.

>

> Evan

>

>

>

>>

>> ----- Original Message -----

>> From: scons-users at scons.org

>> To: scons-users at scons.org

>> At: 6/26 13:23:17

>>

>> On Jun 26, 2012 2:15 PM, "TOM TANNER (BLOOMBERG/ LONDON)"<

>> ttanner2 at bloomberg.net> wrote:

>>

>>>

>>>

>>> I was slightly surprised not to get anything rebuilt when I added a

>>

>> directory to my env['LIBPATH'].

>>

>>>

>>>

>>> Surely this should cause a load of rebuilds?.

>>>

>>>

>>

>>

>> Relinks surely, rebuilds not so certain...

>>

>> JB _______________________________________________

>>

>>> Scons-users mailing list

>>> Scons-users at scons.org

>>> http://four.pairlist.net/mailman/listinfo/scons-users

>>

>>

> _______________________________________________

> Scons-users mailing list

> Scons-users at scons.org

> http://four.pairlist.net/mailman/listinfo/scons-users

>

> _______________________________________________

> Scons-users mailing list

> Scons-users at scons.org

> http://four.pairlist.net/mailman/listinfo/scons-users


_______________________________________________
Scons-users mailing list
Scons-users at scons.org
http://four.pairlist.net/mailman/listinfo/scons-users



More information about the Scons-users mailing list