From f0ed3114a96e3a01b7d2da395ef1353f632e4c56 Mon Sep 17 00:00:00 2001 From: Philippe Coval Date: Wed, 17 May 2017 12:33:49 +0200 Subject: [PATCH] tizen: Also build without security all configs Introduce tizen_{secured,unsecured} for jenkins For smooth transition tizen builder is preserved. Also use bash for advanced tests (to parse options args) Bug: https://jira.iotivity.org/browse/IOT-2237 Change-Id: Ib0a648b889d7d9956d6b26a9dc2111e7b9623b02 Signed-off-by: Philippe Coval Reviewed-on: https://gerrit.iotivity.org/gerrit/19955 Tested-by: jenkins-iotivity Reviewed-by: Jaehong Jo Reviewed-by: C.J. Collier --- auto_build.py | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/auto_build.py b/auto_build.py index 7b77114..c46db40 100644 --- a/auto_build.py +++ b/auto_build.py @@ -383,14 +383,14 @@ def build_arduino(flag, extra_option_str): # BLE support for the Arduino Due is currently unavailable. def build_tizen(flag, extra_option_str): - print ("*********** Build for Tizen *************") - cmd_line = "/bin/sh " + os.getcwd() + "/gbsbuild.sh" + print ("*********** Build for Tizen with options *************") + cmd_line = os.getcwd() + "/gbsbuild.sh" + " " + extra_option_str print ("Running : " + cmd_line) exit_code = subprocess.Popen([cmd_line], shell=True).wait() if exit_code != 0: exit(exit_code) - print ("*********** Build for Tizen octbstack lib and sample with security *************") + print ("*********** Build for Tizen octbstack lib and sample *************") build_extra_options = "-f resource/csdk/stack/samples/tizen/build/SConscript " + extra_option_str build_options = { 'TARGET_OS':'tizen', @@ -400,10 +400,6 @@ def build_tizen(flag, extra_option_str): } call_scons(build_options, build_extra_options) - print ("*********** Build for Tizen octbstack lib and sample *************") - build_options['SECURED'] = 0 - call_scons(build_options, build_extra_options) - print ("*********** Build for Tizen octbstack lib and sample with Routing Manager*************") build_options['ROUTING'] = 'GW' call_scons(build_options, build_extra_options) @@ -414,6 +410,12 @@ def build_tizen(flag, extra_option_str): build_extra_options = "-f service/easy-setup/sampleapp/enrollee/tizen-sdb/EnrolleeSample/build/tizen/SConscript " + extra_option_str call_scons(build_options, build_extra_options) +def build_tizen_secured(flag, extra_option_str): + build_tizen(flag, extra_option_str + " SECURED=1") + +def build_tizen_unsecured(flag, extra_option_str): + build_tizen(flag, extra_option_str + " SECURED=0") + # Mac OS and iOS def build_darwin(flag, extra_option_str): print ("*********** Build for OSX *************") @@ -673,6 +675,14 @@ elif arg_num == 2: build_tizen("true", "") build_tizen("false", "") + elif str(sys.argv[1]) == "tizen_unsecured": + build_tizen_unsecured("true", "") + build_tizen_unsecured("false", "") + + elif str(sys.argv[1]) == "tizen_secured": + build_tizen_secured("true", "") + build_tizen_secured("false", "") + elif str(sys.argv[1]) == "simulator": build_simulator("true", "") build_simulator("false", "") -- 2.7.4