[Scons-users] Add specific command line parameters for Visual Studio Project

M. Laurent MARCHELLI laurent.marchelli at gmail.com
Tue Nov 4 10:48:33 EST 2014


Hi Dirk,

Thank you for your answer, please find more information on what we are trying to achieve :

I use the following command line from the global project root :
To build complete solution for Debug|Win32 :		scons debug=True target_arch=32
To build complete solution for Release|Win32:	scons debug=False target_arch=32
To build complete solution for Debug|x64:		scons debug=True target_arch=x64
To build complete solution for Release|x64:		scons debug=False target_arch=x64

And, for each variant, I wanted to add the corresponding command line parameter to the 'Build command line' written inside the Visual Studio Project file generated by SCons.
I had a look to the variant directory, even it seems to be a good solution for new incomer project, unfortunately it is difficult to apply to our huge solution. 
In fact, modifying 930 SConscripts files in a production project does not seem reasonable. :-(

Best regards,
Laurent Marchelli
Chef de projet technique - Freelance
+33 (0) 6 65 69 70 56
Laurent.marchelli at gmail.com
www.linkedin.com/in/laurentmarchelli
www.viadeo.com/fr/profile/laurent.marchelli


Le 4 nov. 2014 à 13:37, Dirk Bächle <tshortik at gmx.de> a écrit :

> Hi Laurent,
> 
> On 04.11.2014 13:22, M. Laurent MARCHELLI wrote:
>> Hello,
>> 
>> I generated with SCons several Visual Studio Projects with 4 variants in each :
>>  Debug|Win32
>>  Release|Win32
>>  Debug|x64
>>  Release|x64
>> 
>> To be able to compile for each variant differently, I need to have different command line parameters for each.
>> How I can manage it with Scons ?
>> 
> can you possibly elaborate a little more on that? In SCons you usually handle building variants of your source code via using the "variant_dir" functionality, which gets described in the UserGuide, chap. 15 "Separating Source and Build Directories" ( scons.org/doc/production/HTML/scons-user.html#idp14616296 ).
> You can also find a simple example in the folder named "pyconde_2013/examples/exvar" of 
> https://bitbucket.org/dirkbaechle/scons_talks .
> 
> But in that case you wouldn't have to specify any command-line parameters, you'd simply call SCons with the name of the target variant directory, e.g. "debug32", and the setting of variables like defines or include paths would get handled within your SConstruct file(s).
> 
> So, I'm not fully sure that the above is what you're trying to accomplish...feel free to correct and complete my assumptions where required.
> 
> Best regards,
> 
> Dirk
> 
> _______________________________________________
> Scons-users mailing list
> Scons-users at scons.org
> https://pairlist4.pair.net/mailman/listinfo/scons-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist4.pair.net/pipermail/scons-users/attachments/20141104/70a8904d/attachment-0001.html>


More information about the Scons-users mailing list