Removed #ifdef CA_INTs and other code cleanup.
[platform/upstream/iotivity.git] / service / protocol-plugin / sample-app / linux / SConscript
1 ##
2 #sample-app build script
3 ##
4
5 Import('env')
6
7 # Add third party libraries
8 lib_env = env.Clone()
9 SConscript(env.get('SRC_DIR') + '/service/third_party_libs.scons', 'lib_env')
10
11 sample_env = lib_env.Clone()
12
13 target_os = env.get('TARGET_OS')
14 ######################################################################
15 # Build flags
16 ######################################################################
17 sample_env.AppendUnique(CPPPATH = [
18                                 '../../plugin-manager/src/',
19                                 '../../lib/cpluff/libcpluff/',
20                                 '../../lib/rapidxml'])
21 if target_os not in ['windows', 'winrt']:
22         sample_env.AppendUnique(CXXFLAGS = ['-Wall', '-pthread', '-std=c++0x'])
23
24 sample_env.AppendUnique(LIBS = ['pthread'])
25 sample_env.AppendUnique(LIBS = ['oc', 'oc_logger', 'octbstack', 'coap', 'coap_csdk',
26                                                                 'connectivity_abstraction',
27                                                                 'ppm', 'pmimpl', 'dl'])
28
29 if env.get('SECURED') == '1': 
30     sample_env.AppendUnique(LIBS = ['tinydtls'])
31
32 sample_env.ParseConfig('pkg-config --libs glib-2.0')
33
34 ######################################################################
35 # Source files and Targets
36 ######################################################################
37 mqttclient = sample_env.Program('mqtt/mqttclient', 'mqtt/mqttclient.cpp')
38
39 Alias('mqttclient', mqttclient)
40 env.AppendTarget('mqttclient')
41