Commit db2288a0 authored by Hans-Christian Ebke's avatar Hans-Christian Ebke

Speed up cmake some more.


git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@19377 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 02d7cc56
...@@ -46,6 +46,7 @@ function (of_add_plugins) ...@@ -46,6 +46,7 @@ function (of_add_plugins)
get_filename_component (_plugin_dir ${_plugin} PATH) get_filename_component (_plugin_dir ${_plugin} PATH)
add_subdirectory (${CMAKE_SOURCE_DIR}/${_plugin_dir}) add_subdirectory (${CMAKE_SOURCE_DIR}/${_plugin_dir})
endforeach () endforeach ()
set(LOADED_PACKAGES ${LOADED_PACKAGES} PARENT_SCOPE)
endfunction () endfunction ()
macro(_get_plugin_name _path _name) macro(_get_plugin_name _path _name)
......
...@@ -120,9 +120,10 @@ macro (_check_plugin_deps _prefix _optional ) ...@@ -120,9 +120,10 @@ macro (_check_plugin_deps _prefix _optional )
string (TOUPPER ${_val} _VAL) string (TOUPPER ${_val} _VAL)
# First we try to find the dependencies directly # First we try to find the dependencies directly
if (NOT ${_VAL}_FOUND) if (NOT ${_VAL}_FOUND AND NOT ${_val}_FOUND)
# MESSAGE(STATUS "Looking for _val \"${_val}\"") # MESSAGE(STATUS "Looking for _val \"${_val}\"")
find_package(${_val}) find_package(${_val})
list(APPEND LOADED_PACKAGES_ "${_val}")
#else() #else()
# MESSAGE(STATUS "Skipping _val \"${_val}\"") # MESSAGE(STATUS "Skipping _val \"${_val}\"")
endif () endif ()
...@@ -140,9 +141,10 @@ macro (_check_plugin_deps _prefix _optional ) ...@@ -140,9 +141,10 @@ macro (_check_plugin_deps _prefix _optional )
string (TOUPPER ${_rec_dep} _REC_DEP) string (TOUPPER ${_rec_dep} _REC_DEP)
if (NOT ${_REC_DEP}_FOUND) if (NOT ${_REC_DEP}_FOUND AND NOT ${_rec_dep}_FOUND)
# MESSAGE(STATUS "Looking for _rec_dep \"${_rec_dep}\"") # MESSAGE(STATUS "Looking for _rec_dep \"${_rec_dep}\"")
find_package(${_rec_dep}) find_package(${_rec_dep})
list(APPEND LOADED_PACKAGES_ "${_rec_dep}")
#else() #else()
# MESSAGE(STATUS "Skipping _rec_dep \"${_rec_dep}\"") # MESSAGE(STATUS "Skipping _rec_dep \"${_rec_dep}\"")
endif () endif ()
...@@ -166,9 +168,10 @@ macro (_check_plugin_deps _prefix _optional ) ...@@ -166,9 +168,10 @@ macro (_check_plugin_deps _prefix _optional )
string (TOUPPER ${_rec_dep} _REC_DEP) string (TOUPPER ${_rec_dep} _REC_DEP)
if (NOT ${_REC_DEP}_FOUND) if (NOT ${_REC_DEP}_FOUND AND NOT ${_rec_dep}_FOUND)
# MESSAGE(STATUS "Looking for _rec_dep \"${_rec_dep}\"") # MESSAGE(STATUS "Looking for _rec_dep \"${_rec_dep}\"")
find_package(${_rec_dep}) find_package(${_rec_dep})
list(APPEND LOADED_PACKAGES_ "${_rec_dep}")
#else() #else()
# MESSAGE(STATUS "Skipping _rec_dep \"${_rec_dep}\"") # MESSAGE(STATUS "Skipping _rec_dep \"${_rec_dep}\"")
endif () endif ()
...@@ -231,9 +234,10 @@ macro (_check_plugin_deps _prefix _optional ) ...@@ -231,9 +234,10 @@ macro (_check_plugin_deps _prefix _optional )
foreach (_val ${FULL_DEPENDENCY_LIST}) foreach (_val ${FULL_DEPENDENCY_LIST})
string (TOUPPER ${_val} _VAL) string (TOUPPER ${_val} _VAL)
if (NOT ${_VAL}_FOUND) if (NOT ${_VAL}_FOUND AND NOT ${_val}_FOUND)
# MESSAGE(STATUS "Looking for _val \"${_val}\"") # MESSAGE(STATUS "Looking for _val \"${_val}\"")
find_package(${_val}) find_package(${_val})
list(APPEND LOADED_PACKAGES_ "${_val}")
#else() #else()
# MESSAGE(STATUS "Skipping _val \"${_val}\"") # MESSAGE(STATUS "Skipping _val \"${_val}\"")
endif () endif ()
...@@ -304,6 +308,9 @@ macro (_check_plugin_deps _prefix _optional ) ...@@ -304,6 +308,9 @@ macro (_check_plugin_deps _prefix _optional )
acg_set (_${_prefix}_MISSING_DEPS "${_${_prefix}_MISSING_DEPS} ${_val}") acg_set (_${_prefix}_MISSING_DEPS "${_${_prefix}_MISSING_DEPS} ${_val}")
endif () endif ()
endforeach () endforeach ()
set(LOADED_PACKAGES ${LOADED_PACKAGES} ${LOADED_PACKAGES_})
set(LOADED_PACKAGES ${LOADED_PACKAGES} PARENT_SCOPE)
endmacro () endmacro ()
macro (_plugin_licensemanagement) macro (_plugin_licensemanagement)
...@@ -700,7 +707,7 @@ endfunction () ...@@ -700,7 +707,7 @@ endfunction ()
macro (openflipper_plugin) macro (openflipper_plugin)
_get_plugin_name (_plugin) _get_plugin_name (_plugin)
string (TOUPPER ${_plugin} _PLUGIN) string (TOUPPER ${_plugin} _PLUGIN)
# add option to disable plugin build # add option to disable plugin build
...@@ -713,6 +720,7 @@ macro (openflipper_plugin) ...@@ -713,6 +720,7 @@ macro (openflipper_plugin)
if (NOT DISABLE_PLUGIN_${_PLUGIN}) if (NOT DISABLE_PLUGIN_${_PLUGIN})
_build_openflipper_plugin (${_plugin} ${ARGN}) _build_openflipper_plugin (${_plugin} ${ARGN})
endif () endif ()
set(LOADED_PACKAGES ${LOADED_PACKAGES} PARENT_SCOPE)
endmacro () endmacro ()
# No stupid abundance of "Boost version" messages, please. # No stupid abundance of "Boost version" messages, please.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment