mirror of
https://github.com/QuasarApp/CQtDeployer.git
synced 2025-05-05 05:59:35 +00:00
rename prefix to package
This commit is contained in:
parent
5ab1f83e58
commit
4ec4ea6728
@ -4,7 +4,7 @@
|
||||
"binDir": "./",
|
||||
"qmlDir": [
|
||||
[
|
||||
"prefix2",
|
||||
"package2",
|
||||
"./TestQMLWidgets/"
|
||||
],
|
||||
[
|
||||
@ -25,13 +25,13 @@
|
||||
"extraLibs": "myExtraLib (libssl)",
|
||||
"extraPlugin": "myExtraPulgin (platforms)",
|
||||
"targetDir": "./Distro",
|
||||
"targetPrefix": [
|
||||
"targetPackage": [
|
||||
[
|
||||
"/prefix1/",
|
||||
"/package1/",
|
||||
"TestOnlyC"
|
||||
],
|
||||
[
|
||||
"/prefix2/",
|
||||
"/package2/",
|
||||
"TestQMLWidgets"
|
||||
]
|
||||
],
|
||||
@ -49,8 +49,8 @@
|
||||
"noAutoCheckQmake": false,
|
||||
"name": [
|
||||
[
|
||||
"prefix2",
|
||||
"prefix2Application"
|
||||
"package2",
|
||||
"package2Application"
|
||||
],
|
||||
[
|
||||
"mainApplication"
|
||||
@ -58,16 +58,16 @@
|
||||
],
|
||||
"description": [
|
||||
[
|
||||
"prefix2",
|
||||
"this is description for prefix 'prefix2'"
|
||||
"package2",
|
||||
"this is description for package 'package2'"
|
||||
],
|
||||
[
|
||||
"this is description for default prefix"
|
||||
"this is description for default package"
|
||||
]
|
||||
],
|
||||
"deployVersion": [
|
||||
[
|
||||
"prefix2",
|
||||
"package2",
|
||||
"1.0.0"
|
||||
],
|
||||
[
|
||||
@ -76,7 +76,7 @@
|
||||
],
|
||||
"releaseDate": [
|
||||
[
|
||||
"prefix2",
|
||||
"package2",
|
||||
"yyyy-MM-dd"
|
||||
],
|
||||
[
|
||||
@ -85,7 +85,7 @@
|
||||
],
|
||||
"icon": [
|
||||
[
|
||||
"prefix2",
|
||||
"package2",
|
||||
"/path/icon.png"
|
||||
],
|
||||
[
|
||||
@ -94,8 +94,8 @@
|
||||
],
|
||||
"publisher": [
|
||||
[
|
||||
"prefix2",
|
||||
"team of prefix2"
|
||||
"package2",
|
||||
"team of package2"
|
||||
],
|
||||
[
|
||||
"main team"
|
||||
|
@ -16,7 +16,7 @@
|
||||
"extraLibs": "myExtraLib (libssl)",
|
||||
"extraPlugin": "myExtraPulgin (platforms)",
|
||||
"targetDir": "./Distro",
|
||||
"targetPrefix": "",
|
||||
"targetPackage": "",
|
||||
"noStrip": false,
|
||||
"extractPlugins": false,
|
||||
"noTranslations": false,
|
||||
|
@ -128,7 +128,7 @@ QString iDistribution::findProcess(const QString &env, const QString& proc) cons
|
||||
}
|
||||
|
||||
QMap<int ,QPair<QString, const DistroModule*>>
|
||||
iDistribution::sortPrefixes(const QHash<QString, DistroModule> &input) {
|
||||
iDistribution::sortPackages(const QHash<QString, DistroModule> &input) {
|
||||
QMap<int ,QPair<QString, const DistroModule *>> result;
|
||||
for (auto it = input.cbegin(); it != input.cend(); ++it ) {
|
||||
result.insertMulti(0xFFFF - it.key().size(), {it.key(), &it.value()});
|
||||
|
@ -45,7 +45,7 @@ protected:
|
||||
|
||||
QString findProcess(const QString& env, const QString& proc) const;
|
||||
|
||||
QMap<int, QPair<QString, const DistroModule *>> sortPrefixes(const QHash<QString, DistroModule> &input);
|
||||
QMap<int, QPair<QString, const DistroModule *>> sortPackages(const QHash<QString, DistroModule> &input);
|
||||
private:
|
||||
|
||||
QString _location = "Temp Template";
|
||||
|
@ -68,7 +68,7 @@ bool QIF::deployTemplate() {
|
||||
if (customTemplate.isEmpty()) {
|
||||
// default template
|
||||
|
||||
auto sortedMap = sortPrefixes(cfg->prefixes());
|
||||
auto sortedMap = sortPackages(cfg->packages());
|
||||
|
||||
for (auto &it : sortedMap) {
|
||||
auto package = it.second;
|
||||
|
@ -22,18 +22,18 @@
|
||||
#include <Distributions/defaultdistro.h>
|
||||
#include <Distributions/qif.h>
|
||||
/**
|
||||
* this function init prefixes of project
|
||||
* this function init packages of project
|
||||
* inputParamsList - list of parameters
|
||||
* patern : value;prefix
|
||||
* mainContainer - container for insert data, usually it is prefixes map.
|
||||
* patern : value;package
|
||||
* mainContainer - container for insert data, usually it is packages map.
|
||||
* seterFunc - this is method of item of mainConteiner for set value from inputParamsList
|
||||
* important : prefix in inputParamsList must be second.
|
||||
* important : package in inputParamsList must be second.
|
||||
*/
|
||||
|
||||
static QString defaultPrefix = "";
|
||||
static QString defaultPackage = "";
|
||||
|
||||
template<typename Container, typename Setter>
|
||||
bool parsePrefixesPrivate(Container& mainContainer,
|
||||
bool parsePackagesPrivate(Container& mainContainer,
|
||||
const QStringList &inputParamsList,
|
||||
Setter setter) {
|
||||
|
||||
@ -42,7 +42,7 @@ bool parsePrefixesPrivate(Container& mainContainer,
|
||||
auto first = pair.value(0, "");
|
||||
auto second = pair.value(1, "");
|
||||
if (pair.size() == 1)
|
||||
(mainContainer[defaultPrefix].*setter)(first);
|
||||
(mainContainer[defaultPackage].*setter)(first);
|
||||
else {
|
||||
first = PathUtils::toFullPath(first);
|
||||
if (!mainContainer.contains(first)) {
|
||||
@ -140,7 +140,7 @@ const DeployConfig *ConfigParser::config() const {
|
||||
return &_config;
|
||||
}
|
||||
|
||||
// FIX ME. if prefix contains the path separators then prefix rewrite to RelativeLink of configFile location
|
||||
// FIX ME. if package contains the path separators then package rewrite to RelativeLink of configFile location
|
||||
QJsonValue ConfigParser::writeKeyArray(int separatorLvl, const QString ¶meter,
|
||||
const QString &confFileDir) const {
|
||||
|
||||
@ -288,11 +288,11 @@ bool ConfigParser::loadFromFile(const QString& confFile) {
|
||||
|
||||
bool ConfigParser::initDistroStruct() {
|
||||
|
||||
if (!initPrefixes()) {
|
||||
if (!initPackages()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
auto &mainDistro = _config.prefixesEdit();
|
||||
auto &mainDistro = _config.packagesEdit();
|
||||
|
||||
#ifdef Q_OS_LINUX
|
||||
|
||||
@ -331,68 +331,68 @@ bool ConfigParser::initDistroStruct() {
|
||||
split(DeployCore::getSeparator(0), QString::SkipEmptyParts);
|
||||
|
||||
auto erroLog = [](const QString &flag){
|
||||
QuasarAppUtils::Params::verboseLog(QString("Set %0 fail, becouse you try set %0 for not inited prefix."
|
||||
" Use 'targetPrefix' flag for init the prefixes").arg(flag),
|
||||
QuasarAppUtils::Params::verboseLog(QString("Set %0 fail, becouse you try set %0 for not inited package."
|
||||
" Use 'targetPackage' flag for init the packages").arg(flag),
|
||||
QuasarAppUtils::Error);
|
||||
};
|
||||
|
||||
// init distro stucts for all targets
|
||||
if (binOut.size() && !parsePrefixesPrivate(mainDistro, binOut, &DistroModule::setBinOutDir)) {
|
||||
if (binOut.size() && !parsePackagesPrivate(mainDistro, binOut, &DistroModule::setBinOutDir)) {
|
||||
erroLog("binOut");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (libOut.size() && !parsePrefixesPrivate(mainDistro, libOut, &DistroModule::setLibOutDir)) {
|
||||
if (libOut.size() && !parsePackagesPrivate(mainDistro, libOut, &DistroModule::setLibOutDir)) {
|
||||
erroLog("libOut");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (qmlOut.size() && !parsePrefixesPrivate(mainDistro, qmlOut, &DistroModule::setQmlOutDir)) {
|
||||
if (qmlOut.size() && !parsePackagesPrivate(mainDistro, qmlOut, &DistroModule::setQmlOutDir)) {
|
||||
erroLog("qmlOut");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (trOut.size() && !parsePrefixesPrivate(mainDistro, trOut, &DistroModule::setTrOutDir)) {
|
||||
if (trOut.size() && !parsePackagesPrivate(mainDistro, trOut, &DistroModule::setTrOutDir)) {
|
||||
erroLog("trOut");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (pluginOut.size() && !parsePrefixesPrivate(mainDistro, pluginOut, &DistroModule::setPluginsOutDir)) {
|
||||
if (pluginOut.size() && !parsePackagesPrivate(mainDistro, pluginOut, &DistroModule::setPluginsOutDir)) {
|
||||
erroLog("pluginOut");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (recOut.size() && !parsePrefixesPrivate(mainDistro, recOut, &DistroModule::setResOutDir)) {
|
||||
if (recOut.size() && !parsePackagesPrivate(mainDistro, recOut, &DistroModule::setResOutDir)) {
|
||||
erroLog("recOut");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (name.size() && !parsePrefixesPrivate(mainDistro, name, &DistroModule::setName)) {
|
||||
if (name.size() && !parsePackagesPrivate(mainDistro, name, &DistroModule::setName)) {
|
||||
erroLog("name");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (description.size() && !parsePrefixesPrivate(mainDistro, description, &DistroModule::setDescription)) {
|
||||
if (description.size() && !parsePackagesPrivate(mainDistro, description, &DistroModule::setDescription)) {
|
||||
erroLog("description");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (deployVersion.size() && !parsePrefixesPrivate(mainDistro, deployVersion, &DistroModule::setVersion)) {
|
||||
if (deployVersion.size() && !parsePackagesPrivate(mainDistro, deployVersion, &DistroModule::setVersion)) {
|
||||
erroLog("deployVersion");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (releaseDate.size() && !parsePrefixesPrivate(mainDistro, releaseDate, &DistroModule::setReleaseData)) {
|
||||
if (releaseDate.size() && !parsePackagesPrivate(mainDistro, releaseDate, &DistroModule::setReleaseData)) {
|
||||
erroLog("releaseDate");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (icon.size() && !parsePrefixesPrivate(mainDistro, icon, &DistroModule::setIcon)) {
|
||||
if (icon.size() && !parsePackagesPrivate(mainDistro, icon, &DistroModule::setIcon)) {
|
||||
erroLog("icon");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (publisher.size() && !parsePrefixesPrivate(mainDistro, publisher, &DistroModule::setPublisher)) {
|
||||
if (publisher.size() && !parsePackagesPrivate(mainDistro, publisher, &DistroModule::setPublisher)) {
|
||||
erroLog("Publisher");
|
||||
return false;
|
||||
}
|
||||
@ -400,38 +400,38 @@ bool ConfigParser::initDistroStruct() {
|
||||
return true;
|
||||
}
|
||||
|
||||
bool ConfigParser::initPrefixes() {
|
||||
bool ConfigParser::initPackages() {
|
||||
|
||||
defaultPrefix = "";
|
||||
defaultPackage = "";
|
||||
|
||||
if (QuasarAppUtils::Params::isEndable("targetPrefix")) {
|
||||
auto tar_prefixes_array = QuasarAppUtils::Params::getStrArg("targetPrefix", "").
|
||||
if (QuasarAppUtils::Params::isEndable("targetPackage")) {
|
||||
auto tar_packages_array = QuasarAppUtils::Params::getStrArg("targetPackage", "").
|
||||
split(DeployCore::getSeparator(0));
|
||||
|
||||
|
||||
QSet<QString> configuredTargets;
|
||||
for (auto& str: tar_prefixes_array) {
|
||||
for (auto& str: tar_packages_array) {
|
||||
auto pair = str.split(DeployCore::getSeparator(1));
|
||||
auto prefix = PathUtils::toFullPath(pair.value(0, ""));
|
||||
auto package = PathUtils::toFullPath(pair.value(0, ""));
|
||||
|
||||
auto list = _config.getTargetsListByFilter(pair.value(1, ""));
|
||||
|
||||
for (auto it = list.begin(); it != list.end(); ++it) {
|
||||
if (!configuredTargets.contains(it.key())) {
|
||||
configuredTargets.insert(it.key());
|
||||
it.value()->setSufix(prefix);
|
||||
it.value()->setSufix(package);
|
||||
}
|
||||
}
|
||||
|
||||
_config.prefixesEdit().insert(prefix, {});
|
||||
_config.packagesEdit().insert(package, {});
|
||||
|
||||
if (pair.size() != 2) {
|
||||
defaultPrefix = prefix;
|
||||
defaultPackage = package;
|
||||
}
|
||||
}
|
||||
|
||||
QuasarAppUtils::Params::verboseLog(
|
||||
"Set Default Prefix to " + defaultPrefix,
|
||||
"Set Default Package to " + defaultPackage,
|
||||
QuasarAppUtils::Info);
|
||||
}
|
||||
|
||||
@ -449,15 +449,15 @@ bool ConfigParser::initQmlInput() {
|
||||
}
|
||||
|
||||
auto erroLog = [](const QString &flag){
|
||||
QuasarAppUtils::Params::verboseLog(QString("Set %0 fail, becouse you try set %0 for not inited prefix."
|
||||
" Use 'targetPrefix' flag for init the prefixes").arg(flag),
|
||||
QuasarAppUtils::Params::verboseLog(QString("Set %0 fail, becouse you try set %0 for not inited package."
|
||||
" Use 'targetPackage' flag for init the packages").arg(flag),
|
||||
QuasarAppUtils::Error);
|
||||
};
|
||||
|
||||
// init distro stucts for all targets
|
||||
_config.deployQml = qmlDir.size();
|
||||
|
||||
if (qmlDir.size() && !parsePrefixesPrivate(_config.prefixesEdit(), qmlDir, &DistroModule::addQmlInput)) {
|
||||
if (qmlDir.size() && !parsePackagesPrivate(_config.packagesEdit(), qmlDir, &DistroModule::addQmlInput)) {
|
||||
erroLog("qmlDir");
|
||||
return false;
|
||||
}
|
||||
@ -1162,7 +1162,7 @@ bool ConfigParser::smartMoveTargets() {
|
||||
auto newTargetKey = targetPath + "/" + target.fileName();
|
||||
temp.unite(moveTarget(i.value(), newTargetKey));
|
||||
|
||||
_config.prefixesEdit()[i.value().getSufix()].addTarget(newTargetKey);
|
||||
_config.packagesEdit()[i.value().getSufix()].addTarget(newTargetKey);
|
||||
|
||||
}
|
||||
|
||||
|
@ -35,12 +35,12 @@ private:
|
||||
DependenciesScanner *_scaner;
|
||||
Packing * _packing;
|
||||
|
||||
QHash<QString, QString> _Targetprefixes;
|
||||
QHash<QString, QString> _Targetpackages;
|
||||
|
||||
bool createFromDeploy(const QString& file) const;
|
||||
bool loadFromFile(const QString& file);
|
||||
bool initDistroStruct();
|
||||
bool initPrefixes();
|
||||
bool initPackages();
|
||||
bool parseDeployMode();
|
||||
bool parseInfoMode();
|
||||
bool parseInitMode();
|
||||
|
@ -28,31 +28,31 @@ void DeployConfig::setTargetDir(const QString &target) {
|
||||
}
|
||||
|
||||
DistroModule DeployConfig::getDistro(const QString &target) const {
|
||||
return _prefixes.value(_targets.value(target).getSufix());
|
||||
return _packages.value(_targets.value(target).getSufix());
|
||||
}
|
||||
|
||||
DistroModule DeployConfig::getDistroFromPrefix(const QString &prefix) const {
|
||||
if (_prefixes.contains(prefix)) {
|
||||
return _prefixes[prefix];
|
||||
DistroModule DeployConfig::getDistroFromPackage(const QString &package) const {
|
||||
if (_packages.contains(package)) {
|
||||
return _packages[package];
|
||||
}
|
||||
|
||||
return _prefixes.value("");
|
||||
return _packages.value("");
|
||||
}
|
||||
|
||||
QHash<QString, TargetInfo> &DeployConfig::targetsEdit() {
|
||||
return _targets;
|
||||
}
|
||||
|
||||
QHash<QString, DistroModule> &DeployConfig::prefixesEdit() {
|
||||
return _prefixes;
|
||||
QHash<QString, DistroModule> &DeployConfig::packagesEdit() {
|
||||
return _packages;
|
||||
}
|
||||
|
||||
const QHash<QString, TargetInfo> &DeployConfig::targets() const {
|
||||
return _targets;
|
||||
}
|
||||
|
||||
const QHash<QString, DistroModule> &DeployConfig::prefixes() const {
|
||||
return _prefixes;
|
||||
const QHash<QString, DistroModule> &DeployConfig::packages() const {
|
||||
return _packages;
|
||||
}
|
||||
|
||||
|
||||
|
@ -74,17 +74,17 @@ public:
|
||||
DistroModule getDistro(const QString& target) const;
|
||||
|
||||
/**
|
||||
* @brief getDistroFromPrefix
|
||||
* @param prefix
|
||||
* @return distro struct from prefix
|
||||
* @brief getDistroFromPackage
|
||||
* @param package
|
||||
* @return distro struct from package
|
||||
*/
|
||||
DistroModule getDistroFromPrefix(const QString& prefix) const;
|
||||
DistroModule getDistroFromPackage(const QString& package) const;
|
||||
|
||||
const QHash<QString, TargetInfo>& targets() const;
|
||||
const QHash<QString, DistroModule>& prefixes() const;
|
||||
const QHash<QString, DistroModule>& packages() const;
|
||||
|
||||
QHash<QString, TargetInfo>& targetsEdit();
|
||||
QHash<QString, DistroModule>& prefixesEdit();
|
||||
QHash<QString, DistroModule>& packagesEdit();
|
||||
|
||||
private:
|
||||
|
||||
@ -96,12 +96,12 @@ private:
|
||||
QHash<QString, TargetInfo> _targets;
|
||||
|
||||
/**
|
||||
* @brief prefixes
|
||||
* key - prefix
|
||||
* value struvture of prefix
|
||||
* default prefix is empty value
|
||||
* @brief packages
|
||||
* key - package
|
||||
* value struvture of package
|
||||
* default package is empty value
|
||||
*/
|
||||
QHash<QString, DistroModule> _prefixes;
|
||||
QHash<QString, DistroModule> _packages;
|
||||
|
||||
/**
|
||||
* @brief targetDir - targe directory (this folder conteins all files of distrebution kit)
|
||||
|
@ -179,7 +179,7 @@ QString DeployCore::help() {
|
||||
{ " -binDir [params] : A folder which includes deployable files (recursive search)." },
|
||||
{ " | WARNING: this flag supports 'so', 'dll' and 'exe' files only." },
|
||||
{ " | Use '-bin' flag if you want to deploy linux binary files" },
|
||||
{ " -qmlDir [prefix;path,path]: Qml data dir. For example -qmlDir ~/my/project/qml" },
|
||||
{ " -qmlDir [package;path,path]: Qml data dir. For example -qmlDir ~/my/project/qml" },
|
||||
{ " deploySystem : Deploys all libs" },
|
||||
{ " deploySystem-with-libc : Skip Deploys system core libs libs" },
|
||||
{ " -qmake [params] : Qmake path." },
|
||||
@ -201,7 +201,7 @@ QString DeployCore::help() {
|
||||
{ " -extraPlugin[list,params]: Sets an additional path to extraPlugin of an app" },
|
||||
{ " -recursiveDepth [params] : Sets the Depth of recursive search of libs (default 0)" },
|
||||
{ " -targetDir [params] : Sets target directory(by default it is the path to the first deployable file)" },
|
||||
{ " -targetPrefix [tar1;path,path]: Sets prefix for target( by default it is empty value)" },
|
||||
{ " -targetPackage [tar1;path,path]: Sets package for target( by default it is empty value)" },
|
||||
{ " noStrip : Skips strip step" },
|
||||
{ " extractPlugins | This flag will cause cqtdeployer to retrieve dependencies from plugins." },
|
||||
{ " : Starting with version 1.4, this option has been disabled by default,"},
|
||||
@ -210,19 +210,19 @@ QString DeployCore::help() {
|
||||
{ " noTranslations : Skips the translations files." },
|
||||
{ " | It doesn't work without qmake and inside a snap package" },
|
||||
{ " -noAutoCheckQmake : Disables automatic search of paths to qmake in executable files." },
|
||||
{ " -qmlOut [prefix;val,val] : Sets path to qml out directory" },
|
||||
{ " -libOut [prefix;val,val] : Sets path to libraries out directory" },
|
||||
{ " -trOut [prefix;val,val] : Sets path to translations out directory" },
|
||||
{ " -pluginOut [prefix;val,val]: Sets path to plugins out directory" },
|
||||
{ " -binOut [prefix;val,val] : Sets path to binary out directory" },
|
||||
{ " -recOut [prefix;val,val] : Sets path to recurses out directory" },
|
||||
{ " -qmlOut [package;val,val] : Sets path to qml out directory" },
|
||||
{ " -libOut [package;val,val] : Sets path to libraries out directory" },
|
||||
{ " -trOut [package;val,val] : Sets path to translations out directory" },
|
||||
{ " -pluginOut [package;val,val]: Sets path to plugins out directory" },
|
||||
{ " -binOut [package;val,val] : Sets path to binary out directory" },
|
||||
{ " -recOut [package;val,val] : Sets path to recurses out directory" },
|
||||
|
||||
{ " -name [prefix;val,val] : Sets name for prefix. If this if you do not specify a prefix, the value will be assigned to the default prefix ("")" },
|
||||
{ " -description [prefix;val,val] : Sets description for prefix" },
|
||||
{ " -deployVersion [prefix;val,val] : Sets version for prefix" },
|
||||
{ " -releaseDate [prefix;val,val] : Sets release date for prefix" },
|
||||
{ " -icon [prefix;val,val] : Sets path to icon for prefix" },
|
||||
{ " -publisher [prefix;val,val]: Sets Publisher for prefix" },
|
||||
{ " -name [package;val,val] : Sets name for package. If this if you do not specify a package, the value will be assigned to the default package ("")" },
|
||||
{ " -description [package;val,val] : Sets description for package" },
|
||||
{ " -deployVersion [package;val,val] : Sets version for package" },
|
||||
{ " -releaseDate [package;val,val] : Sets release date for package" },
|
||||
{ " -icon [package;val,val] : Sets path to icon for package" },
|
||||
{ " -publisher [package;val,val]: Sets Publisher for package" },
|
||||
|
||||
{ " -qif [params] : Create the QIF installer for deployement programm" },
|
||||
{ " : By default params value is 'Default'" },
|
||||
@ -263,7 +263,7 @@ QStringList DeployCore::helpKeys() {
|
||||
"extraPlugin",
|
||||
"recursiveDepth",
|
||||
"targetDir",
|
||||
"targetPrefix",
|
||||
"targetPackage",
|
||||
"noStrip",
|
||||
"extractPlugins",
|
||||
"noTranslations",
|
||||
|
@ -37,8 +37,8 @@ bool Extracter::deployMSVC() {
|
||||
return _fileManager->copyFile(msvcInstaller, DeployCore::_config->getTargetDir());
|
||||
}
|
||||
|
||||
bool Extracter::isWebEngine(const QString &prefix) const {
|
||||
auto qtModules = _prefixDependencyes.value(prefix).qtModules();
|
||||
bool Extracter::isWebEngine(const QString &package) const {
|
||||
auto qtModules = _packageDependencyes.value(package).qtModules();
|
||||
|
||||
return static_cast<quint64>(qtModules) & static_cast<quint64>(DeployCore::QtModule::QtWebEngineModule);
|
||||
}
|
||||
@ -47,10 +47,10 @@ bool Extracter::extractWebEngine() {
|
||||
|
||||
auto cnf = DeployCore::_config;
|
||||
|
||||
for (auto i = cnf->prefixes().cbegin(); i != cnf->prefixes().cend(); ++i) {
|
||||
for (auto i = cnf->packages().cbegin(); i != cnf->packages().cend(); ++i) {
|
||||
|
||||
const auto &prefix = i.key();
|
||||
if (isWebEngine(prefix)) {
|
||||
const auto &package = i.key();
|
||||
if (isWebEngine(package)) {
|
||||
auto webEngeneBin = DeployCore::_config->qtDir.getLibexecs();
|
||||
if (DeployCore::_config->qtDir.getQtPlatform() & Platform::Unix) {
|
||||
webEngeneBin += "/QtWebEngineProcess";
|
||||
@ -58,8 +58,8 @@ bool Extracter::extractWebEngine() {
|
||||
webEngeneBin += "/QtWebEngineProcess.exe";
|
||||
}
|
||||
|
||||
auto destWebEngine = DeployCore::_config->getTargetDir() + prefix + DeployCore::_config->prefixes()[prefix].getBinOutDir();
|
||||
auto resOut = DeployCore::_config->getTargetDir() + prefix + DeployCore::_config->prefixes()[prefix].getResOutDir();
|
||||
auto destWebEngine = DeployCore::_config->getTargetDir() + package + DeployCore::_config->packages()[package].getBinOutDir();
|
||||
auto resOut = DeployCore::_config->getTargetDir() + package + DeployCore::_config->packages()[package].getResOutDir();
|
||||
auto res = DeployCore::_config->qtDir.getResources();
|
||||
|
||||
if (!_fileManager->copyFile(webEngeneBin, destWebEngine)) {
|
||||
@ -75,13 +75,13 @@ bool Extracter::extractWebEngine() {
|
||||
return true;
|
||||
}
|
||||
|
||||
bool Extracter::copyPlugin(const QString &plugin, const QString& prefix) {
|
||||
bool Extracter::copyPlugin(const QString &plugin, const QString& package) {
|
||||
|
||||
QStringList listItems;
|
||||
|
||||
auto cnf = DeployCore::_config;
|
||||
auto targetPath = cnf->getTargetDir() + prefix;
|
||||
auto distro = cnf->getDistroFromPrefix(prefix);
|
||||
auto targetPath = cnf->getTargetDir() + package;
|
||||
auto distro = cnf->getDistroFromPackage(package);
|
||||
|
||||
|
||||
auto pluginPath = targetPath + distro.getPluginsOutDir() +
|
||||
@ -94,21 +94,21 @@ bool Extracter::copyPlugin(const QString &plugin, const QString& prefix) {
|
||||
|
||||
for (const auto &item : listItems) {
|
||||
if (QuasarAppUtils::Params::isEndable("extractPlugins")) {
|
||||
extract(item, &_prefixDependencyes[prefix]);
|
||||
extract(item, &_packageDependencyes[package]);
|
||||
} else {
|
||||
extract(item, &_prefixDependencyes[prefix], "Qt");
|
||||
extract(item, &_packageDependencyes[package], "Qt");
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void Extracter::copyExtraPlugins(const QString& prefix) {
|
||||
void Extracter::copyExtraPlugins(const QString& package) {
|
||||
QFileInfo info;
|
||||
|
||||
auto cnf = DeployCore::_config;
|
||||
auto targetPath = cnf->getTargetDir() + prefix;
|
||||
auto distro = cnf->getDistroFromPrefix(prefix);
|
||||
auto targetPath = cnf->getTargetDir() + package;
|
||||
auto distro = cnf->getDistroFromPackage(package);
|
||||
|
||||
for (auto extraPlugin : DeployCore::_config->extraPlugins) {
|
||||
|
||||
@ -118,37 +118,37 @@ void Extracter::copyExtraPlugins(const QString& prefix) {
|
||||
|
||||
info.setFile(extraPlugin);
|
||||
if (info.isDir() && DeployCore::_config->qtDir.isQt(info.absoluteFilePath())) {
|
||||
copyPlugin(info.absoluteFilePath(), prefix);
|
||||
copyPlugin(info.absoluteFilePath(), package);
|
||||
|
||||
} else if (info.exists()) {
|
||||
_fileManager->copyFile(info.absoluteFilePath(),
|
||||
targetPath + distro.getPluginsOutDir());
|
||||
|
||||
if (QuasarAppUtils::Params::isEndable("extractPlugins")) {
|
||||
extract(info.absoluteFilePath(), &_prefixDependencyes[prefix]);
|
||||
extract(info.absoluteFilePath(), &_packageDependencyes[package]);
|
||||
} else {
|
||||
extract(info.absoluteFilePath(), &_prefixDependencyes[prefix], "Qt");
|
||||
extract(info.absoluteFilePath(), &_packageDependencyes[package], "Qt");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void Extracter::copyPlugins(const QStringList &list, const QString& prefix) {
|
||||
void Extracter::copyPlugins(const QStringList &list, const QString& package) {
|
||||
for (const auto &plugin : list) {
|
||||
if (!copyPlugin(plugin, prefix)) {
|
||||
if (!copyPlugin(plugin, package)) {
|
||||
qWarning() << plugin << " not copied!";
|
||||
}
|
||||
}
|
||||
copyExtraPlugins(prefix);
|
||||
copyExtraPlugins(package);
|
||||
}
|
||||
|
||||
void Extracter::extractAllTargets() {
|
||||
auto cfg = DeployCore::_config;
|
||||
for (auto i = cfg->prefixes().cbegin(); i != cfg->prefixes().cend(); ++i) {
|
||||
_prefixDependencyes[i.key()] = {};
|
||||
for (auto i = cfg->packages().cbegin(); i != cfg->packages().cend(); ++i) {
|
||||
_packageDependencyes[i.key()] = {};
|
||||
|
||||
for (const auto &target : i.value().targets()) {
|
||||
extract(target, &_prefixDependencyes[i.key()]);
|
||||
extract(target, &_packageDependencyes[i.key()]);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -167,19 +167,19 @@ void Extracter::extractPlugins() {
|
||||
auto cnf = DeployCore::_config;
|
||||
PluginsParser pluginsParser;
|
||||
|
||||
for (auto i = cnf->prefixes().cbegin(); i != cnf->prefixes().cend(); ++i) {
|
||||
auto distro = cnf->getDistroFromPrefix(i.key());
|
||||
for (auto i = cnf->packages().cbegin(); i != cnf->packages().cend(); ++i) {
|
||||
auto distro = cnf->getDistroFromPackage(i.key());
|
||||
|
||||
QStringList plugins;
|
||||
pluginsParser.scan(cnf->qtDir.getPlugins(), plugins, _prefixDependencyes[i.key()].qtModules());
|
||||
pluginsParser.scan(cnf->qtDir.getPlugins(), plugins, _packageDependencyes[i.key()].qtModules());
|
||||
copyPlugins(plugins, i.key());
|
||||
}
|
||||
}
|
||||
|
||||
void Extracter::copyLibs(const QSet<QString> &files, const QString& prefix) {
|
||||
void Extracter::copyLibs(const QSet<QString> &files, const QString& package) {
|
||||
auto cnf = DeployCore::_config;
|
||||
auto targetPath = cnf->getTargetDir() + prefix;
|
||||
auto distro = cnf->getDistroFromPrefix(prefix);
|
||||
auto targetPath = cnf->getTargetDir() + package;
|
||||
auto distro = cnf->getDistroFromPackage(package);
|
||||
|
||||
for (const auto &file : files) {
|
||||
if (!_fileManager->smartCopyFile(file, targetPath + distro.getLibOutDir())) {
|
||||
@ -191,12 +191,12 @@ void Extracter::copyLibs(const QSet<QString> &files, const QString& prefix) {
|
||||
void Extracter::copyFiles() {
|
||||
auto cnf = DeployCore::_config;
|
||||
|
||||
for (auto i = cnf->prefixes().cbegin(); i != cnf->prefixes().cend(); ++i) {
|
||||
for (auto i = cnf->packages().cbegin(); i != cnf->packages().cend(); ++i) {
|
||||
|
||||
copyLibs(_prefixDependencyes[i.key()].neadedLibs(), i.key());
|
||||
copyLibs(_packageDependencyes[i.key()].neadedLibs(), i.key());
|
||||
|
||||
if (QuasarAppUtils::Params::isEndable("deploySystem")) {
|
||||
copyLibs(_prefixDependencyes[i.key()].systemLibs(), i.key());
|
||||
copyLibs(_packageDependencyes[i.key()].systemLibs(), i.key());
|
||||
}
|
||||
|
||||
if (!QuasarAppUtils::Params::isEndable("noStrip") && !_fileManager->strip(cnf->getTargetDir())) {
|
||||
@ -211,8 +211,8 @@ void Extracter::copyTr() {
|
||||
|
||||
auto cnf = DeployCore::_config;
|
||||
|
||||
for (auto i = cnf->prefixes().cbegin(); i != cnf->prefixes().cend(); ++i) {
|
||||
if (!copyTranslations(DeployCore::extractTranslation(_prefixDependencyes[i.key()].neadedLibs()),
|
||||
for (auto i = cnf->packages().cbegin(); i != cnf->packages().cend(); ++i) {
|
||||
if (!copyTranslations(DeployCore::extractTranslation(_packageDependencyes[i.key()].neadedLibs()),
|
||||
i.key())) {
|
||||
QuasarAppUtils::Params::verboseLog("Failed to copy standard Qt translations",
|
||||
QuasarAppUtils::Warning);
|
||||
@ -254,7 +254,7 @@ void Extracter::deploy() {
|
||||
|
||||
}
|
||||
|
||||
bool Extracter::copyTranslations(const QStringList &list, const QString& prefix) {
|
||||
bool Extracter::copyTranslations(const QStringList &list, const QString& package) {
|
||||
|
||||
auto cnf = DeployCore::_config;
|
||||
|
||||
@ -270,14 +270,14 @@ bool Extracter::copyTranslations(const QStringList &list, const QString& prefix)
|
||||
|
||||
auto listItems = dir.entryInfoList(filters, QDir::Files | QDir::NoDotAndDotDot);
|
||||
|
||||
auto targetPath = cnf->getTargetDir() + prefix;
|
||||
auto distro = cnf->getDistroFromPrefix(prefix);
|
||||
auto targetPath = cnf->getTargetDir() + package;
|
||||
auto distro = cnf->getDistroFromPackage(package);
|
||||
|
||||
for (const auto &i: listItems) {
|
||||
_fileManager->copyFile(i.absoluteFilePath(), targetPath + distro.getTrOutDir());
|
||||
}
|
||||
|
||||
if (isWebEngine(prefix)) {
|
||||
if (isWebEngine(package)) {
|
||||
auto trOut = targetPath + distro.getTrOutDir();
|
||||
auto tr = DeployCore::_config->qtDir.getTranslations() + "/qtwebengine_locales";
|
||||
_fileManager->copyFolder(tr, trOut + "/qtwebengine_locales");
|
||||
@ -351,9 +351,9 @@ bool Extracter::extractQmlAll() {
|
||||
auto cnf = DeployCore::_config;
|
||||
|
||||
|
||||
for (auto i = cnf->prefixes().cbegin(); i != cnf->prefixes().cend(); ++i) {
|
||||
for (auto i = cnf->packages().cbegin(); i != cnf->packages().cend(); ++i) {
|
||||
auto targetPath = cnf->getTargetDir() + i.key();
|
||||
auto distro = cnf->getDistroFromPrefix(i.key());
|
||||
auto distro = cnf->getDistroFromPackage(i.key());
|
||||
|
||||
QStringList listItems;
|
||||
|
||||
@ -365,9 +365,9 @@ bool Extracter::extractQmlAll() {
|
||||
|
||||
for (const auto &item : listItems) {
|
||||
if (QuasarAppUtils::Params::isEndable("extractPlugins")) {
|
||||
extract(item, &_prefixDependencyes[i.key()]);
|
||||
extract(item, &_packageDependencyes[i.key()]);
|
||||
} else {
|
||||
extract(item, &_prefixDependencyes[i.key()], "Qt");
|
||||
extract(item, &_packageDependencyes[i.key()], "Qt");
|
||||
}
|
||||
}
|
||||
|
||||
@ -380,9 +380,9 @@ bool Extracter::extractQmlFromSource(const QString& sourceDir) {
|
||||
|
||||
auto cnf = DeployCore::_config;
|
||||
|
||||
for (auto i = cnf->prefixes().cbegin(); i != cnf->prefixes().cend(); ++i) {
|
||||
for (auto i = cnf->packages().cbegin(); i != cnf->packages().cend(); ++i) {
|
||||
auto targetPath = cnf->getTargetDir() + i.key();
|
||||
auto distro = cnf->getDistroFromPrefix(i.key());
|
||||
auto distro = cnf->getDistroFromPackage(i.key());
|
||||
|
||||
QStringList plugins;
|
||||
QStringList listItems;
|
||||
@ -419,9 +419,9 @@ bool Extracter::extractQmlFromSource(const QString& sourceDir) {
|
||||
|
||||
for (const auto &item : listItems) {
|
||||
if (QuasarAppUtils::Params::isEndable("extractPlugins")) {
|
||||
extract(item, &_prefixDependencyes[i.key()]);
|
||||
extract(item, &_packageDependencyes[i.key()]);
|
||||
} else {
|
||||
extract(item, &_prefixDependencyes[i.key()], "Qt");
|
||||
extract(item, &_packageDependencyes[i.key()], "Qt");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -22,7 +22,7 @@ class MetaFileManager;
|
||||
class DEPLOYSHARED_EXPORT Extracter {
|
||||
private:
|
||||
|
||||
QHash<QString, DependencyMap> _prefixDependencyes;
|
||||
QHash<QString, DependencyMap> _packageDependencyes;
|
||||
|
||||
DependenciesScanner *_scaner;
|
||||
FileManager *_fileManager;
|
||||
@ -30,7 +30,7 @@ class DEPLOYSHARED_EXPORT Extracter {
|
||||
MetaFileManager *_metaFileManager;
|
||||
|
||||
void extract(const QString &file, DependencyMap* depMap, const QString& mask = "");
|
||||
bool copyTranslations(const QStringList &list, const QString &prefix);
|
||||
bool copyTranslations(const QStringList &list, const QString &package);
|
||||
|
||||
bool extractQml();
|
||||
|
||||
@ -48,8 +48,8 @@ class DEPLOYSHARED_EXPORT Extracter {
|
||||
bool extractWebEngine();
|
||||
|
||||
|
||||
bool copyPlugin(const QString &plugin, const QString &prefix);
|
||||
void copyPlugins(const QStringList &list, const QString &prefix);
|
||||
bool copyPlugin(const QString &plugin, const QString &package);
|
||||
void copyPlugins(const QStringList &list, const QString &package);
|
||||
|
||||
/**
|
||||
* @brief compress - this function join all target dependecies in to one struct
|
||||
@ -59,10 +59,10 @@ class DEPLOYSHARED_EXPORT Extracter {
|
||||
void extractPlugins();
|
||||
void copyFiles();
|
||||
void copyTr();
|
||||
void copyExtraPlugins(const QString &prefix);
|
||||
void copyLibs(const QSet<QString> &files, const QString &prefix);
|
||||
void copyExtraPlugins(const QString &package);
|
||||
void copyLibs(const QSet<QString> &files, const QString &package);
|
||||
|
||||
bool isWebEngine(const QString& prefix) const;
|
||||
bool isWebEngine(const QString& package) const;
|
||||
public:
|
||||
explicit Extracter(FileManager *fileManager, ConfigParser * cqt, DependenciesScanner *_scaner);
|
||||
void deploy();
|
||||
|
@ -174,7 +174,7 @@ bool MetaFileManager::createQConf(const QString &target) {
|
||||
|
||||
QString content =
|
||||
"[Paths]\n"
|
||||
"Prefix= ." + distro.getRootDir(distro.getBinOutDir()) + "\n"
|
||||
"Package= ." + distro.getRootDir(distro.getBinOutDir()) + "\n"
|
||||
"Libraries= ." + distro.getLibOutDir() + "\n"
|
||||
"Plugins= ." + distro.getPluginsOutDir() + "\n"
|
||||
"Imports= ." + distro.getQmlOutDir() + "\n"
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -24,7 +24,7 @@ public:
|
||||
static QSet<QString> qtLibs();
|
||||
static QSet<QString> qmlLibs();
|
||||
static QSet<QString> qmlLibsExtractPlugins();
|
||||
static QSet<QString> separetedPrefixeslibs();
|
||||
static QSet<QString> separetedPackageslibs();
|
||||
|
||||
static QSet<QString> outTestLibs();
|
||||
|
||||
|
@ -97,8 +97,8 @@ private slots:
|
||||
// tested flags confFile
|
||||
void testConfFile();
|
||||
|
||||
// tested flags targetPrefix
|
||||
void testPrefixes();
|
||||
// tested flags targetPackage
|
||||
void testPackages();
|
||||
|
||||
// tested flags qmlDir qmake
|
||||
void testQt();
|
||||
@ -613,15 +613,15 @@ void deploytest::testQIF() {
|
||||
bin += "," + target2;
|
||||
bin += "," + target3;
|
||||
|
||||
auto prefixString = "/prefix1/;" + QFileInfo(target1).absoluteFilePath() + ",/prefix2/;" + QFileInfo(target2).absoluteFilePath();
|
||||
auto packageString = "/package1/;" + QFileInfo(target1).absoluteFilePath() + ",/package2/;" + QFileInfo(target2).absoluteFilePath();
|
||||
runTestParams({"-bin", bin, "force-clear",
|
||||
"-binOut", "/lol",
|
||||
"-libOut", "/lolLib",
|
||||
"-trOut", "/lolTr",
|
||||
"-pluginOut", "/p",
|
||||
"-qmlOut", "/q",
|
||||
"-qmlDir", "prefix2;" + TestBinDir + "/../TestQMLWidgets",
|
||||
"-targetPrefix", prefixString, "qif"}, &comapareTree);
|
||||
"-qmlDir", "package2;" + TestBinDir + "/../TestQMLWidgets",
|
||||
"-targetPackage", packageString, "qif"}, &comapareTree);
|
||||
|
||||
}
|
||||
|
||||
@ -633,9 +633,13 @@ void deploytest::testInit()
|
||||
runTestParams({"init"});
|
||||
runTestParams({});
|
||||
|
||||
QVERIFY(QFile(DEFAULT_COFIGURATION_FILE).remove());
|
||||
|
||||
runTestParams({"-init", "multiPackage"});
|
||||
runTestParams({});
|
||||
|
||||
QVERIFY(QFile(DEFAULT_COFIGURATION_FILE).remove());
|
||||
|
||||
}
|
||||
|
||||
void deploytest::testDependencyMap() {
|
||||
@ -1336,24 +1340,24 @@ void deploytest::testConfFile() {
|
||||
QFile f("./" + DISTRO_DIR + "/bin/TestOnlyC");
|
||||
comapareTree = utils.createTree(
|
||||
{
|
||||
"./" + DISTRO_DIR + "/prefix/TestOnlyC.sh",
|
||||
"./" + DISTRO_DIR + "/prefix/bin/TestOnlyC",
|
||||
"./" + DISTRO_DIR + "/prefix/bin/qt.conf"
|
||||
"./" + DISTRO_DIR + "/package/TestOnlyC.sh",
|
||||
"./" + DISTRO_DIR + "/package/bin/TestOnlyC",
|
||||
"./" + DISTRO_DIR + "/package/bin/qt.conf"
|
||||
});
|
||||
QString target1 = TestBinDir + "TestOnlyC";
|
||||
|
||||
#else
|
||||
QFile f("./" + DISTRO_DIR + "/TestOnlyC.exe");
|
||||
comapareTree = utils.createTree(
|
||||
{"./" + DISTRO_DIR + "/prefix/TestOnlyC.exe",
|
||||
"./" + DISTRO_DIR + "/prefix/qt.conf"});
|
||||
{"./" + DISTRO_DIR + "/package/TestOnlyC.exe",
|
||||
"./" + DISTRO_DIR + "/package/qt.conf"});
|
||||
QString target1 = TestBinDir + "TestOnlyC.exe";
|
||||
|
||||
#endif
|
||||
bin = target1;
|
||||
|
||||
runTestParams({"-bin", bin, "force-clear",
|
||||
"-targetPrefix", "prefix;Test",
|
||||
"-targetPackage", "package;Test",
|
||||
"-confFile", TestBinDir + "/../folder/For/Testing/Deploy/File/TestConf.json"}, &comapareTree);
|
||||
|
||||
runTestParams({"-confFile", TestBinDir + "/../folder/For/Testing/Deploy/File/TestConf.json"},
|
||||
@ -1364,34 +1368,34 @@ void deploytest::testConfFile() {
|
||||
|
||||
}
|
||||
|
||||
void deploytest::testPrefixes() {
|
||||
void deploytest::testPackages() {
|
||||
TestUtils utils;
|
||||
|
||||
#ifdef Q_OS_UNIX
|
||||
QFile f("./" + DISTRO_DIR + "/bin/TestOnlyC");
|
||||
auto comapareTree = utils.createTree(
|
||||
{
|
||||
"./" + DISTRO_DIR + "/prefix/TestOnlyC.sh",
|
||||
"./" + DISTRO_DIR + "/prefix/bin/TestOnlyC",
|
||||
"./" + DISTRO_DIR + "/prefix/bin/qt.conf"
|
||||
"./" + DISTRO_DIR + "/package/TestOnlyC.sh",
|
||||
"./" + DISTRO_DIR + "/package/bin/TestOnlyC",
|
||||
"./" + DISTRO_DIR + "/package/bin/qt.conf"
|
||||
});
|
||||
QString target1 = TestBinDir + "TestOnlyC";
|
||||
|
||||
#else
|
||||
QFile f("./" + DISTRO_DIR + "/TestOnlyC.exe");
|
||||
auto comapareTree = utils.createTree(
|
||||
{"./" + DISTRO_DIR + "/prefix/TestOnlyC.exe",
|
||||
"./" + DISTRO_DIR + "/prefix/qt.conf"});
|
||||
{"./" + DISTRO_DIR + "/package/TestOnlyC.exe",
|
||||
"./" + DISTRO_DIR + "/package/qt.conf"});
|
||||
QString target1 = TestBinDir + "TestOnlyC.exe";
|
||||
|
||||
#endif
|
||||
QString bin = target1;
|
||||
|
||||
runTestParams({"-bin", bin, "force-clear",
|
||||
"-targetPrefix", "/prefix/;Test"}, &comapareTree);
|
||||
"-targetPackage", "/package/;Test"}, &comapareTree);
|
||||
|
||||
runTestParams({"-bin", bin, "force-clear",
|
||||
"-targetPrefix", "/prefix/;" + QFileInfo(target1).absoluteFilePath()}, &comapareTree);
|
||||
"-targetPackage", "/package/;" + QFileInfo(target1).absoluteFilePath()}, &comapareTree);
|
||||
|
||||
#ifdef Q_OS_UNIX
|
||||
QString target2 = TestBinDir + "TestQMLWidgets";
|
||||
@ -1405,9 +1409,9 @@ void deploytest::testPrefixes() {
|
||||
bin += "," + target2;
|
||||
bin += "," + target3;
|
||||
|
||||
auto prefixString = "/prefix1/;" + QFileInfo(target1).absoluteFilePath() + ",/prefix2/;" + QFileInfo(target2).absoluteFilePath();
|
||||
auto packageString = "/package1/;" + QFileInfo(target1).absoluteFilePath() + ",/package2/;" + QFileInfo(target2).absoluteFilePath();
|
||||
|
||||
comapareTree = Modules::separetedPrefixeslibs();
|
||||
comapareTree = Modules::separetedPackageslibs();
|
||||
|
||||
runTestParams({"-bin", bin, "force-clear",
|
||||
"-binOut", "/lol",
|
||||
@ -1415,27 +1419,27 @@ void deploytest::testPrefixes() {
|
||||
"-trOut", "/lolTr",
|
||||
"-pluginOut", "/p",
|
||||
"-qmlOut", "/q",
|
||||
"-qmlDir", "prefix2;" + TestBinDir + "/../TestQMLWidgets",
|
||||
"-targetPrefix", prefixString}, &comapareTree);
|
||||
"-qmlDir", "package2;" + TestBinDir + "/../TestQMLWidgets",
|
||||
"-targetPackage", packageString}, &comapareTree);
|
||||
|
||||
comapareTree -= utils.createTree({
|
||||
"./" + DISTRO_DIR + "/prefix2/bin/TestQMLWidgets",
|
||||
"./" + DISTRO_DIR + "/prefix2/bin/qt.conf",
|
||||
"./" + DISTRO_DIR + "/package2/bin/TestQMLWidgets",
|
||||
"./" + DISTRO_DIR + "/package2/bin/qt.conf",
|
||||
});
|
||||
|
||||
comapareTree += utils.createTree({
|
||||
"./" + DISTRO_DIR + "/prefix2/testBin/TestQMLWidgets",
|
||||
"./" + DISTRO_DIR + "/prefix2/testBin/qt.conf",
|
||||
"./" + DISTRO_DIR + "/package2/testBin/TestQMLWidgets",
|
||||
"./" + DISTRO_DIR + "/package2/testBin/qt.conf",
|
||||
});
|
||||
|
||||
runTestParams({"-bin", bin, "force-clear",
|
||||
"-binOut", "prefix2;/testBin,lol",
|
||||
"-binOut", "package2;/testBin,lol",
|
||||
"-libOut", "/lolLib",
|
||||
"-trOut", "/lolTr",
|
||||
"-pluginOut", "/p",
|
||||
"-qmlOut", "/q",
|
||||
"-qmlDir", "prefix2;" + TestBinDir + "/../TestQMLWidgets",
|
||||
"-targetPrefix", prefixString}, &comapareTree);
|
||||
"-qmlDir", "package2;" + TestBinDir + "/../TestQMLWidgets",
|
||||
"-targetPackage", packageString}, &comapareTree);
|
||||
|
||||
}
|
||||
|
||||
@ -2056,7 +2060,7 @@ void deploytest::testOutDirs() {
|
||||
auto runScript = file.readAll();
|
||||
file.close();
|
||||
|
||||
QVERIFY(runScript.contains("Prefix= ./../"));
|
||||
QVERIFY(runScript.contains("Package= ./../"));
|
||||
QVERIFY(runScript.contains("Libraries= ./lolLib/"));
|
||||
QVERIFY(runScript.contains("Plugins= ./p/"));
|
||||
QVERIFY(runScript.contains("Imports= ./q/"));
|
||||
|
Loading…
x
Reference in New Issue
Block a user