Skip to content

Commit

Permalink
Windows: build xz in "Release" mode and bundle it in the installer (#673
Browse files Browse the repository at this point in the history
)

Also bump to Qt 6.6.0.
  • Loading branch information
grulja committed Dec 7, 2023
1 parent 41d213f commit 6a287e9
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/pr-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: pr-check
on: [pull_request]

env:
QT_VERSION: '6.5.3'
QT_VERSION: '6.6.0'

jobs:
Linux:
Expand Down Expand Up @@ -142,13 +142,13 @@ jobs:
eval "$(./dist/win/make-vs2019-env.bat)"
git clone https://git.tukaani.org/xz.git
cd xz
git checkout v5.2
git checkout v5.4.5
sed -i 's/#include "config.h"//' src/common/common_w32res.rc
sed -i 's/PACKAGE_NAME/"liblzma"/' src/common/common_w32res.rc
sed -i 's/PACKAGE_URL/"https:\/\/tukaani.org\/xz\/"/' src/common/common_w32res.rc
mkdir build
cd build
cmake .. -GNinja -DCMAKE_INSTALL_PREFIX="$Qt6_DIR" -DBUILD_SHARED_LIBS=ON ..
cmake .. -GNinja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX="$Qt6_DIR" -DBUILD_SHARED_LIBS=ON ..
cmake --build .
cmake --install .
Expand All @@ -169,7 +169,8 @@ jobs:
cd build/app/release
mv ../../src/app/helper.exe .
mv ../../src/app/mediawriter.exe .
$Qt6_DIR/bin/windeployqt.exe mediawriter.exe --verbose 2 --qmldir ../../.. --compiler-runtime --release
cp $Qt6_DIR/bin/liblzma.dll .
$Qt6_DIR/bin/windeployqt.exe mediawriter.exe helper.exe liblzma.dll --verbose 2 --qmldir ../../.. --compiler-runtime --release
find . -type d -not -path '*/\.*' | sed 's/^\.\///g' | sed 's@\/@\\@g' | grep -v "^.$" > uninstall.log
find . -type f -not -path '*/\.*' | sed 's/^\.\///g' | sed 's@\/@\\@g' | sort >> uninstall.log
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
types: [ created ]

env:
QT_VERSION: '6.5.3'
QT_VERSION: '6.6.0'

jobs:
macOS:
Expand Down Expand Up @@ -112,13 +112,13 @@ jobs:
eval "$(./dist/win/make-vs2019-env.bat)"
git clone https://git.tukaani.org/xz.git
cd xz
git checkout v5.2
git checkout v5.4.5
sed -i 's/#include "config.h"//' src/common/common_w32res.rc
sed -i 's/PACKAGE_NAME/"liblzma"/' src/common/common_w32res.rc
sed -i 's/PACKAGE_URL/"https:\/\/tukaani.org\/xz\/"/' src/common/common_w32res.rc
mkdir build
cd build
cmake .. -GNinja -DCMAKE_INSTALL_PREFIX="$Qt6_DIR" -DBUILD_SHARED_LIBS=ON ..
cmake .. -GNinja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX="$Qt6_DIR" -DBUILD_SHARED_LIBS=ON ..
cmake --build .
cmake --install .
Expand All @@ -139,7 +139,8 @@ jobs:
cd build/app/release
mv ../../src/app/helper.exe .
mv ../../src/app/mediawriter.exe .
$Qt6_DIR/bin/windeployqt.exe mediawriter.exe --verbose 2 --qmldir ../../.. --compiler-runtime --release
cp $Qt6_DIR/bin/liblzma.dll .
$Qt6_DIR/bin/windeployqt.exe mediawriter.exe helper.exe liblzma.dll --verbose 2 --qmldir ../../.. --compiler-runtime --release
find . -type d -not -path '*/\.*' | sed 's/^\.\///g' | sed 's@\/@\\@g' | grep -v "^.$" > uninstall.log
find . -type f -not -path '*/\.*' | sed 's/^\.\///g' | sed 's@\/@\\@g' | sort >> uninstall.log
Expand Down

0 comments on commit 6a287e9

Please sign in to comment.