mirror of
https://github.com/minetest/irrlicht.git
synced 2025-02-11 09:00:24 +01:00
Work around cmake<3.12 object target rules
CMake does not allow specifying usage requirements with target_link_libraries() until version 3.12.
This commit is contained in:
parent
0aa0331d46
commit
636951d304
@ -308,6 +308,7 @@ set(link_libs
|
|||||||
"${ZLIB_LIBRARY}"
|
"${ZLIB_LIBRARY}"
|
||||||
"${JPEG_LIBRARY}"
|
"${JPEG_LIBRARY}"
|
||||||
"${PNG_LIBRARY}"
|
"${PNG_LIBRARY}"
|
||||||
|
tinygltf::tinygltf
|
||||||
"$<$<BOOL:${USE_SDL2}>:${SDL2_LIBRARIES}>"
|
"$<$<BOOL:${USE_SDL2}>:${SDL2_LIBRARIES}>"
|
||||||
|
|
||||||
${OPENGL_LIBRARIES}
|
${OPENGL_LIBRARIES}
|
||||||
@ -341,7 +342,18 @@ add_library(IRRMESHOBJ OBJECT
|
|||||||
${IRRMESHLOADER}
|
${IRRMESHLOADER}
|
||||||
)
|
)
|
||||||
|
|
||||||
target_link_libraries(IRRMESHOBJ PRIVATE tinygltf::tinygltf)
|
get_property(tinygltf_INCLUDE_DIRS
|
||||||
|
TARGET tinygltf::tinygltf
|
||||||
|
PROPERTY INTERFACE_INCLUDE_DIRECTORIES
|
||||||
|
)
|
||||||
|
|
||||||
|
get_property(tinygltf_COMPILE_DEFS
|
||||||
|
TARGET tinygltf::tinygltf
|
||||||
|
PROPERTY INTERFACE_COMPILE_DEFINITIONS
|
||||||
|
)
|
||||||
|
|
||||||
|
target_include_directories(IRRMESHOBJ PRIVATE ${tinygltf_INCLUDE_DIRS})
|
||||||
|
target_compile_definitions(IRRMESHOBJ PUBLIC ${tinygltf_COMPILE_DEFS})
|
||||||
|
|
||||||
add_library(IRROBJ OBJECT
|
add_library(IRROBJ OBJECT
|
||||||
CBillboardSceneNode.cpp
|
CBillboardSceneNode.cpp
|
||||||
|
Loading…
Reference in New Issue
Block a user