Skip to content

Commit

Permalink
openbsd's port fix for non Linux systems w/o libRT
Browse files Browse the repository at this point in the history
X11 headers are not always in expected locations, add them to include list.

Modifications by est31: indentation fixes, commit message improved
  • Loading branch information
devnexen authored and est31 committed Jul 3, 2016
1 parent 80cebdc commit b6eef1c
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/CMakeLists.txt
Expand Up @@ -336,7 +336,10 @@ else()
if(APPLE)
set(PLATFORM_LIBS "-framework CoreFoundation" ${PLATFORM_LIBS})
else()
set(PLATFORM_LIBS -lrt ${PLATFORM_LIBS})
check_library_exists(rt clock_gettime "" HAVE_LIBRT)
if (HAVE_LIBRT)
set(PLATFORM_LIBS -lrt ${PLATFORM_LIBS})
endif(HAVE_LIBRT)
endif(APPLE)

# This way Xxf86vm is found on OpenBSD too
Expand Down Expand Up @@ -555,6 +558,7 @@ include_directories(
${LUA_INCLUDE_DIR}
${GMP_INCLUDE_DIR}
${JSON_INCLUDE_DIR}
${X11_INCLUDE_DIR}
${PROJECT_SOURCE_DIR}/script
)

Expand Down

0 comments on commit b6eef1c

Please sign in to comment.