forked from qt-creator/qt-creator
cmake build: Fix sdktool default output path
The relative path that is passed to the sdktool build must be relative from the sdktool binary to the data path. IDE_DATA_PATH is relative from the Qt Creator binary. Change-Id: If74d9a07cb491247861eef36ebf8406de4fdedd8 Reviewed-by: Cristian Adam <cristian.adam@qt.io>
This commit is contained in:
@@ -40,9 +40,11 @@ endif()
|
||||
|
||||
set(UtilsSourcesDir "../../libs/utils")
|
||||
|
||||
file(RELATIVE_PATH DATA_PATH "/${IDE_LIBEXEC_PATH}" "/${IDE_DATA_PATH}")
|
||||
|
||||
add_qtc_executable(sdktool
|
||||
${DESTINATION}
|
||||
DEFINES DATA_PATH=\"${IDE_DATA_PATH}\"
|
||||
DEFINES DATA_PATH=\"${DATA_PATH}\"
|
||||
DEPENDS Qt5::Core
|
||||
INCLUDES
|
||||
"${UtilsSourcesDir}/../"
|
||||
|
@@ -79,6 +79,14 @@ void printHelp(const std::vector<std::unique_ptr<Operation>> &operations)
|
||||
std::cout << " --help|-h Print this help text" << std::endl;
|
||||
std::cout << " --sdkpath=PATH|-s PATH Set the path to the SDK files" << std::endl << std::endl;
|
||||
|
||||
std::cout << "Default sdkpath is \""
|
||||
<< qPrintable(QDir::cleanPath(
|
||||
Utils::FilePath::fromString(QCoreApplication::applicationDirPath())
|
||||
.pathAppended(DATA_PATH)
|
||||
.toUserOutput()))
|
||||
<< "\"" << std::endl
|
||||
<< std::endl;
|
||||
|
||||
std::cout << "OPERATION:" << std::endl;
|
||||
std::cout << " One of:" << std::endl;
|
||||
for (const std::unique_ptr<Operation> &o : operations)
|
||||
|
Reference in New Issue
Block a user