build: Disable provisioning logging when not wanted
[platform/upstream/iotivity.git] / build_common / tizen / SConscript
1 # -*- mode: python; python-indent-offset: 4; indent-tabs-mode: nil -*-
2 ##
3 # This script set linux specific flags (GNU GCC)
4 #
5 ##
6 import os
7 import SCons.Util
8
9 Import('env')
10
11 print "Reading linux configuration script"
12
13 # Set release/debug flags
14 if env.get('RELEASE'):
15         env.AppendUnique(CPPDEFINES = ['NDEBUG'])
16
17 if env.get('LOGGING'):
18     env.AppendUnique(CPPDEFINES = ['TB_LOG'])
19
20 env['CCFLAGS'] = SCons.Util.CLVar(os.environ.get('CFLAGS', ""))
21 env.AppendUnique(CPPDEFINES = ['WITH_POSIX', '__linux__'])
22 env.AppendUnique(CFLAGS = ['-std=gnu99'])
23 env.AppendUnique(CCFLAGS = ['-Wextra', '-fPIC'])
24 env.AppendUnique(LIBS = ['dl', 'pthread'])
25
26 env.AppendUnique(CCFLAGS = ['-D__TIZEN__', '-D_GNU_SOURCE', '-DTIZEN_DEBUG_ENABLE'])
27 env.ParseConfig("pkg-config dlog --cflags --libs")
28
29 # Set arch flags : It will be handled by Tizen build system.