[Scons-dev] Help needed on command string

Russel Winder russel at winder.org.uk
Thu Apr 13 02:58:17 EDT 2017


On Wed, 2017-04-12 at 07:50 -0700, Bill Deegan wrote:
> Russel,
> 
> I'm not sure what the difference is between configurations and
> variants?
> To me they are the same and SCons supports them well.
> The only difference may be that other build systems have per-
> concieved
> ideas of different configurations (flags for
> optimize/release/debug/etc)
> (More easily for some directory structures than others)

I guess different build systems have different thoughts. CMake, Meson,
and Dub for example handle the release/debug build as a separate
concept from the set of files which is determined by a target
specification application/test.

> Typically you create a bunch of environments for each variant, and
> then
> pass that to the same SConscript with different variant_dir's.
> 
> In some cases you may use info passed from the parent (Via
> SConscript) to
> modify the behavior of the children (SConscripts).

I think the lesson I have taken from this, is that unless you want to
program the build source structure explicitly, you have to put the
SConscript files in the directory to which they apply. I think my
problem was that I was trying to keep the SConscript file separate from
the source they related to. This is not something SCons handles well.
CMake and Meson allow this but also allow single top level
specification with variants without lots of hassle. SCons model
requires hassle if not using the SConscript in the directory to which
it applies.

Nothing wrong here per se, it just an idiom it behoves one not to fight
against.

> I've built debug/release/test/purify X 32/64bit x {linux,win32,
> solaris,
> hpux, aix} with such a build system. Worked like a charm.  (And
> wasn't
> overly complicated)

Doing all source compilation of D codes looks like it may not be that
hard to add to the D tools.

Also connecting SCons to the Dub repository may not be that big a deal.

-- 
Russel.
=============================================================================
Dr Russel Winder      t: +44 20 7585 2200   voip: sip:russel.winder at ekiga.net
41 Buckmaster Road    m: +44 7770 465 077   xmpp: russel at winder.org.uk
London SW11 1EN, UK   w: www.russel.org.uk  skype: russel_winder
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <https://pairlist2.pair.net/pipermail/scons-dev/attachments/20170413/069a21fe/attachment.pgp>


More information about the Scons-dev mailing list