mirror of
https://github.com/id-Software/DOOM-3-BFG.git
synced 2025-03-14 22:50:45 +00:00
Merge pull request #231 from coldtobi/use_cmake_dl_libs
Do use CMAKE_DL_LIBS to determine the linkerflags needed to link against libdl
This commit is contained in:
commit
8a8deb63fd
2 changed files with 7 additions and 6 deletions
|
@ -1409,6 +1409,7 @@ if(MSVC)
|
|||
${PNG_LIBRARY}
|
||||
${JPEG_LIBRARY}
|
||||
${GLEW_LIBRARY}
|
||||
${CMAKE_DL_LIBS}
|
||||
)
|
||||
|
||||
#CMAKE_BINARY_DIR
|
||||
|
@ -1565,15 +1566,10 @@ else()
|
|||
set(RT_LIBRARY rt)
|
||||
endif()
|
||||
|
||||
if(NOT "${CMAKE_SYSTEM}" MATCHES "FreeBSD")
|
||||
set(DL_LIBRARY dl)
|
||||
endif()
|
||||
|
||||
target_link_libraries(RBDoom3BFG
|
||||
idlib
|
||||
${OPENGL_LIBRARIES}
|
||||
pthread
|
||||
${DL_LIBRARY}
|
||||
${RT_LIBRARY}
|
||||
${SDLx_LIBRARY}
|
||||
${OPENAL_LIBRARY}
|
||||
|
@ -1582,6 +1578,7 @@ else()
|
|||
${PNG_LIBRARY}
|
||||
${JPEG_LIBRARY}
|
||||
${GLEW_LIBRARY}
|
||||
${CMAKE_DL_LIBS}
|
||||
)
|
||||
endif()
|
||||
|
||||
|
|
|
@ -102,7 +102,7 @@ If you have questions concerning this license or the applicable additional terms
|
|||
#endif
|
||||
|
||||
|
||||
#elif defined(__linux__) || defined(__FreeBSD__) || defined(__APPLE__)
|
||||
#elif defined(__linux__) || defined(__FreeBSD__) || defined(__APPLE__) || defined(__GNUC__) || defined(__clang__)
|
||||
|
||||
#if defined(__i386__)
|
||||
#define CPUSTRING "x86"
|
||||
|
@ -116,6 +116,8 @@ If you have questions concerning this license or the applicable additional terms
|
|||
#define BUILD_STRING "linux-" CPUSTRING
|
||||
#elif defined(__APPLE__)
|
||||
#define BUILD_STRING "osx-" CPUSTRING
|
||||
#else
|
||||
#define BUILD_STRING "other-" CPUSTRING
|
||||
#endif
|
||||
|
||||
#define _alloca alloca
|
||||
|
@ -146,6 +148,8 @@ If you have questions concerning this license or the applicable additional terms
|
|||
#define CALLBACK
|
||||
#define __cdecl
|
||||
|
||||
#else
|
||||
#error unknown build enviorment
|
||||
#endif
|
||||
// RB end
|
||||
|
||||
|
|
Loading…
Reference in a new issue