Use third_party_libs.scons of resource in resource-directory
authorHabib Virji <habib.virji@samsung.com>
Fri, 28 Oct 2016 13:21:33 +0000 (14:21 +0100)
committerUze Choi <uzchoi@samsung.com>
Mon, 31 Oct 2016 04:02:04 +0000 (04:02 +0000)
resource-directory was moved to resource layer from service
layer. so third_party_libs.scons of resource should be used.

Change-Id: I9d1f06f041318443b62d78242b8bc04f77a6f4f3
Signed-off-by: Habib Virji <habib.virji@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/13769
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hyuna Jo <hyuna0213.jo@samsung.com>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
resource/csdk/resource-directory/samples/SConscript
resource/csdk/resource-directory/unittests/SConscript

index 0e98a20..aced00c 100644 (file)
 Import('env')
 
 lib_env = env.Clone()
-SConscript('#service/third_party_libs.scons', 'lib_env')
+SConscript('#resource/third_party_libs.scons', 'lib_env')
 
 rd_sample_app_env = lib_env.Clone()
 
 target_os = env.get('TARGET_OS')
+src_dir = env.get('SRC_DIR')
 ######################################################################
 # Build flags
 ######################################################################
-rd_sample_app_env.AppendUnique(CPPPATH = ['../include'])
+rd_sample_app_env.AppendUnique(CPPPATH = ['../include',
+                                          '../src/internal',
+                                          src_dir + '/resource/csdk/stack/include',
+                                          src_dir + '/resource/include',
+                                          src_dir + '/resource/oc_logger/include',])
 
 if target_os not in ['windows']:
     rd_sample_app_env.AppendUnique(CXXFLAGS = ['-O2', '-g', '-Wall', '-Wextra', '-std=c++0x'])
index ba5bc2b..7768b15 100644 (file)
@@ -36,7 +36,7 @@ if lib_env.get('LOGGING'):
     lib_env.AppendUnique(CPPDEFINES = ['TB_LOG'])
 
 # Add third party libraries
-SConscript('#service/third_party_libs.scons', 'lib_env')
+SConscript('#resource/third_party_libs.scons', 'lib_env')
 
 if target_os in ['linux']:
     # Verify that 'hippomocks' mocking code is installed.  If not,
@@ -57,16 +57,15 @@ rd_test_env.AppendUnique(
         CPPPATH = [
                 src_dir + '/extlibs/hippomocks-master',
                 '../include',
-                '../../stack/test/',
-        ])
+                src_dir + '/resource/include',
+                src_dir + '/resource/csdk/stack/include',
+                src_dir + '/resource/csdk/stack/test/',
+                src_dir + '/resource/oc_logger/include',])
 
-rd_test_env.PrependUnique(LIBS = [
-    'connectivity_abstraction',
-    'oc_logger',
-    'oc_logger_core',
-    'octbstack',
-    'oc',
-    'resource_directory'])
+
+rd_test_env.AppendUnique(LIBPATH = [lib_env.get('BUILD_DIR')])
+rd_test_env.AppendUnique(RPATH = [lib_env.get('BUILD_DIR')])
+rd_test_env.PrependUnique(LIBS = ['resource_directory', 'octbstack' ])
 
 if rd_test_env.get('RD_MODE'):
     rd_mode = rd_test_env.get('RD_MODE')