5 SConscript('./resource/csdk/connectivity/build/SConscript')
9 target_os = env.get('TARGET_OS')
10 transport = env.get('TARGET_TRANSPORT')
11 buildsample = env.get('BUILD_SAMPLE')
12 release_mode = env.get('RELEASE')
13 secured = env.get('SECURED')
14 logging = env.get('LOGGING')
15 routing = env.get('ROUTING')
16 with_proxy = env.get('WITH_PROXY')
17 with_tcp = env.get('WITH_TCP')
18 with_mq = env.get('WITH_MQ')
20 with_upstream_libcoap = env.get('WITH_UPSTREAM_LIBCOAP')
21 if with_upstream_libcoap == '1':
22 # For bring up purposes only, we manually copy the forked version to where the unforked version is downloaded.
23 env.AppendUnique(CPPPATH = ['#extlibs/libcoap/libcoap/include'])
25 # For bring up purposes only, the forked version will live here.
26 env.AppendUnique(CPPPATH = ['../../../../connectivity/lib/libcoap-4.1.1'])
28 env.PrependUnique(CPPPATH = [
29 '../../../../logger/include',
30 '../../../../stack/include',
31 '../../../../../../extlibs/cjson',
32 '../../../../../oc_logger/include'
35 env.AppendUnique(CPPDEFINES = ['TB_LOG'])
37 env.AppendUnique(CPPDEFINES = ['ROUTING_GATEWAY'])
39 env.AppendUnique(CPPDEFINES = ['ROUTING_EP'])
40 env.AppendUnique(CPPDEFINES = ['__TIZEN__'])
42 if env.get('WITH_PROXY'):
43 env.AppendUnique(CPPDEFINES = ['WITH_CHPROXY'])
45 print "Given Transport is %s" % transport
46 print "Given OS is %s" % target_os
47 print "Given MQ is %s" % with_mq
49 gbs_command_prefix = ""
50 if (('BLE' in transport) or ('ALL' in transport)):
51 print "Tizen BLE requires tizen 3.0 profile"
52 gbs_command_prefix += "gbsprofile=tizen_4_0_unified_armv7l "
54 if target_os == 'tizen':
55 command = gbs_command_prefix + "./resource/csdk/stack/samples/tizen/build/gbsbuild.sh %s %s %s %s %s %s %s %s %s" % (transport, secured, buildsample, release_mode, logging, routing, with_tcp, with_proxy, with_mq)
56 print "Created Command is %s" % command
57 gbs_script = env.Command('gbs_build', None, command)
58 AlwaysBuild ('gbs_script')