From a7f774be00a444a475d84db1177feba86e45ede7 Mon Sep 17 00:00:00 2001 From: Joseph Morrow Date: Fri, 29 May 2015 18:07:14 -0400 Subject: [PATCH] Specify proper default SCons parameter build values for Android. This will allow an end user to simply issue "scons TARGET_OS=android" and expect the build to work. Before this, end users had to specify the TARGET_TRANSPORT & TARGET_ARCH parameters every time. Change-Id: I48cea638a441fa55b1a82d320cd2a65b6cc39c01 Signed-off-by: Joseph Morrow Reviewed-on: https://gerrit.iotivity.org/gerrit/1154 Reviewed-by: Erich Keane Tested-by: jenkins-iotivity --- build_common/SConscript | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/build_common/SConscript b/build_common/SConscript index 02cbed3..88b39fb 100644 --- a/build_common/SConscript +++ b/build_common/SConscript @@ -40,7 +40,11 @@ if target_os not in host_target_map[host]: print "\nError: Unknown target os: %s (Allow values: %s)\n" % (target_os, host_target_map[host]) Exit(1) -default_arch = platform.machine() +if target_os is 'android': + default_arch = 'x86' +else: + default_arch = platform.machine() + if default_arch not in os_arch_map[target_os]: default_arch = os_arch_map[target_os][0].lower() @@ -63,7 +67,7 @@ else: ###################################################################### # Common build options (release, target os, target arch) ###################################################################### -targets_disallow_multitransport = ['arduino'] +targets_disallow_multitransport = ['arduino', 'android'] help_vars = Variables() help_vars.Add(BoolVariable('VERBOSE', 'Show compilation', False)) -- 2.7.4