代码拉取完成,页面将自动刷新
cmake_minimum_required(VERSION 3.0)
project(UESDK)
set(CMAKE_VERBOSE_MAKEFILE ON)
set(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} -O0 -ggdb -Wall -Wno-deprecated -Werror -Wno-unused-function -Wno-builtin-macro-redefined -Wno-unused-local-typedefs")
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/depends_libs/curl/include)
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
link_directories(${CMAKE_CURRENT_SOURCE_DIR}/depends_libs/curl/bin)
link_directories(${CMAKE_CURRENT_SOURCE_DIR}/depends_libs/curl/lib)
include(CMake/utils.cmake)
set(CMAKE_C_COMPILER "gcc")
set(CMAKE_CXX_COMPILER "g++")
include_directories("D:/PROJECTSUPPORT/boost_1_78_0")
# set(BOOST_ROOT "D:/PROJECTSUPPORT/boost_mingw530_32/lib")
# set(Boost_COMPILER -mgw53)
# # set(Boost_DEBUG ON)
# find_package(Boost COMPONENTS thread system serialization REQUIRED)
# if(Boost_FOUND)
# message(STATUS "Boost_INCLUDE_DIRS: ${Boost_INCLUDE_DIRS}")
# message(STATUS "Boost_LIBRARIES: ${Boost_LIBRARIES}")
# message(STATUS "Boost_VERSION: ${Boost_VERSION}")
# message(STATUS "Boost_LIBRARY_DIRS: ${Boost_LIBRARY_DIRS}")
# link_directories(${Boost_LIBRARY_DIRS})
# include_directories(${Boost_INCLUDE_DIRS})
# endif()
# add_definitions(-DBOOST_SYSTEM_NO_DEPRECATED)
add_definitions(-DBOOST_USE_WINDOWS_H)
set(
LIB_SRC
uesdk/http/http.cc
uesdk/http/http_connect.cc
uesdk/cJSON.cc
uesdk/user_manger.cc
uesdk/utils.cc
)
set(
LIBS
uesdk
curl
${Boost_LIBRARIES}
)
add_library(uesdk SHARED ${LIB_SRC})
target_link_libraries(uesdk curl )
target_link_libraries(uesdk ${Boost_LIBRARIES})
add_executable(test_main test/test_main.cc)
uesdk_add_executable(test_connect "test/test_connect.cc" uesdk "${LIBS}")
uesdk_add_executable(test_user_login "test/test_user_login.cc" uesdk "${LIBS}")
SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin)
SET(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin)
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。