Build fix on *BSD.

dns resolution belongs to the libc on those systems.
This commit is contained in:
David Carlier 2020-02-05 17:40:27 +00:00
parent 43cf39bdef
commit f464b95afb

View File

@ -162,7 +162,11 @@ include_directories("${PROJECT_SOURCE_DIR}/lib/bullet/src")
if(WIN32)
set(LIBRESOLV_LIBRARY)
else()
find_library(LIBRESOLV_LIBRARY NAMES resolv libresolv)
if (NOT CMAKE_SYSTEM_NAME MATCHES "BSD")
find_library(LIBRESOLV_LIBRARY NAMES resolv libresolv)
else()
set(LIBRESOLV_LIBRARY)
endif()
endif()
# Find system ENet library or build it if missing