Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

added ws2_32 and wsock32 target libraries to cmake files that is require...#355

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
deanberris merged 1 commit intocpp-netlib:0.11-develfromtghosgor:0.11-devel
Jan 6, 2014
Merged
Show file tree
Hide file tree
Changes fromall commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
added ws2_32 and wsock32 target libraries to cmake files that is requ…
…ired to build under mingw
  • Loading branch information
@tghosgor
tghosgor committedDec 31, 2013
commit2d7f5c0996e75e0db7648cbd4b13b2b3e3fd5507
10 changes: 7 additions & 3 deletionslibs/mime/test/CMakeLists.txt
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
include_directories(${CPP-NETLIB_SOURCE_DIR})
file ( COPY TestMessages DESTINATION ${CMAKE_CURRENT_BINARY_DIR} )

if ( Boost_FOUND )
#This test causes a "too many sections" error on Windows MinGW64
#(MSVC has /bigobj, MinGW does not)
if (NOT(${CMAKE_CXX_COMPILER_ID} MATCHES GNU AND ${CMAKE_SYSTEM_NAME} MATCHES "Windows"))
if ( Boost_FOUND )
add_executable ( mime-roundtrip mime-roundtrip.cpp )
target_link_libraries ( mime-roundtrip ${Boost_LIBRARIES}
${CMAKE_THREAD_LIBS_INIT})
add_test ( mime-roundtrip mime-roundtrip )
endif ()
add_test ( mime-roundtrip ${CPP-NETLIB_BINARY_DIR}/tests/mime-roundtrip )
endif ()
endif()

11 changes: 11 additions & 0 deletionslibs/network/example/CMakeLists.txt
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -99,6 +99,17 @@ if (OPENSSL_FOUND)
target_link_libraries(hello_world_async_server_with_work_queue ${OPENSSL_LIBRARIES})
endif (OPENSSL_FOUND)

if (${CMAKE_CXX_COMPILER_ID} MATCHES GNU AND ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
target_link_libraries(http_client ws2_32)
target_link_libraries(simple_wget ws2_32)
target_link_libraries(atom_reader ws2_32)
target_link_libraries(rss_reader ws2_32)
target_link_libraries(twitter_search ws2_32)
target_link_libraries(hello_world_server ws2_32 wsock32)
target_link_libraries(hello_world_client ws2_32)
target_link_libraries(hello_world_async_server_with_work_queue ws2_32 wsock32)
endif()

if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(http_client rt)
target_link_libraries(simple_wget rt)
Expand Down
13 changes: 8 additions & 5 deletionslibs/network/test/CMakeLists.txt
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -22,14 +22,17 @@ if (Boost_FOUND)
PROPERTIES COMPILE_FLAGS "-Wall")
endif()
add_executable(cpp-netlib-${test} ${test}.cpp)
add_dependencies(cpp-netlib-${test} cppnetlib-uri)
add_dependencies(cpp-netlib-${test} cppnetlib-uri)
target_link_libraries(cpp-netlib-${test} ${Boost_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} cppnetlib-uri)
if (OPENSSL_FOUND)
target_link_libraries(cpp-netlib-${test} ${OPENSSL_LIBRARIES})
target_link_libraries(cpp-netlib-${test} ${OPENSSL_LIBRARIES})
endif()
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(cpp-netlib-${test} rt)
endif()
if (${CMAKE_CXX_COMPILER_ID} MATCHES GNU AND ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
target_link_libraries(cpp-netlib-${test} ws2_32 wsock32)
endif()
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(cpp-netlib-${test} rt)
endif()
set_target_properties(cpp-netlib-${test}
PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CPP-NETLIB_BINARY_DIR}/tests)
add_test(cpp-netlib-${test}
Expand Down
29 changes: 19 additions & 10 deletionslibs/network/test/http/CMakeLists.txt
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -14,7 +14,7 @@ endif()
if (Boost_FOUND)
set ( TESTS
request_incremental_parser_test
request_linearize_test
request_linearize_test
)
foreach ( test ${TESTS} )
add_executable(cpp-netlib-http-${test} ${test}.cpp)
Expand All@@ -23,9 +23,12 @@ if (Boost_FOUND)
target_link_libraries(cpp-netlib-http-${test}
${Boost_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT}
cppnetlib-uri)
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(cpp-netlib-http-${test} rt)
endif()
if (${CMAKE_CXX_COMPILER_ID} MATCHES GNU AND ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
target_link_libraries(cpp-netlib-http-${test} ws2_32)
endif()
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(cpp-netlib-http-${test} rt)
endif()
set_target_properties(cpp-netlib-http-${test}
PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CPP-NETLIB_BINARY_DIR}/tests)
add_test(cpp-netlib-http-${test}
Expand All@@ -50,9 +53,12 @@ if (Boost_FOUND)
if (OPENSSL_FOUND)
target_link_libraries(cpp-netlib-http-${test} ${OPENSSL_LIBRARIES})
endif()
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(cpp-netlib-http-${test} rt)
endif()
if (${CMAKE_CXX_COMPILER_ID} MATCHES GNU AND ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
target_link_libraries(cpp-netlib-http-${test} ws2_32)
endif()
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(cpp-netlib-http-${test} rt)
endif()
set_target_properties(cpp-netlib-http-${test}
PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CPP-NETLIB_BINARY_DIR}/tests)
add_test(cpp-netlib-http-${test}
Expand All@@ -68,9 +74,12 @@ if (Boost_FOUND)
add_executable(cpp-netlib-http-${test} ${test}.cpp)
add_dependencies(cpp-netlib-http-${test} cppnetlib-server-parsers)
target_link_libraries(cpp-netlib-http-${test} ${Boost_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} cppnetlib-server-parsers)
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(cpp-netlib-http-${test} rt)
endif()
if (${CMAKE_CXX_COMPILER_ID} MATCHES GNU AND ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
target_link_libraries(cpp-netlib-http-${test} ws2_32 wsock32)
endif()
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries(cpp-netlib-http-${test} rt)
endif()
set_target_properties(cpp-netlib-http-${test}
PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CPP-NETLIB_BINARY_DIR}/tests)
add_test(cpp-netlib-http-${test}
Expand Down
5 changes: 4 additions & 1 deletionlibs/network/test/uri/CMakeLists.txt
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -24,8 +24,11 @@ if (Boost_FOUND)
target_link_libraries(cpp-netlib-${test}
${Boost_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} cppnetlib-uri)
if (OPENSSL_FOUND)
target_link_libraries(cpp-netlib-${test} ${OPENSSL_LIBRARIES})
target_link_libraries(cpp-netlib-${test} ${OPENSSL_LIBRARIES})
endif()
if (${CMAKE_CXX_COMPILER_ID} MATCHES GNU AND ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
target_link_libraries(cpp-netlib-${test} ws2_32)
endif()
set_target_properties(cpp-netlib-${test}
PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CPP-NETLIB_BINARY_DIR}/tests)
add_test(cpp-netlib-${test}
Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp