From 5a1ec105567f064d0220d2195dd1765f609bb499 Mon Sep 17 00:00:00 2001 From: Fu Juntang <StrongTiger_001@163.com> Date: 星期五, 03 九月 2021 17:46:19 +0800 Subject: [PATCH] Merge branch 'master' of http://os.smartai.com:9091/valib/c_bhomebus --- CMakeLists.txt | 10 ++++++++-- 1 files changed, 8 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 9af847a..fd63739 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -15,11 +15,13 @@ option(BUILD_SHARED_LIBS "Build using shared libraries" ON) +add_compile_options(-fPIC) + option(BUILD_DOC "Build doc" OFF) list(APPEND EXTRA_INCLUDES "${PROJECT_SOURCE_DIR}/include/usgcommon") -list(APPEND EXTRA_LIBS ${PROJECT_SOURCE_DIR}/lib/libusgcommon.a pthread rt protobuf-lite.a) +list(APPEND EXTRA_LIBS ${PROJECT_SOURCE_DIR}/lib/libusgcommon.a pthread rt protobuf protobuf-lite.a) # build api doc if (BUILD_DOC) @@ -30,5 +32,9 @@ add_subdirectory(${PROJECT_SOURCE_DIR}/test) add_subdirectory(${PROJECT_SOURCE_DIR}/test_net_socket) add_subdirectory(${PROJECT_SOURCE_DIR}/test_socket) -# add_subdirectory(${PROJECT_SOURCE_DIR}/shm_util) + include_directories(${CMAKE_CURRENT_BINARY_DIR}/proto) + #add_subdirectory(${PROJECT_SOURCE_DIR}/shm_util) endif() + +add_definitions("-DPROTOBUF_USS_DLLS") + -- Gitblit v1.8.0