wangzhengquan
2021-02-05 e15d6fe15898caab7180b2065fea3382ecabd3e0
update
3个文件已修改
15 ■■■■■ 已修改文件
CMakeLists.txt 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/CMakeLists.txt 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/socket/shm_mod_socket.h 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
CMakeLists.txt
@@ -11,7 +11,7 @@
# we don't need to tinker with the path to run the executable
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/lib")
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/lib")
# set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}")
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/bin")
option(BUILD_SHARED_LIBS "Build using shared libraries" ON)
src/CMakeLists.txt
@@ -28,10 +28,13 @@
./shm/hashtable.cpp
)
if (BUILD_SHARED_LIBS)
  add_library(shm_queue SHARED ${_SOURCES_})
else()
 add_library(shm_queue STATIC ${_SOURCES_})
endif()
# add_library(shm_queue SHARED ${_SOURCES_})
# add_library(shm_queue STATIC ${_SOURCES_})
add_library(shm_queue ${_SOURCES_})
#add_library(shm_queue ${_SOURCES_})
target_include_directories(shm_queue PUBLIC ${EXTRA_INCLUDES} )
src/socket/shm_mod_socket.h
@@ -36,8 +36,8 @@
    static int get_bus_sendbuf(bus_head_t &request_head, const void *topic_buf, int topic_size, const void *content_buf, int content_size, void **retbuf);
public:
    static size_t remove_keys(int keys[], size_t length);
    static size_t remove_keys_exclude(int keys[], size_t length);
    // static size_t remove_keys(int keys[], size_t length);
    // static size_t remove_keys_exclude(int keys[], size_t length);
  // bus header 编码为网络传输的字节
  static void * encode_bus_head(bus_head_t & bushead);