things-manager: libTGMSDKLibrary.so: add missing depending library
authorHauke Mehrtens <hauke.mehrtens@lantiq.com>
Tue, 21 Jul 2015 20:06:52 +0000 (22:06 +0200)
committerUze Choi <uzchoi@samsung.com>
Fri, 24 Jul 2015 10:18:22 +0000 (10:18 +0000)
libTGMSDKLibrary.so also depends on liboc.so, liboctbstack.so and
pthread, this patch adds these dependencies to the build.

Without this the dynamic loader will not automatically load these
libraries and it could result in unresolved dependencies at runtime.

Change-Id: I174b38e747be247fc25544db629f8ad2b7eb5ef5
Signed-off-by: Hauke Mehrtens <hauke.mehrtens@lantiq.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1795
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
service/things-manager/SConscript

index 0ae8a81..7086b43 100644 (file)
@@ -35,17 +35,20 @@ target_os = env.get('TARGET_OS')
 ######################################################################
 things_manager_env.AppendUnique(CPPPATH = ['../../extlibs/timer', 'sdk/inc', 'sdk/src'])
 
+things_manager_env.PrependUnique(LIBS = ['oc', 'octbstack'])
+
 if target_os not in ['windows', 'winrt']:
     things_manager_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall'])
     if target_os != 'android':
         things_manager_env.AppendUnique(CXXFLAGS = ['-pthread'])
+        things_manager_env.AppendUnique(LIBS = ['pthread'])
 
 if target_os not in ['darwin', 'ios', 'windows', 'winrt']:
     things_manager_env.AppendUnique(LINKFLAGS = ['-Wl,--no-undefined'])
 
 if target_os == 'android':
     things_manager_env.AppendUnique(CXXFLAGS = ['-frtti', '-fexceptions'])
-    things_manager_env.PrependUnique(LIBS = ['oc', 'octbstack', 'gnustl_shared'])
+    things_manager_env.PrependUnique(LIBS = ['gnustl_shared'])
 
 ######################################################################
 # Source files and Targets