mirror of
https://github.com/glfw/glfw.git
synced 2025-10-04 13:46:37 +00:00
Add GLFW includes to target_include_directories
This makes it easier to build GLFW as a sub-project of another CMake based project. Instead of having to use include_directories(path/to/glfw/include) the project using GLFW will get the correct include path by just doing target_link_libraries(myapp glfw ${GLFW_LIBRARIES}).
This commit is contained in:
parent
832c2ffa3b
commit
e5601f1619
@ -64,6 +64,9 @@ target_include_directories(glfw PRIVATE
|
||||
"${GLFW_BINARY_DIR}/src"
|
||||
${glfw_INCLUDE_DIRS})
|
||||
|
||||
# Make the public GLFW includes available for users of the GLFW library.
|
||||
target_include_directories(glfw PUBLIC "${GLFW_SOURCE_DIR}/include")
|
||||
|
||||
# HACK: When building on MinGW, WINVER and UNICODE need to be defined before
|
||||
# the inclusion of stddef.h (by glfw3.h), which is itself included before
|
||||
# win32_platform.h. We define them here until a saner solution can be found
|
||||
|
Loading…
Reference in New Issue
Block a user