2 # NotificationManager build script
8 SConscript(env.get('SRC_DIR') + '/service/third_party_libs.scons', 'lib_env')
9 notimgr_env = lib_env.Clone()
11 target_os = env.get('TARGET_OS')
12 ######################################################################
14 ######################################################################
15 notimgr_env.AppendUnique(CPPPATH = ['NotificationManager/include'])
16 notimgr_env.AppendUnique(CPPPATH = ['../../extlibs/cjson'])
17 notimgr_env.AppendUnique(CPPPATH = ['../../resource/csdk/logger/include'])
18 notimgr_env.PrependUnique(LIBS = ['oc', 'octbstack', 'oc_logger', 'coap'])
20 if target_os not in ['windows', 'winrt']:
21 notimgr_env.AppendUnique(CXXFLAGS = ['-O2', '-g', '-Wall', '-fmessage-length=0'])
23 if target_os == 'linux':
24 notimgr_env.AppendUnique(LIBS = ['pthread'])
26 if target_os == 'android':
27 notimgr_env.AppendUnique(CXXFLAGS = ['-frtti', '-fexceptions'])
28 notimgr_env.AppendUnique(LIBS = ['gnustl_static'])
30 if not env.get('RELEASE'):
31 notimgr_env.AppendUnique(LIBS = ['log'])
33 ######################################################################
34 # Source files and Targets
35 ######################################################################
36 NOTI_SRC_DIR = 'NotificationManager/src/'
38 NOTI_SRC_DIR + 'hosting.c',
39 NOTI_SRC_DIR + 'requestHandler.c',
40 NOTI_SRC_DIR + 'virtualResource.c']
42 notificationsdk = notimgr_env.StaticLibrary('NOTISDKLibrary', notimgr_src)
44 notimgr_env.InstallTarget(notificationsdk, 'libNMSDK')
46 # Go to build sample apps
47 SConscript('SampleApp/SConscript')