Making simulator build optional through scons command line argument "SIMULATOR".
authorHarish Kumara Marappa <h.marappa@samsung.com>
Mon, 21 Sep 2015 06:05:06 +0000 (11:35 +0530)
committerMadan Lanka <lanka.madan@samsung.com>
Mon, 21 Sep 2015 07:35:20 +0000 (07:35 +0000)
simulator module will be built only if scons command passed with SIMULATOR
argument having one of the case insensitive value from "True", "Yes", "Y" and
"1".

Example: scons SIMULATOR=1

Change-Id: I466cadaa8b815bc9bd269c147324ccbb32c907dc
Signed-off-by: Harish Kumara Marappa <h.marappa@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/2813
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
build_common/SConscript
service/SConscript

index 4f0bf76..6a90f75 100644 (file)
@@ -79,6 +79,7 @@ help_vars.Add(EnumVariable('TARGET_OS', 'Target platform', host, host_target_map
 
 
 help_vars.Add(BoolVariable('WITH_RA', 'Build with Remote Access module', False))
+help_vars.Add(BoolVariable('SIMULATOR', 'Build with simulator module', False))
 
 if target_os in targets_disallow_multitransport:
        help_vars.Add(ListVariable('TARGET_TRANSPORT', 'Target transport', 'IP', ['BT', 'BLE', 'IP']))
index 9fb8020..231205c 100644 (file)
@@ -46,7 +46,7 @@ if target_os not in ['arduino','darwin']:
                SConscript('resource-encapsulation/SConscript')
 
        # Build simulator module
-       if target_os in ['linux']:
+       if target_os in ['linux'] and env.get('SIMULATOR', False):
                SConscript('simulator/SConscript')