link against pthreads using cmake when building under Linux, shared libs
(linking against pthreads is just a workaround for buggy NVidia drivers that require it)
This commit is contained in:
1 parent
2a1ac61c4d
commit
a164245915
1 file changed
+8
-1
@@ -53,6 +53,13 @@ endif ()
|
||||
|
||||
if (BUILD_SHARED_LIBS)
|
||||
target_link_libraries(OpenGLWindow Bullet3Common)
|
||||
if (WIN32 OR APPLE)
|
||||
target_link_libraries(OpenGLWindow ${OPENGL_gl_LIBRARY})
|
||||
else()
|
||||
set (CMAKE_THREAD_PREFER_PTHREAD TRUE)
|
||||
FIND_PACKAGE(Threads)
|
||||
target_link_libraries(OpenGLWindow ${CMAKE_THREAD_LIBS_INIT})
|
||||
endif()
|
||||
endif()
|
||||
|
||||
target_link_libraries(OpenGLWindow ${OPENGL_gl_LIBRARY})
|
||||
#target_link_libraries(OpenGLWindow ${OPENGL_gl_LIBRARY})
|
||||
Reference in new issue
Block a user