mirror of
git://code.qt.io/qt/qt5.git
synced 2025-12-21 07:28:21 +08:00
init-repository: Fix passing no --alternates option
Commitd6918d7ac5broke init-repository if you did not pass an --alternates option. Pick-to: 6.10 6.8 Task-number: QTBUG-142712 Fixes: QTBUG-142744 Change-Id: Ia727b420a34a46e52f0f05e549aabe2c975c6d7e Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> (cherry picked from commit6bd3b23b6c)
This commit is contained in:
@@ -427,11 +427,13 @@ endfunction()
|
||||
# Convert to absolute path if necessary.
|
||||
function(qt_ir_get_option_as_existing_absolute_path name value)
|
||||
qt_ir_get_option_value("${name}" path)
|
||||
if(NOT EXISTS "${abspath}")
|
||||
qt_ir_add_error("The path '${path}' passed with -${name} does not exist.")
|
||||
endif()
|
||||
if(NOT IS_ABSOLUTE "${path}")
|
||||
get_filename_component(path "${path}" ABSOLUTE)
|
||||
if(NOT "${path}" STREQUAL "")
|
||||
if(NOT EXISTS "${path}")
|
||||
qt_ir_add_error("The path '${path}' passed with -${name} does not exist.")
|
||||
endif()
|
||||
if(NOT IS_ABSOLUTE "${path}")
|
||||
get_filename_component(path "${path}" ABSOLUTE)
|
||||
endif()
|
||||
endif()
|
||||
set("${value}" "${path}" PARENT_SCOPE)
|
||||
endfunction()
|
||||
|
||||
Reference in New Issue
Block a user