DMG license causes issues in Qbs.

This commit is contained in:
Roman Telezhynskyi 2023-09-15 09:21:13 +03:00
parent ea71d5ff56
commit e5087302e7
2 changed files with 15 additions and 5 deletions

View File

@ -693,7 +693,7 @@ for:
python3 ./scripts/treestate.py scan /usr/local usrlocal.json python3 ./scripts/treestate.py scan /usr/local usrlocal.json
brew update brew update
brew install coreutils ccache git openssl@1.1 pkg-config brew install coreutils ccache git openssl@1.1 pkg-config qbs
# The build environment is now ready for use. We can complete # The build environment is now ready for use. We can complete
# the rest of the process of creating the Homebrew archive # the rest of the process of creating the Homebrew archive
@ -725,6 +725,10 @@ for:
- qmake --version - qmake --version
- which qmake - which qmake
- qbs --version - qbs --version
# Patch Qbs. Remove after Qbs 2.1.2+.
- curl https://gist.githubusercontent.com/dismine/43a20f66f563232e54e02f2e85732e7a/raw/e80a0c827348da3e99310ba4a648c1860bb3a8a6/BundleModule.qbs --output $HOME/BundleModule.qbs --silent
- cp -f $HOME/BundleModule.qbs $(brew --prefix qbs)/share/qbs/modules/bundle/BundleModule.qbs
- rm $HOME/BundleModule.qbs
- cd ${APPVEYOR_BUILD_FOLDER} - cd ${APPVEYOR_BUILD_FOLDER}
build_script: build_script:

14
dmg.qbs
View File

@ -1,5 +1,6 @@
import qbs.File import qbs.File
import qbs.FileInfo import qbs.FileInfo
import qbs.Utilities
VAppleApplicationDiskImage { VAppleApplicationDiskImage {
Depends { name: "buildconfig" } Depends { name: "buildconfig" }
@ -43,10 +44,15 @@ VAppleApplicationDiskImage {
codesign.signingType: "apple-id" codesign.signingType: "apple-id"
} }
files: [ files: {
"dist/macx/dmg/dmg.iconset", var files = ["dist/macx/dmg/dmg.iconset"];
"dist/macx/dmg/en_US.lproj/LICENSE"
] // Tested on 2.1.1. At least this version doesn't crash even if the feature still doesn't work
if (Utilities.versionCompare(qbs.version, "2.1.1") >= 0)
files.push("dist/macx/dmg/en_US.lproj/LICENSE");
return files;
}
Group { Group {
name: "Bundles" name: "Bundles"