[Scons-users] Cancel any previous definition via -U using MergeFlags

Dirk Bächle tshortik at gmx.de
Wed May 6 12:24:03 EDT 2015


Hi Ivan,

On 06.05.2015 12:45, Ivan Kravets wrote:
> Dear community,
>
> I've received an issue for PlatformIO https://github.com/platformio/platformio/issues/191 , where user reported that SCons doesn't recognise "-U" option using env.MergeFlags().
>
> Is it normal behaviour that SCons passes `-U` options to $CCFLAGS which follows before $CPPDEFINES?
>


from what I can see in the current sources, the "-U" option is not supported within ParseFlags() (which gets called internally by 
MergeFlags). The reason for this might be that you don't need it usually in plain SCons projects. If you want to have a variable 
"undefined" for the compilation of a single object file, you can always create a clean Environment() and then "define" (-D) only the 
variables that you would need for building the target.

Best regards,

Dirk



More information about the Scons-users mailing list