diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 2438c2ea..cd50b41d 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -12,6 +12,12 @@ if(CYGWIN) endif(CYGWIN) if(UNIX) + if(_GLFW_HAS_XRANDR) + set(GLFW_PKGLIBS "${GLFW_PKGLIBS} xrandr") + endif(_GLFW_HAS_XRANDR) + if(_GLFW_HAS_XF86VIDMODE) + set(GLFW_PKGLIBS "${GLFW_PKGLIBS} xxf86vm") + endif(_GLFW_HAS_XF86VIDMODE) configure_file(${CMAKE_CURRENT_SOURCE_DIR}/libglfw.pc.cmake ${CMAKE_CURRENT_BINARY_DIR}/libglfw.pc @ONLY) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libglfw.pc DESTINATION lib/pkgconfig) diff --git a/src/libglfw.pc.cmake b/src/libglfw.pc.cmake index e69de29b..47cfb4f5 100644 --- a/src/libglfw.pc.cmake +++ b/src/libglfw.pc.cmake @@ -0,0 +1,12 @@ +prefix=@CMAKE_INSTALL_PREFIX@ +exec_prefix=${prefix} +includedir=${prefix}/include +libdir=${exec_prefix}/lib + +Name: GLFW +Description: A portable library for OpenGL, window and input +Version: 3.0.0 +URL: http://www.glfw.org/ +Requires.private: gl x11 @GLFW_PKGLIBS@ +Libs: -L${libdir} -lglfw +Cflags: -I${includedir}