2017-12-24 22:08:48 +01:00
|
|
|
# The variable SKIP_MODULES can be set to skip particular modules;
|
|
|
|
# individual modules can also decide they must be skipped (e.g. OS-specific
|
|
|
|
# modules, or ones with unmet dependencies). Collect the skipped modules
|
|
|
|
# in this list.
|
|
|
|
set( LIST_SKIPPED_MODULES "" )
|
|
|
|
|
2017-10-12 17:55:07 +02:00
|
|
|
if( BUILD_TESTING )
|
|
|
|
add_executable( test_conf test_conf.cpp )
|
|
|
|
target_link_libraries( test_conf ${YAMLCPP_LIBRARY} )
|
2017-11-02 12:38:36 +01:00
|
|
|
target_include_directories( test_conf PUBLIC ${YAMLCPP_INCLUDE_DIR} )
|
2017-10-12 17:55:07 +02:00
|
|
|
endif()
|
|
|
|
|
2014-07-14 16:26:10 +02:00
|
|
|
file( GLOB SUBDIRECTORIES RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} "*" )
|
2015-08-03 17:59:07 +02:00
|
|
|
string( REPLACE " " ";" SKIP_LIST "${SKIP_MODULES}" )
|
2014-07-14 16:26:10 +02:00
|
|
|
foreach( SUBDIRECTORY ${SUBDIRECTORIES} )
|
2015-08-03 17:59:07 +02:00
|
|
|
list( FIND SKIP_LIST ${SUBDIRECTORY} DO_SKIP )
|
|
|
|
|
|
|
|
if( NOT DO_SKIP EQUAL -1 )
|
|
|
|
message( "${ColorReset}-- Skipping module ${BoldRed}${SUBDIRECTORY}${ColorReset}." )
|
|
|
|
message( "" )
|
2017-12-24 22:08:48 +01:00
|
|
|
list( APPEND LIST_SKIPPED_MODULES "${SUBDIRECTORY} (user request)" )
|
2015-08-03 17:59:07 +02:00
|
|
|
elseif( ( IS_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/${SUBDIRECTORY}" ) AND
|
|
|
|
( DO_SKIP EQUAL -1 ) )
|
2017-12-24 22:08:48 +01:00
|
|
|
set( SKIPPED_MODULES )
|
2014-07-14 16:26:10 +02:00
|
|
|
calamares_add_module_subdirectory( ${SUBDIRECTORY} )
|
2017-12-24 22:08:48 +01:00
|
|
|
if ( SKIPPED_MODULES )
|
|
|
|
list( APPEND LIST_SKIPPED_MODULES "${SKIPPED_MODULES}" )
|
|
|
|
endif()
|
2014-06-11 13:37:10 +02:00
|
|
|
endif()
|
|
|
|
endforeach()
|
2017-08-09 20:33:32 +02:00
|
|
|
|
2018-01-10 15:20:49 +01:00
|
|
|
# This is *also* done in top-level, so list is displayed
|
|
|
|
# both before and after the feature summary.
|
|
|
|
calamares_explain_skipped_modules( ${LIST_SKIPPED_MODULES} )
|
2017-12-24 22:08:48 +01:00
|
|
|
|
2017-08-09 20:33:32 +02:00
|
|
|
include( CalamaresAddTranslations )
|
|
|
|
add_calamares_python_translations( ${CALAMARES_TRANSLATION_LANGUAGES} )
|