summaryrefslogtreecommitdiff
path: root/tests/CMakeLists.txt
diff options
context:
space:
mode:
authorGlenn Strauss <gstrauss@gluelogic.com>2022-01-03 16:14:45 -0500
committerGlenn Strauss <gstrauss@gluelogic.com>2022-01-04 04:25:26 -0500
commitb9d58fa723cd3789b8fb2475696a7c596fefc961 (patch)
treeb5a799fae2ea49fc420e5cfb1368ca03de4e4af4 /tests/CMakeLists.txt
parenta931b1fce2a33d6f5ba83d585f5ccefdadaf35e1 (diff)
downloadlighttpd-git-b9d58fa723cd3789b8fb2475696a7c596fefc961.tar.gz
[build] cmake,meson socket libs for win32, Illumos (fixes #3130)
(thx devnexen) cmake, meson: specify socket libs for win32, Illumos x-ref: "Solaris build fix proposal" https://redmine.lighttpd.net/issues/3130
Diffstat (limited to 'tests/CMakeLists.txt')
-rw-r--r--tests/CMakeLists.txt10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index cfb20740..444e7430 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -1,5 +1,15 @@
add_executable(fcgi-responder fcgi-responder.c)
add_executable(scgi-responder scgi-responder.c)
+if(WIN32)
+ set(SOCKLIBS ws2_32)
+endif()
+if(CMAKE_SYSTEM_NAME MATCHES "SunOS")
+ set(SOCKLIBS socket nsl)
+endif()
+if(SOCKLIBS)
+ target_link_libraries(fcgi-responder ${SOCKLIBS})
+ target_link_libraries(scgi-responder ${SOCKLIBS})
+endif()
set(T_FILES
prepare.sh