From e685bc0c2950aa682dc62cb73b418c3305ce0b14 Mon Sep 17 00:00:00 2001 From: YounghyunJoo Date: Wed, 22 Jul 2015 21:34:04 +0900 Subject: [PATCH] Remove boost library dependency on PPM module. Change-Id: Ic8710ec19e0417d912869a0a24c7e476a932acf0 Signed-off-by: YounghyunJoo Reviewed-on: https://gerrit.iotivity.org/gerrit/1810 Tested-by: jenkins-iotivity Reviewed-by: Uze Choi --- service/protocol-plugin/plugin-manager/SConscript | 2 +- .../plugin-manager/src/Android/jni/Android.mk | 15 +-------------- .../plugin-manager/src/Android/jni/SConscript | 2 +- .../protocol-plugin/plugin-manager/src/CpluffAdapter.cpp | 14 -------------- .../protocol-plugin/plugin-manager/src/CpluffAdapter.h | 3 --- service/protocol-plugin/plugin-manager/src/FelixAdapter.h | 3 --- .../plugin-manager/src/PluginManagerImpl.h | 1 + service/protocol-plugin/sample-app/linux/SConscript | 2 +- .../sample-app/tizen/PPMSampleApp/.cproject | 4 ---- 9 files changed, 5 insertions(+), 41 deletions(-) diff --git a/service/protocol-plugin/plugin-manager/SConscript b/service/protocol-plugin/plugin-manager/SConscript index f002b78..25edfce 100644 --- a/service/protocol-plugin/plugin-manager/SConscript +++ b/service/protocol-plugin/plugin-manager/SConscript @@ -28,7 +28,7 @@ if target_os not in ['windows', 'winrt']: if target_os == 'android': plugin_manager_env.AppendUnique(CXXFLAGS = ['-frtti', '-fexceptions', '-DANDROID']) - plugin_manager_env.AppendUnique(LIBS = ['boost_thread', 'boost_system', 'gnustl_shared', 'log']) + plugin_manager_env.AppendUnique(LIBS = ['gnustl_shared', 'log']) plugin_manager_env.AppendUnique(CPPDEFINES = ['CP_C_API=CP_EXPORT', 'CP_HOST=\"\\"'+env.get('TARGET_OS')+'\\"\"', diff --git a/service/protocol-plugin/plugin-manager/src/Android/jni/Android.mk b/service/protocol-plugin/plugin-manager/src/Android/jni/Android.mk index 9bf9102..e7203dd 100644 --- a/service/protocol-plugin/plugin-manager/src/Android/jni/Android.mk +++ b/service/protocol-plugin/plugin-manager/src/Android/jni/Android.mk @@ -6,16 +6,6 @@ LOCAL_SRC_FILES := ../../../../../../dep/android/armeabi/usr/lib/libexpat.so include $(PREBUILT_SHARED_LIBRARY) include $(CLEAR_VARS) -LOCAL_MODULE := libboost_thread -LOCAL_SRC_FILES := ../../../../../../dep/android/armeabi/usr/lib/libboost_thread.a -include $(PREBUILT_STATIC_LIBRARY) - -include $(CLEAR_VARS) -LOCAL_MODULE := libboost_system -LOCAL_SRC_FILES := ../../../../../../dep/android/armeabi/usr/lib/libboost_system.a -include $(PREBUILT_STATIC_LIBRARY) - -include $(CLEAR_VARS) LOCAL_MODULE := libcpluff LOCAL_SRC_FILES := ../../../../../../out/android/armeabi/release/libcpluff.a include $(PREBUILT_STATIC_LIBRARY) @@ -35,12 +25,9 @@ LOCAL_LDLIBS := -llog -ldl -lz LOCAL_STATIC_LIBRARIES := libcpluff LOCAL_STATIC_LIBRARIES += libpmimpl -LOCAL_STATIC_LIBRARIES += libboost_thread -LOCAL_STATIC_LIBRARIES += libboost_system LOCAL_STATIC_LIBRARIES += libexpat -LOCAL_C_INCLUDES := ../../../../../../extlibs/boost/boost_1_58_0 -LOCAL_C_INCLUDES += ../../../../lib/cpluff/libcpluff +LOCAL_C_INCLUDES := ../../../../lib/cpluff/libcpluff LOCAL_C_INCLUDES += ../../../src LOCAL_C_INCLUDES += ../../../../../../extlibs/rapidxml diff --git a/service/protocol-plugin/plugin-manager/src/Android/jni/SConscript b/service/protocol-plugin/plugin-manager/src/Android/jni/SConscript index 7498767..9b54f72 100644 --- a/service/protocol-plugin/plugin-manager/src/Android/jni/SConscript +++ b/service/protocol-plugin/plugin-manager/src/Android/jni/SConscript @@ -18,7 +18,7 @@ ppm_sdk = env.get('SRC_DIR') + '/service/protocol-plugin/plugin-manager' ###################################################################### ppm_jni_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-DLINUX', '-DNDEBUG']) ppm_jni_env.AppendUnique(CXXFLAGS = ['-frtti', '-fexceptions']) -ppm_jni_env.PrependUnique(LIBS = ['pmimpl', 'ppm', 'expat', 'cpluff', 'boost_system', 'boost_thread', 'gnustl_shared', 'log']) +ppm_jni_env.PrependUnique(LIBS = ['pmimpl', 'ppm', 'expat', 'cpluff', 'gnustl_shared', 'log']) ppm_jni_env.AppendUnique(CPPPATH = [ppm_sdk+'/src']) ppm_jni_env.AppendUnique(CPPPATH = [ppm_sdk+'/../lib/cpluff/libcpluff']) diff --git a/service/protocol-plugin/plugin-manager/src/CpluffAdapter.cpp b/service/protocol-plugin/plugin-manager/src/CpluffAdapter.cpp index b4b641f..e2b3d68 100644 --- a/service/protocol-plugin/plugin-manager/src/CpluffAdapter.cpp +++ b/service/protocol-plugin/plugin-manager/src/CpluffAdapter.cpp @@ -194,20 +194,6 @@ int CpluffAdapter::loadPluginInfoToManager(const std::string path) } if (plugin_compare_flag) { - //Auto plugin detection is disabled - /* - try - { - boost::thread *t = new boost::thread(boost::bind(&CpluffAdapter::observePluginPath, - //this, (void *)path.c_str())); - this, (void *)m_cp_plugins[i]->plugin_path)); - m_thread_g.add_thread(t); - } - catch (...) - { - printf("thread throw exception\n"); - } - */ m_plugins.push_back(*plugin); delete(plugin); } diff --git a/service/protocol-plugin/plugin-manager/src/CpluffAdapter.h b/service/protocol-plugin/plugin-manager/src/CpluffAdapter.h index 2248665..221c305 100644 --- a/service/protocol-plugin/plugin-manager/src/CpluffAdapter.h +++ b/service/protocol-plugin/plugin-manager/src/CpluffAdapter.h @@ -34,8 +34,6 @@ #include #include #include -#include -#include #include #include "Plugin.h" @@ -196,7 +194,6 @@ namespace OIC cp_status_t m_status; cp_plugin_info_t **m_cp_plugins; cp_plugin_info_t *m_plugin; - //boost::thread_group m_thread_g; static CpluffAdapter *s_pinstance; /** diff --git a/service/protocol-plugin/plugin-manager/src/FelixAdapter.h b/service/protocol-plugin/plugin-manager/src/FelixAdapter.h index f4d655d..c19f458 100644 --- a/service/protocol-plugin/plugin-manager/src/FelixAdapter.h +++ b/service/protocol-plugin/plugin-manager/src/FelixAdapter.h @@ -34,8 +34,6 @@ #include #include #include -#include -#include #include #include @@ -186,7 +184,6 @@ namespace OIC Config *config; typedef std::map File_list; std::vector m_plugins; - boost::thread m_file_detect_thread; static FelixAdapter *s_pinstance; diff --git a/service/protocol-plugin/plugin-manager/src/PluginManagerImpl.h b/service/protocol-plugin/plugin-manager/src/PluginManagerImpl.h index c49768b..39f0e95 100644 --- a/service/protocol-plugin/plugin-manager/src/PluginManagerImpl.h +++ b/service/protocol-plugin/plugin-manager/src/PluginManagerImpl.h @@ -27,6 +27,7 @@ #include "Plugin.h" #include "CpluffAdapter.h" +#include #ifdef ANDROID #include "FelixAdapter.h" diff --git a/service/protocol-plugin/sample-app/linux/SConscript b/service/protocol-plugin/sample-app/linux/SConscript index 0a40553..5c35aa1 100644 --- a/service/protocol-plugin/sample-app/linux/SConscript +++ b/service/protocol-plugin/sample-app/linux/SConscript @@ -41,7 +41,7 @@ if target_os not in ['windows', 'winrt']: sample_env.AppendUnique(LIBS = ['oc', 'oc_logger', 'octbstack', 'connectivity_abstraction', 'coap', - 'ppm', 'boost_system', 'pmimpl', 'dl']) + 'ppm', 'pmimpl', 'dl']) if env.get('SECURED') == '1': sample_env.AppendUnique(LIBS = ['tinydtls']) diff --git a/service/protocol-plugin/sample-app/tizen/PPMSampleApp/.cproject b/service/protocol-plugin/sample-app/tizen/PPMSampleApp/.cproject index 3d37aad..519f982 100644 --- a/service/protocol-plugin/sample-app/tizen/PPMSampleApp/.cproject +++ b/service/protocol-plugin/sample-app/tizen/PPMSampleApp/.cproject @@ -227,8 +227,6 @@ - -