diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ca61a1b..0fa9865 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -73,19 +73,19 @@ jobs: p12-file-base64: ${{ secrets.MACOS_CERTIFICATE }} p12-password: ${{ secrets.MACOS_CERTIFICATE_PWD }} - - run: make target/gyroflow-ofx-macosx.zip + - run: make target/gyroflow-ofx-macosx.dmg env: SIGNING_FINGERPRINT: ${{ secrets.MACOS_CERTIFICATE_FINGERPRINT }} - name: Notarize and staple release build run: | - npx notarize-cli --file target/gyroflow-ofx-macosx.zip --bundle-id xyz.gyroflow.ofx --asc-provider="${{ secrets.MACOS_TEAM }}" --username="${{ secrets.MACOS_ACCOUNT_USER }}" --password="${{ secrets.MACOS_ACCOUNT_PASS }}" - xcrun stapler staple --verbose target/gyroflow-ofx-macosx.zip + npx notarize-cli --file target/gyroflow-ofx-macosx.dmg --bundle-id xyz.gyroflow.ofx --asc-provider="${{ secrets.MACOS_TEAM }}" --username="${{ secrets.MACOS_ACCOUNT_USER }}" --password="${{ secrets.MACOS_ACCOUNT_PASS }}" + xcrun stapler staple --verbose target/gyroflow-ofx-macosx.dmg - name: Release uses: softprops/action-gh-release@v1 if: startsWith(github.ref, 'refs/tags/') with: - files: target/gyroflow-ofx-macosx.zip + files: target/gyroflow-ofx-macosx.dmg env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/Makefile b/Makefile index e31a513..1028d11 100644 --- a/Makefile +++ b/Makefile @@ -10,19 +10,25 @@ target/gyroflow-ofx-linux.zip: target/release/libgyroflow_ofx.so LICENSE README. cp target/bundle-common/Info.plist LICENSE README.md target/gyroflow-ofx-linux/GyroFlow.ofx.bundle/Contents/ cd target/gyroflow-ofx-linux && zip -r ../gyroflow-ofx-linux.zip . -target/gyroflow-ofx-macosx.zip: target/x86_64-apple-darwin/release/libgyroflow_ofx.dylib target/aarch64-apple-darwin/release/libgyroflow_ofx.dylib LICENSE README.md target/bundle-common/Info.plist Makefile +target/gyroflow-ofx-macosx.dmg: target/x86_64-apple-darwin/release/libgyroflow_ofx.dylib target/aarch64-apple-darwin/release/libgyroflow_ofx.dylib LICENSE README.md target/bundle-common/Info.plist Makefile rm -Rf target/gyroflow-ofx-macosx - rm -f target/gyroflow-ofx-macosx.zip + rm -f target/gyroflow-ofx-macosx.dmg mkdir -p target/gyroflow-ofx-macosx/GyroFlow.ofx.bundle/Contents/MacOS - lipo target/{x86_64,aarch64}-apple-darwin/release/libgyroflow_ofx.dylib -create -output target/gyroflow-ofx-macosx/GyroFlow.ofx.bundle/Contents/MacOS/GyroFlow.ofx + + lipo target/{x86_64,aarch64}-apple-darwin/release/libgyroflow_ofx.dylib -create -output target/gyroflow-ofx-macosx/GyroFlow.ofx.bundle/Contents/MacOS/GyroFlow.dylib cp target/bundle-common/Info.plist LICENSE README.md target/gyroflow-ofx-macosx/GyroFlow.ofx.bundle/Contents/ - codesign -vvvv --strict --options=runtime --timestamp --force -s ${SIGNING_FINGERPRINT} target/gyroflow-ofx-macosx/GyroFlow.ofx.bundle/Contents/MacOS/GyroFlow.ofx + codesign -vvvv --strict --options=runtime --timestamp --force -s ${SIGNING_FINGERPRINT} target/gyroflow-ofx-macosx/GyroFlow.ofx.bundle/Contents/MacOS/GyroFlow.dylib + mv target/gyroflow-ofx-macosx/GyroFlow.ofx.bundle/Contents/MacOS/GyroFlow.dylib target/gyroflow-ofx-macosx/GyroFlow.ofx.bundle/Contents/MacOS/GyroFlow.ofx + + codesign -vvvv --deep --strict --options=runtime --timestamp --force -s ${SIGNING_FINGERPRINT} target/gyroflow-ofx-macosx/GyroFlow.ofx.bundle + codesign -vvvv --deep --verify target/gyroflow-ofx-macosx/GyroFlow.ofx.bundle - cd target/gyroflow-ofx-macosx && zip -r ../gyroflow-ofx-macosx.zip . + ln -sf /Library/OFX/Plugins "target/gyroflow-ofx-macosx/" + hdiutil create "target/gyroflow-ofx-macosx.dmg" -volname "Gyroflow-ofx" -fs HFS+ -srcfolder "target/gyroflow-ofx-macosx/" -ov -format UDZO -imagekey zlib-level=9 - codesign -vvvv --strict --options=runtime --timestamp --force -s ${SIGNING_FINGERPRINT} ../gyroflow-ofx-macosx.zip - codesign -vvvv --deep --verify ../gyroflow-ofx-macosx.zip + codesign -vvvv --strict --options=runtime --timestamp --force -s ${SIGNING_FINGERPRINT} target/gyroflow-ofx-macosx.dmg + codesign -vvvv --deep --verify target/gyroflow-ofx-macosx.dmg target/gyroflow-ofx-windows.zip: target/release/gyroflow_ofx.dll LICENSE README.md target/bundle-common/Info.plist Makefile rm -Rf target/gyroflow-ofx-windows