[Scons-dev] Question: VersionedLibrary, Name/Path in Node class...
Gary Oberbrunner
garyo at oberbrunner.com
Tue Nov 25 16:52:10 EST 2014
I'd certainly think those two should stay in sync (name and path).
On Tue, Nov 25, 2014 at 3:37 PM, Dirk Bächle <tshortik at gmx.de> wrote:
> Hi fellow devs,
>
> I'm currently working on my patch for switching the Node class to
> __slots__, and there is one final test in the suite which doesn't pass and
> keeps bugging me: test/LINK/VersionedLib.py.
>
> The basic problem seems to be that the "shlib_emitter" in the "link.py"
> tool rewrites the name of the target node:
>
> ===================================================
>
> def shlib_emitter(target, source, env):
> Verbose = True
> platform = env.subst('$PLATFORM')
> for tgt in target:
> tgt.attributes.shared = 1
> try:
> # target[0] comes in as libtest.so. Add the version extensions
> version = env.subst('$SHLIBVERSION')
> if version:
> version_names = shlib_emitter_names(target, source, env)
> # change the name of the target to include the version number
> target[0].name = version_names[0]
> for name in version_names:
> env.SideEffect(name, target[0])
> env.Clean(target[0], name)
> if Verbose:
> print "shlib_emitter: add side effect - ",name
> except KeyError:
> version = None
> return (target, source)
>
> ===================================================
>
> but it doesn't amend the ".path" at the same time, so both entries are
> actually out of synch in the following:
>
> name = "libtest.so.2.5.4"
> path = "libtest.so"
>
> for the test example.
>
> My question: Do we allow the name of a Node to be anything, or (as I
> assumed until now) is the "name" always the trailing part of the "path"?
>
> Best regards,
>
> Dirk
>
> _______________________________________________
> Scons-dev mailing list
> Scons-dev at scons.org
> https://pairlist2.pair.net/mailman/listinfo/scons-dev
>
--
Gary
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist2.pair.net/pipermail/scons-dev/attachments/20141125/8f61371f/attachment.html>
More information about the Scons-dev
mailing list