From d15020c4ae0ebbbb0f82e74f1351de0b60a65e28 Mon Sep 17 00:00:00 2001 From: bgallois Date: Mon, 21 Oct 2024 14:44:45 +0200 Subject: [PATCH] [fix] ci: fix macos dmg --- .github/workflows/build.yml | 14 ++++++++++++-- .github/workflows/build_cli.yml | 4 +++- src/FastTrack-Cli.pro | 1 + src/FastTrack.pro | 1 + 4 files changed, 17 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2d6ef00..0bfd68f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -99,7 +99,7 @@ jobs: path: src/build/FastTrack build_mac: - runs-on: macos-latest + runs-on: macos-14 steps: - uses: actions/checkout@v2 - uses: actions/setup-python@v2 @@ -141,8 +141,18 @@ jobs: macdeployqt FastTrack.app -always-overwrite wget https://raw.githubusercontent.com/tamlok/macdeployqtfix/master/macdeployqtfix.py cp *.qm FastTrack.app/Contents/Resources/ - python macdeployqtfix.py FastTrack.app/Contents/MacOS/FastTrack ../../Qt/${{ env.QT_VERSION }}/ + find / -name "libgcc_s.1.1.dylib" -exec cp {} FastTrack.app/Contents/Frameworks/ \; 2> >(tee /dev/stderr) || true + find / -name "libtbb*.dylib" -exec cp {} FastTrack.app/Contents/Frameworks/ \; 2> >(tee /dev/stderr) || true + cp /opt/homebrew/Cellar/opencv/*/lib/lib*.dylib FastTrack.app/Contents/Frameworks/ # Should (and was) be automatically done by macdeployqt! + python macdeployqtfix.py fasttrack.app/contents/macos/fasttrack ../../Qt/${{ env.QT_VERSION }}/ hdiutil create -volname FastTrack -srcfolder FastTrack.app -ov -format UDZO FastTrack.dmg + - name: test_ft + run: | + cd build/ + open FastTrack.app & + sleep 20 + log show --predicate 'process == "FastTrack"' --info + pkill -f FastTrack - name: upload_artefact uses: actions/upload-artifact@v4 with: diff --git a/.github/workflows/build_cli.yml b/.github/workflows/build_cli.yml index 84ebf93..6a4b251 100644 --- a/.github/workflows/build_cli.yml +++ b/.github/workflows/build_cli.yml @@ -92,7 +92,7 @@ jobs: path: src/build_cli/ build_mac: - runs-on: macos-latest + runs-on: macos-14 steps: - uses: actions/checkout@v2 - uses: actions/setup-python@v2 @@ -133,6 +133,8 @@ jobs: cd build_cli/ macdeployqt FastTrack-cli.app -always-overwrite wget https://raw.githubusercontent.com/tamlok/macdeployqtfix/master/macdeployqtfix.py + find / -name "libgcc_s.1.1.dylib" -exec cp {} FastTrack.app/Contents/Frameworks/ \; >/dev/null 2>&1 || true + cp /opt/homebrew/Cellar/opencv/*/lib/lib*.dylib FastTrack.app/Contents/Frameworks/ # Should (and was) be automatically done by macdeployqt! python macdeployqtfix.py FastTrack-cli.app/Contents/MacOS/FastTrack-cli ../../Qt/${{ env.QT_VERSION }}/ hdiutil create -volname FastTrack-cli -srcfolder FastTrack-cli.app -ov -format UDZO FastTrack-cli.dmg - name: upload_artefact diff --git a/src/FastTrack-Cli.pro b/src/FastTrack-Cli.pro index 507294f..891079b 100644 --- a/src/FastTrack-Cli.pro +++ b/src/FastTrack-Cli.pro @@ -48,6 +48,7 @@ unix:macx { QT_CONFIG -= no-pkg-config CONFIG += link_pkgconfig PKGCONFIG += opencv4 + PKGCONFIG += protobuf ICON=assets/icon.icns } diff --git a/src/FastTrack.pro b/src/FastTrack.pro index 10c9788..fe72544 100644 --- a/src/FastTrack.pro +++ b/src/FastTrack.pro @@ -73,6 +73,7 @@ unix:macx { QT_CONFIG -= no-pkg-config CONFIG += link_pkgconfig PKGCONFIG += opencv4 + PKGCONFIG += protobuf ICON=assets/icon.icns }