diff --git a/.github/actions/mac-codesign/action.yml b/.github/actions/mac-codesign/action.yml index 70988a3009b..5f3e19bf57a 100644 --- a/.github/actions/mac-codesign/action.yml +++ b/.github/actions/mac-codesign/action.yml @@ -50,7 +50,7 @@ runs: ( cd install find ${{ inputs.path-to-sign }} \ - \( -name "*.dylib" -o -name "*.a" -o -name "*.so" -o -name "*.mxo" \) \ + \( -name "*.dylib" -o -name "*.a" -o -name "*.so" -o -name "*.mxo" -o -name "ossia.d_*" \) \ -exec echo Signing {} + \ -exec codesign --force --timestamp --sign "ossia.io" {} + diff --git a/.github/workflows/ossia-max.yml b/.github/workflows/ossia-max.yml index c41d43d5c52..426b6c925a5 100644 --- a/.github/workflows/ossia-max.yml +++ b/.github/workflows/ossia-max.yml @@ -11,57 +11,13 @@ jobs: - uses: ./.github/actions/latest-mac-toolchain - name: build run: ./tools/build-ossia-max.sh clean silent release - - name: Code Signing - shell: bash - env: + + - uses: ./.github/actions/mac-codesign + with: + path-to-sign: ossia MAC_CERT_B64: ${{ secrets.MAC_CERT_B64 }} MAC_CERT_PASSWORD: ${{ secrets.MAC_CERT_PASSWORD }} MAC_ALTOOL_PASSWORD: ${{ secrets.MAC_ALTOOL_PASSWORD }} - run: | - # Setup codesigning - # Thanks https://www.update.rocks/blog/osx-signing-with-travis/ - ( - set +x - KEY_CHAIN=build.keychain - echo "$MAC_CERT_B64" | base64 --decode > ossia-cert.p12 - - security create-keychain -p azure $KEY_CHAIN - security default-keychain -s $KEY_CHAIN - security unlock-keychain -p azure $KEY_CHAIN - security import ossia-cert.p12 -k $KEY_CHAIN -P "$MAC_CERT_PASSWORD" -T /usr/bin/codesign; - security set-key-partition-list -S apple-tool:,apple: -s -k azure $KEY_CHAIN - - rm -rf *.p12 - ) - - security unlock-keychain -p azure build.keychain - - echo "Checking codesigning" - find . -name libossia-max.dylib - ( - cd artifacts - echo "===== Content of artifacts" - ls - echo "===== Content of artifacts/ossia/support" - ls ossia/support - echo "===== Content of artifacts/ossia/externals" - ls ossia/externals - - codesign --force --timestamp --sign "ossia.io" ossia/support/libossia-max.dylib - for mxo in ossia/externals/*.mxo; - do - codesign --force --timestamp --sign "ossia.io" $mxo - done - - ditto -c -k --sequesterRsrc --keepParent ossia ossia-max.zip - xcrun altool \ - --notarize-app \ - -t osx \ - -f "ossia-max.zip" \ - --primary-bundle-id "io.ossia.ossia-max" \ - -u jeanmichael.celerier@gmail.com -p "@env:MAC_ALTOOL_PASSWORD" - rm ossia-max.zip - ) - name: Archive Max Package uses: actions/upload-artifact@v2 with: diff --git a/.github/workflows/ossia-pd.yml b/.github/workflows/ossia-pd.yml index 0850e3894b7..c14823a4dc3 100644 --- a/.github/workflows/ossia-pd.yml +++ b/.github/workflows/ossia-pd.yml @@ -22,44 +22,13 @@ jobs: cmake --build build cmake --build build --target install - - name: Code Signing - shell: bash - env: + - uses: ./.github/actions/mac-codesign + with: + path-to-sign: "install/ossia-pd-package" MAC_CERT_B64: ${{ secrets.MAC_CERT_B64 }} MAC_CERT_PASSWORD: ${{ secrets.MAC_CERT_PASSWORD }} MAC_ALTOOL_PASSWORD: ${{ secrets.MAC_ALTOOL_PASSWORD }} - run: | - # Setup codesigning - # Thanks https://www.update.rocks/blog/osx-signing-with-travis/ - ( - set +x - KEY_CHAIN=build.keychain - echo "$MAC_CERT_B64" | base64 --decode > ossia-cert.p12 - - security create-keychain -p azure $KEY_CHAIN - security default-keychain -s $KEY_CHAIN - security unlock-keychain -p azure $KEY_CHAIN - security import ossia-cert.p12 -k $KEY_CHAIN -P "$MAC_CERT_PASSWORD" -T /usr/bin/codesign; - security set-key-partition-list -S apple-tool:,apple: -s -k azure $KEY_CHAIN - - rm -rf *.p12 - ) - - security unlock-keychain -p azure build.keychain - - ( - cd install/ossia-pd-package - codesign --force --timestamp --sign "ossia.io" ossia/ossia.d_* - - zip ossia-pd.zip ossia/ossia.d_* - xcrun altool \ - --notarize-app \ - -t osx \ - -f "ossia-pd.zip" \ - --primary-bundle-id "io.ossia.ossia-pd" \ - -u jeanmichael.celerier@gmail.com -p "@env:MAC_ALTOOL_PASSWORD" - rm ossia-pd.zip - ) + - name: Archive Package uses: actions/upload-artifact@v2 with: @@ -92,11 +61,8 @@ jobs: run: | sudo apt-get update -yqq sudo apt-get upgrade -yqq - sudo apt-get install -yqq build-essential gcc-11 g++-11 ninja-build libavahi-client-dev + sudo apt-get install -yqq build-essential ninja-build libavahi-client-dev - name: Build - env: - CC: gcc-11 - CXX: g++-11 run: | cmake -B build -S ${GITHUB_WORKSPACE} -GNinja -DOSSIA_CI=1 -DCMAKE_BUILD_TYPE=Release -DOSSIA_PD_ONLY=1 -DCMAKE_INSTALL_PREFIX=install cmake --build build diff --git a/.github/workflows/ossia-purrdata.yml b/.github/workflows/ossia-purrdata.yml index 09ec88b0b9c..694e803cbe2 100644 --- a/.github/workflows/ossia-purrdata.yml +++ b/.github/workflows/ossia-purrdata.yml @@ -22,44 +22,14 @@ jobs: cmake --build build cmake --build build --target install - - name: Code Signing - shell: bash - env: + + - uses: ./.github/actions/mac-codesign + with: + path-to-sign: "install/ossia-pd-package" MAC_CERT_B64: ${{ secrets.MAC_CERT_B64 }} MAC_CERT_PASSWORD: ${{ secrets.MAC_CERT_PASSWORD }} MAC_ALTOOL_PASSWORD: ${{ secrets.MAC_ALTOOL_PASSWORD }} - run: | - # Setup codesigning - # Thanks https://www.update.rocks/blog/osx-signing-with-travis/ - ( - set +x - KEY_CHAIN=build.keychain - echo "$MAC_CERT_B64" | base64 --decode > ossia-cert.p12 - - security create-keychain -p azure $KEY_CHAIN - security default-keychain -s $KEY_CHAIN - security unlock-keychain -p azure $KEY_CHAIN - security import ossia-cert.p12 -k $KEY_CHAIN -P "$MAC_CERT_PASSWORD" -T /usr/bin/codesign; - security set-key-partition-list -S apple-tool:,apple: -s -k azure $KEY_CHAIN - - rm -rf *.p12 - ) - - security unlock-keychain -p azure build.keychain - - ( - cd install/ossia-pd-package - codesign --force --timestamp --sign "ossia.io" ossia/ossia.d_* - - zip ossia-pd.zip ossia/ossia.d_* - xcrun altool \ - --notarize-app \ - -t osx \ - -f "ossia-pd.zip" \ - --primary-bundle-id "io.ossia.ossia-pd" \ - -u jeanmichael.celerier@gmail.com -p "@env:MAC_ALTOOL_PASSWORD" - rm ossia-pd.zip - ) + - name: Archive Package uses: actions/upload-artifact@v2 with: diff --git a/.github/workflows/ossia-python.yml b/.github/workflows/ossia-python.yml index ff1bfb0a9f2..beb3f293125 100644 --- a/.github/workflows/ossia-python.yml +++ b/.github/workflows/ossia-python.yml @@ -16,36 +16,14 @@ jobs: -DOSSIA_CI=1 \ -DCMAKE_OSX_ARCHITECTURES="x86_64;arm64" cmake --build build - - name: Code Signing - shell: bash - env: + + - uses: ./.github/actions/mac-codesign + with: + path-to-sign: "build" MAC_CERT_B64: ${{ secrets.MAC_CERT_B64 }} MAC_CERT_PASSWORD: ${{ secrets.MAC_CERT_PASSWORD }} MAC_ALTOOL_PASSWORD: ${{ secrets.MAC_ALTOOL_PASSWORD }} - run: | - # Setup codesigning - # Thanks https://www.update.rocks/blog/osx-signing-with-travis/ - ( - set +x - KEY_CHAIN=build.keychain - echo "$MAC_CERT_B64" | base64 --decode > ossia-cert.p12 - - security create-keychain -p azure $KEY_CHAIN - security default-keychain -s $KEY_CHAIN - security unlock-keychain -p azure $KEY_CHAIN - security import ossia-cert.p12 -k $KEY_CHAIN -P "$MAC_CERT_PASSWORD" -T /usr/bin/codesign; - security set-key-partition-list -S apple-tool:,apple: -s -k azure $KEY_CHAIN - - rm -rf *.p12 - ) - - security unlock-keychain -p azure build.keychain - - for lib in `find build -name "ossia_python.cpython*.so" -print` - do - echo Signing ${lib} - codesign --force --timestamp --sign "ossia.io" ${lib} - done + - name: Build Wheel shell: bash run: | diff --git a/.github/workflows/ossia-qml.yml b/.github/workflows/ossia-qml.yml index 1041645f7a6..48b79ac7060 100644 --- a/.github/workflows/ossia-qml.yml +++ b/.github/workflows/ossia-qml.yml @@ -50,15 +50,15 @@ jobs: -DCMAKE_OSX_ARCHITECTURES="x86_64" cmake --build build cmake --build build --target install - - name: Code Signing - shell: bash - env: - MAC_CERT_B64: ${{ secrets.MAC_CERT_B64 }} - MAC_CERT_PASSWORD: ${{ secrets.MAC_CERT_PASSWORD }} - MAC_ALTOOL_PASSWORD: ${{ secrets.MAC_ALTOOL_PASSWORD }} - run: | - source ${GITHUB_WORKSPACE}/ci/codesign_functions.sh - release_macos_folder "${GITHUB_WORKSPACE}/install/Ossia" "$PWD/ossia-qml-osx.zip" "io.ossia.ossia-qml" + # - name: Code Signing + # shell: bash + # env: + # MAC_CERT_B64: ${{ secrets.MAC_CERT_B64 }} + # MAC_CERT_PASSWORD: ${{ secrets.MAC_CERT_PASSWORD }} + # MAC_ALTOOL_PASSWORD: ${{ secrets.MAC_ALTOOL_PASSWORD }} + # run: | + # source ${GITHUB_WORKSPACE}/ci/codesign_functions.sh + # release_macos_folder "${GITHUB_WORKSPACE}/install/Ossia" "$PWD/ossia-qml-osx.zip" "io.ossia.ossia-qml" - name: Archive Package uses: actions/upload-artifact@v2