mirror of
https://github.com/glfw/glfw.git
synced 2025-10-05 06:06:36 +00:00
Fix build on OpenBSD
OpenBSD lacks librt, but provides its functionality in base libc.
This commit is contained in:
parent
f29c963030
commit
063799a116
@ -199,11 +199,13 @@ endif()
|
||||
# Find and add Unix math and time libraries
|
||||
#--------------------------------------------------------------------
|
||||
if (UNIX AND NOT APPLE)
|
||||
find_library(RT_LIBRARY rt)
|
||||
mark_as_advanced(RT_LIBRARY)
|
||||
if (RT_LIBRARY)
|
||||
list(APPEND glfw_LIBRARIES "${RT_LIBRARY}")
|
||||
list(APPEND glfw_PKG_LIBS "-lrt")
|
||||
if (NOT ${CMAKE_SYSTEM_NAME} MATCHES "OpenBSD")
|
||||
find_library(RT_LIBRARY rt)
|
||||
mark_as_advanced(RT_LIBRARY)
|
||||
if (RT_LIBRARY)
|
||||
list(APPEND glfw_LIBRARIES "${RT_LIBRARY}")
|
||||
list(APPEND glfw_PKG_LIBS "-lrt")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
find_library(MATH_LIBRARY m)
|
||||
|
Loading…
Reference in New Issue
Block a user