summaryrefslogtreecommitdiffstats
path: root/tools/repogen
diff options
context:
space:
mode:
authorKatja Marttila <katja.marttila@qt.io>2020-06-09 15:52:07 +0300
committerKatja Marttila <katja.marttila@qt.io>2020-06-10 10:50:38 +0300
commitfc973b4c0b1b4e30ff69564565fd30e5ac18524a (patch)
tree2ab15bcd0b92e08a3729d7e89942a8d2c29a2c20 /tools/repogen
parenta5d8d25531597de44d8296c1686a659122d9882e (diff)
Fix united-metadata creation
Creating repositories caused sha mismatch detect if installed with IFW version 3.2 or lower. Also changed the behavior that without any switches both united and component metadata will be created. --unite-metadata will create only one combined metadata and --component-metadata the old style where each component has their own meta 7z file. Change-Id: I60d3b56217917739fb8115771af8c3bcf9e59f43 Reviewed-by: Iikka Eklund <iikka.eklund@qt.io>
Diffstat (limited to 'tools/repogen')
-rw-r--r--tools/repogen/repogen.cpp18
1 files changed, 8 insertions, 10 deletions
diff --git a/tools/repogen/repogen.cpp b/tools/repogen/repogen.cpp
index 2d16fa720..922bdfe30 100644
--- a/tools/repogen/repogen.cpp
+++ b/tools/repogen/repogen.cpp
@@ -69,12 +69,10 @@ static void printUsage()
std::cout << " -v|--verbose Verbose output" << std::endl;
std::cout << " --unite-metadata Combine all metadata into one 7z. This speeds up metadata " << std::endl;
- std::cout << " download phase. Creates also metadata 7z per component for " << std::endl;
- std::cout << " backward compatibility." << std::endl;
-
- std::cout << " --unite-metadata-only Combine all metadata into one 7z. This speeds up metadata " << std::endl;
std::cout << " download phase." << std::endl;
+ std::cout << " --component-metadata Creates one metadata 7z per component. " << std::endl;
+
std::cout << std::endl;
std::cout << "Example:" << std::endl;
std::cout << " " << appName << " -p ../examples/packages repository/"
@@ -106,8 +104,8 @@ int main(int argc, char** argv)
QInstallerTools::FilterType filterType = QInstallerTools::Exclude;
bool remove = false;
bool updateExistingRepositoryWithNewComponents = false;
- bool createUnitedMetadata = false;
- bool createOnlyUnitedMetadata = false;
+ bool createUnifiedMetadata = true;
+ bool createComponentMetadata = true;
//TODO: use a for loop without removing values from args like it is in binarycreator.cpp
//for (QStringList::const_iterator it = args.begin(); it != args.end(); ++it) {
@@ -186,10 +184,10 @@ int main(int argc, char** argv)
remove = true;
args.removeFirst();
} else if (args.first() == QLatin1String("--unite-metadata")) {
- createUnitedMetadata = true;
+ createComponentMetadata = false;
args.removeFirst();
- } else if (args.first() == QLatin1String("--unite-metadata-only")) {
- createOnlyUnitedMetadata = true;
+ } else if (args.first() == QLatin1String("--component-metadata")) {
+ createUnifiedMetadata = false;
args.removeFirst();
}
else {
@@ -298,7 +296,7 @@ int main(int argc, char** argv)
QInstallerTools::copyMetaData(tmpMetaDir, repositoryDir, packages, QLatin1String("{AnyApplication}"),
QLatin1String(QUOTE(IFW_REPOSITORY_FORMAT_VERSION)));
QInstallerTools::compressMetaDirectories(tmpMetaDir, tmpMetaDir, pathToVersionMapping,
- createUnitedMetadata, createOnlyUnitedMetadata);
+ createComponentMetadata, createUnifiedMetadata);
QDirIterator it(repositoryDir, QStringList(QLatin1String("Updates*.xml")), QDir::Files | QDir::CaseSensitive);
while (it.hasNext()) {