Skip to content

Commit 1d04822

Browse files
author
Alexandre jublot
committed
refactor: use the Find script for render-modules dependency
1 parent d70c838 commit 1d04822

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

cmake/FindRenderCore.cmake renamed to CMake/FindRenderModules.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
if(NOT TARGET render-modules)
32
include(FetchContent)
43

@@ -9,4 +8,5 @@ if(NOT TARGET render-modules)
98
)
109

1110
FetchContent_MakeAvailable(render-modules)
12-
endif()
11+
get_target_property(render-modules-icls render-modules INTERFACE_INCLUDE_DIRECTORIES)
12+
endif()

CMakeLists.txt

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ endif()
1717
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3")
1818

1919
include(CMake/FindPolymorphEngine.cmake)
20-
include(cmake/FindRenderCore.cmake)
20+
include(CMake/FindRenderModules.cmake)
2121

2222
file(GLOB_RECURSE SCRIPTS_SRC Scripts/src/*.cpp)
2323
file(GLOB_RECURSE SCRIPTS_ICL Scripts/include/*.hpp)
@@ -28,7 +28,6 @@ file(GLOB_RECURSE FACTORY_ICL Factory/include/*.hpp)
2828
file(GLOB_RECURSE CORE_SRC Core/src/*.cpp)
2929
file(GLOB_RECURSE CORE_ICL Core/include/*.hpp)
3030
file(GLOB_RECURSE EXPORTS IncludeExport/*.hpp)
31-
get_target_property(ICLS_CORE render-modules INCLUDE_DIRECTORIES)
3231

3332
set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON)
3433

@@ -41,7 +40,7 @@ target_include_directories(${PROJECT_NAME} PRIVATE
4140
)
4241
target_include_directories(${PROJECT_NAME} PUBLIC
4342
IncludeExport
44-
${ICLS_CORE}
43+
${render-modules-icls}
4544
)
4645

4746
target_link_libraries(${PROJECT_NAME} PolymorphEngine)

0 commit comments

Comments
 (0)