Re: How to put varient dir totally out side of the Source tree
Subrata Dasgupta via Scons-users <[email protected]> 1 Aug 2024 19:04:39 -0000
| Newsgroups | gmane.comp.programming.tools.scons.user |
|---|---|
| Message-ID | <1722538293.S.5246.autosave.drafts.1722539079.24095@webmail.rediffmail.com> |
Hi Mats, First of all thanks for the suggestion. My source code have multiple levels.I kept multiple SConstruct files within various source tree and internally calling them as required. This worked so far fine, SCons was able to understand the source dependency and fire compilation in correct order when building within the source tree. Then I tried to build using variant_dir to separate build output and source. Then lots of issues are coming. For an example some times it give following error. scons: *** 'build' already has a source directory: 'Lib1' Above error goes away if I call SConscript like below from the top SConstruct file. Other SConstruct files within sub folders do not contain variant_dir argument. env.SConscript('Lib1/SConstruct', variant_dir='BUILD_TEST/Lib1') env.SConscript('Prog/SConstruct', variant_dir='BUILD_TEST/Prog') But with the above changes now scons will only try to build the Prog not the Lib1. Please suggest how to resolve the issue. Thanks Subrata From: Mats Wichmann <[email protected]> Sent: Thu, 01 Aug 2024 02:02:52 To: [email protected] Subject: Re: [Scons-users] How to put varient dir totally out side of the Source tree On 7/31/24 13:12, Subrata Dasgupta via Scons-users wrote: > Hi All, > I am new to Scons. I am currently trying to build a project using Scons. > Build within source tree is working for me. I kept multiple SConstruct > files within various source tree and internally calling them as required. > > But I am not sure how to separate the build output and source using > VariantDir call when variant_dir is totally out side of the source tree. > > Please suggest how to achieve this. A small example will be very helpful. This has to do with target selection. SCons does not by default select targets outside the tree, so if you put the variantdir outside, then nothing in the variantdir will be built by default - you have to tell it. To see if this is your problem, try a build like this: scons / _______________________________________________ Scons-users mailing list [email protected] https://pairlist4.pair.net/mailman/listinfo/scons-users _______________________________________________ Scons-users mailing list [email protected] https://pairlist4.pair.net/mailman/listinfo/scons-users