SET (WITH_TEST_SUITE CACHE BOOL "")
SET (NO_OFFENSIVE CACHE BOOL "Exclude the offensive option.")
+SET (USE_WIN32_REGEX_LIBS CACHE BOOL "")
SET (LOCALDIR "${CMAKE_INSTALL_PREFIX}/local/share/games/fortunes" CACHE STRING "LOCALDIR fortunes dir")
SET (LOCALODIR "${LOCALDIR}/off" CACHE STRING "offensive fortunes localdir")
SET (COOKIEDIR "${CMAKE_INSTALL_PREFIX}/share/games/fortunes" CACHE STRING "cookie dir not under /usr/local")
endif()
if (WIN32)
# See https://stackoverflow.com/questions/15119639/how-to-link-winsock-in-cmake
- list(APPEND _libs intl regex wsock32 ws2_32)
+ if (USE_WIN32_REGEX_LIBS)
+ list(APPEND _libs intl regex)
+ endif()
+ list(APPEND _libs wsock32 ws2_32)
endif()
TARGET_LINK_LIBRARIES("${exe}" ${_libs})
if (NOT ("${dir}" STREQUAL "null"))