mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2025-11-29 17:38:24 +08:00
skip inclusion of modules without CMakeLists
+ added hook for after load conf
This commit is contained in:
@@ -42,6 +42,8 @@ if(EXISTS "conf/config.cmake")
|
|||||||
include(conf/config.cmake)
|
include(conf/config.cmake)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
RUN_HOOK("AFTER_LOAD_CONF")
|
||||||
|
|
||||||
# build in Release-mode by default if not explicitly set
|
# build in Release-mode by default if not explicitly set
|
||||||
if( NOT CMAKE_BUILD_TYPE )
|
if( NOT CMAKE_BUILD_TYPE )
|
||||||
set(CMAKE_BUILD_TYPE "Release")
|
set(CMAKE_BUILD_TYPE "Release")
|
||||||
@@ -85,8 +87,10 @@ include(src/cmake/showoptions.cmake)
|
|||||||
AZTH_SUBDIRLIST(sub_DIRS "${CMAKE_SOURCE_DIR}/modules" FALSE FALSE)
|
AZTH_SUBDIRLIST(sub_DIRS "${CMAKE_SOURCE_DIR}/modules" FALSE FALSE)
|
||||||
FOREACH(subdir ${sub_DIRS})
|
FOREACH(subdir ${sub_DIRS})
|
||||||
STRING(REGEX REPLACE "^${CMAKE_SOURCE_DIR}/" "" subdir ${subdir})
|
STRING(REGEX REPLACE "^${CMAKE_SOURCE_DIR}/" "" subdir ${subdir})
|
||||||
|
if(EXISTS "${subdir}/CMakeLists.txt")
|
||||||
message("Loading module: ${subdir}")
|
message("Loading module: ${subdir}")
|
||||||
add_subdirectory("${subdir}")
|
add_subdirectory("${subdir}")
|
||||||
|
endif()
|
||||||
ENDFOREACH()
|
ENDFOREACH()
|
||||||
|
|
||||||
RUN_HOOK("BEFORE_SRC_LOAD")
|
RUN_HOOK("BEFORE_SRC_LOAD")
|
||||||
|
|||||||
Reference in New Issue
Block a user