|
|
@ -154,6 +154,9 @@ endif() |
|
|
|
# Use Win32 for window creation |
|
|
|
# Use Win32 for window creation |
|
|
|
#-------------------------------------------------------------------- |
|
|
|
#-------------------------------------------------------------------- |
|
|
|
if (_GLFW_WIN32) |
|
|
|
if (_GLFW_WIN32) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
set(GLFW_PKG_LIBS "${GLFW_PKG_LIBS} -lgdi32 -lwinmm") |
|
|
|
|
|
|
|
|
|
|
|
# The DLL links against winmm; the static library loads it |
|
|
|
# The DLL links against winmm; the static library loads it |
|
|
|
# That way, both code paths receive testing |
|
|
|
# That way, both code paths receive testing |
|
|
|
if (BUILD_SHARED_LIBS) |
|
|
|
if (BUILD_SHARED_LIBS) |
|
|
@ -180,8 +183,12 @@ endif() |
|
|
|
# Use WGL for context creation |
|
|
|
# Use WGL for context creation |
|
|
|
#-------------------------------------------------------------------- |
|
|
|
#-------------------------------------------------------------------- |
|
|
|
if (_GLFW_WGL) |
|
|
|
if (_GLFW_WGL) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
set(GLFW_PKG_LIBS "${GLFW_PKG_LIBS} -lopengl32") |
|
|
|
|
|
|
|
|
|
|
|
list(APPEND glfw_INCLUDE_DIRS ${OPENGL_INCLUDE_DIR}) |
|
|
|
list(APPEND glfw_INCLUDE_DIRS ${OPENGL_INCLUDE_DIR}) |
|
|
|
list(APPEND glfw_LIBRARIES ${OPENGL_gl_LIBRARY}) |
|
|
|
list(APPEND glfw_LIBRARIES ${OPENGL_gl_LIBRARY}) |
|
|
|
|
|
|
|
|
|
|
|
endif() |
|
|
|
endif() |
|
|
|
|
|
|
|
|
|
|
|
#-------------------------------------------------------------------- |
|
|
|
#-------------------------------------------------------------------- |
|
|
@ -308,9 +315,7 @@ if (_GLFW_EGL) |
|
|
|
list(APPEND glfw_INCLUDE_DIRS ${EGL_INCLUDE_DIR}) |
|
|
|
list(APPEND glfw_INCLUDE_DIRS ${EGL_INCLUDE_DIR}) |
|
|
|
list(APPEND glfw_LIBRARIES ${EGL_LIBRARY}) |
|
|
|
list(APPEND glfw_LIBRARIES ${EGL_LIBRARY}) |
|
|
|
|
|
|
|
|
|
|
|
if (UNIX) |
|
|
|
set(GLFW_PKG_DEPS "${GLFW_PKG_DEPS} egl") |
|
|
|
set(GLFW_PKG_DEPS "${GLFW_PKG_DEPS} egl") |
|
|
|
|
|
|
|
endif() |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (_GLFW_USE_OPENGL) |
|
|
|
if (_GLFW_USE_OPENGL) |
|
|
|
list(APPEND glfw_LIBRARIES ${OPENGL_gl_LIBRARY}) |
|
|
|
list(APPEND glfw_LIBRARIES ${OPENGL_gl_LIBRARY}) |
|
|
@ -397,10 +402,8 @@ configure_file(${GLFW_SOURCE_DIR}/src/glfwConfig.cmake.in |
|
|
|
configure_file(${GLFW_SOURCE_DIR}/src/glfwConfigVersion.cmake.in |
|
|
|
configure_file(${GLFW_SOURCE_DIR}/src/glfwConfigVersion.cmake.in |
|
|
|
${GLFW_BINARY_DIR}/src/glfwConfigVersion.cmake @ONLY) |
|
|
|
${GLFW_BINARY_DIR}/src/glfwConfigVersion.cmake @ONLY) |
|
|
|
|
|
|
|
|
|
|
|
if (UNIX) |
|
|
|
configure_file(${GLFW_SOURCE_DIR}/src/glfw3.pc.in |
|
|
|
configure_file(${GLFW_SOURCE_DIR}/src/glfw3.pc.in |
|
|
|
${GLFW_BINARY_DIR}/src/glfw3.pc @ONLY) |
|
|
|
${GLFW_BINARY_DIR}/src/glfw3.pc @ONLY) |
|
|
|
|
|
|
|
endif() |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#-------------------------------------------------------------------- |
|
|
|
#-------------------------------------------------------------------- |
|
|
|
# Add subdirectories |
|
|
|
# Add subdirectories |
|
|
@ -431,11 +434,9 @@ if (GLFW_INSTALL) |
|
|
|
${GLFW_BINARY_DIR}/src/glfwConfigVersion.cmake |
|
|
|
${GLFW_BINARY_DIR}/src/glfwConfigVersion.cmake |
|
|
|
DESTINATION lib${LIB_SUFFIX}/cmake/glfw) |
|
|
|
DESTINATION lib${LIB_SUFFIX}/cmake/glfw) |
|
|
|
|
|
|
|
|
|
|
|
if (UNIX) |
|
|
|
install(EXPORT glfwTargets DESTINATION lib${LIB_SUFFIX}/cmake/glfw) |
|
|
|
install(EXPORT glfwTargets DESTINATION lib${LIB_SUFFIX}/cmake/glfw) |
|
|
|
install(FILES ${GLFW_BINARY_DIR}/src/glfw3.pc |
|
|
|
install(FILES ${GLFW_BINARY_DIR}/src/glfw3.pc |
|
|
|
DESTINATION lib${LIB_SUFFIX}/pkgconfig) |
|
|
|
DESTINATION lib${LIB_SUFFIX}/pkgconfig) |
|
|
|
|
|
|
|
endif() |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Only generate this target if no higher-level project already has |
|
|
|
# Only generate this target if no higher-level project already has |
|
|
|
if (NOT TARGET uninstall) |
|
|
|
if (NOT TARGET uninstall) |
|
|
|