Commit 8a1471da authored by Ghislain MARY's avatar Ghislain MARY

Some fixes for build with LINPHONE_BUILDER_EXTERNAL_BUILDERS_PATH set.

parent d935b628
......@@ -58,6 +58,11 @@ else()
# Include targets definitions
include(${CMAKE_CURRENT_LIST_DIR}/../targets/CMakeLists.txt)
if(LINPHONE_BUILDER_EXTERNAL_BUILDERS_PATH)
message(STATUS "Including external builders from ${LINPHONE_BUILDER_EXTERNAL_BUILDERS_PATH}")
include(${LINPHONE_BUILDER_EXTERNAL_BUILDERS_PATH}/CMakeLists.txt)
endif()
# Include builder options definitions according to the targets to be built
include(${CMAKE_CURRENT_LIST_DIR}/../options/common.cmake)
foreach(_target IN LISTS TARGET_${LINPHONE_BUILDER_TARGET}_DEPENDENCIES)
......@@ -69,13 +74,6 @@ else()
# Check for build tools and show an error if one of them is not present
include(${CMAKE_CURRENT_LIST_DIR}/../cmake/CheckBuildTools.cmake)
if(LINPHONE_BUILDER_EXTERNAL_BUILDERS_PATH)
message(STATUS "Including external builders from ${LINPHONE_BUILDER_EXTERNAL_BUILDERS_PATH}")
set(LINPHONE_BUILDER_INCLUDING_BUILDERS_FROM_EXTERNAL_BUILDERS_PATH TRUE)
include(${LINPHONE_BUILDER_EXTERNAL_BUILDERS_PATH}/CMakeLists.txt)
endif()
# Check that the chosen target is valid and declare it with its dependencies
lcb_check_target()
lcb_declare_targets()
......
......@@ -253,9 +253,14 @@ macro(linphone_builder_include_builder BUILDER INCLUDE_AFTER DEPENDENCIES _inclu
list(FIND LINPHONE_BUILDER_INCLUDED_BUILDERS ${BUILDER} _already_included)
list(FIND ${DEPENDENCIES} ${BUILDER} _already_included2)
if(_already_included EQUAL -1 AND _already_included2 EQUAL -1)
if(LINPHONE_BUILDER_INCLUDING_BUILDERS_FROM_EXTERNAL_BUILDERS_PATH)
unset(_builder_filepath)
if(LINPHONE_BUILDER_EXTERNAL_BUILDERS_PATH)
set(_builder_filepath "${LINPHONE_BUILDER_EXTERNAL_BUILDERS_PATH}/${BUILDER}.cmake")
else()
if(NOT EXISTS "${_builder_filepath}")
unset(_builder_filepath)
endif()
endif()
if(NOT _builder_filepath)
set(_builder_filepath "${CMAKE_CURRENT_SOURCE_DIR}/builders/${BUILDER}.cmake")
endif()
if(EXISTS "${_builder_filepath}")
......
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