[Scons-users] Problems with env.Install()

Michel Lestrade michel.lestrade at crosslight.com
Fri Jan 25 23:02:19 EST 2013


Bill,

On 1/25/2013 4:17 PM, William Deegan wrote:

> I think it's an issue that you're mixing variant_dir with non-variant_dir SConscripts in the same directory and specifying duplicate=0.

>

> esmumps = SConscript(dirs = 'esmumps', duplicate=0,

> exports = {'env':env.Clone(LIBS=[libscotch,libscotcherrexit,env['LIBS']]),'mpi':0})

> SConscript(dirs = 'scotch', duplicate=0,

> exports = {'env':env.Clone(LIBS=[libscotch,libscotcherrexit,env['LIBS']]),'mpi':0})

>

> And then:

> ptesmumps = SConscript(dirs = 'esmumps', variant_dir = 'ptesmumps', duplicate=0,

> exports = {'env':pt.Clone(LIBS=[libscotch,libscotcherrexit,libptscotch,pt['LIBS']]),'mpi':1})

> SConscript(dirs = 'scotch', variant_dir = 'ptscotch', duplicate=0,

> exports = {'env':pt.Clone(LIBS=[libscotch,libscotcherrexit,libptscotch,pt['LIBS']]),'mpi':1})

>

> It'll see the pthread.dll in the non-variant dir build, and so it won't run the install again, and since you specify duplicate=0, it won't copy it to the variant dir.

>

> Am I right that you are missing these files:

> ** d:\Source\MUMPS_scons\build\scotch64\ptesmumps\pthread64.dll

> ** d:\Source\MUMPS_scons\build\scotch64\scotch_dll\pthread64.dll


Yes, those are exactly the files I was missing. I think I did not
specify the variant_dir for the original un-renamed folder names because
scons was complaining about how a variant_dir cannot be under the
original dir. I can understand why you cannot build "foo" under
"foo/bar" since it would create a recursion nightmare but it seemed odd
that you cannot simply use the exact original directory name as the name
of the variant_dir; it's not exactly a variant if you do this ! The
duplicate=0 was simply to avoid copying the source files. I did not
think it applied to build targets but I see now that it makes sense; I
had noticed some object files were not being copied to my variant folders.

Anyway, that is an interesting idea; I will try giving some dummy
variant names for those original folders to see if it helps. However, it
seems odd that some variant folders (e.g. ptscotch_dll) did receive the
DLL; from what you suggest, only my original non-variant directories
should get the files .... Since there are only 2 original folders with
non-variant calls, I should be missing 4 DLLs out of 6 instead of just 2.

Michel Lestrade


More information about the Scons-users mailing list