diff --git a/.github/workflows/cpp_package.yaml b/.github/workflows/cpp_package.yaml index 96938e8df70..1f017400bde 100644 --- a/.github/workflows/cpp_package.yaml +++ b/.github/workflows/cpp_package.yaml @@ -59,11 +59,13 @@ jobs: override: true - uses: Swatinem/rust-cache@v1 - uses: actions-rs/install@v0.1 - if: matrix.os == 'windows-latest' with: crate: cargo-about - - name: Prepare licenses - if: matrix.os == 'windows-latest' + - name: Prepare licenses (with Qt) + if: matrix.os == 'windows-latest' || matrix.os == 'macOS-11' + run: bash -x ./scripts/prepare_binary_package.sh . --with-qt + - name: Prepare licenses (without Qt) + if: matrix.os != 'windows-latest' && matrix.os != 'macOS-11' run: bash -x ./scripts/prepare_binary_package.sh . - uses: ilammy/msvc-dev-cmd@v1 - name: Select MSVC (windows) diff --git a/.github/workflows/sixtyfps_tool_binary.yaml b/.github/workflows/sixtyfps_tool_binary.yaml index 3aeb5b717b3..f245703cc44 100644 --- a/.github/workflows/sixtyfps_tool_binary.yaml +++ b/.github/workflows/sixtyfps_tool_binary.yaml @@ -66,7 +66,7 @@ jobs: cp ..\..\..\Qt\6.2.1\msvc2019_64\plugins\imageformats\qsvg.dll ./plugins/imageformats cd .. cd .. - bash -x ./scripts/prepare_binary_package.sh pkg\${{ github.event.inputs.program || inputs.program }} + bash -x ./scripts/prepare_binary_package.sh pkg\${{ github.event.inputs.program || inputs.program }} --with-qt - name: Upload artifact uses: actions/upload-artifact@v2 @@ -171,7 +171,7 @@ jobs: cp -a ~/work/sixtyfps/Qt/6.2.1/macos/plugins/platforms/libqcocoa.dylib ./plugins/platforms cp -a ~/work/sixtyfps/Qt/6.2.1/macos/plugins/imageformats/libqsvg.dylib ./plugins/imageformats cd .. - ./scripts/prepare_binary_package.sh ${{ github.event.inputs.program || inputs.program }} + ./scripts/prepare_binary_package.sh ${{ github.event.inputs.program || inputs.program }} --with-qt - name: Tar artifacts to preserve permissions run: tar czvf ${{ github.event.inputs.program || inputs.program }}-macos.tar.gz ${{ github.event.inputs.program || inputs.program }} - name: Upload artifact diff --git a/scripts/prepare_binary_package.sh b/scripts/prepare_binary_package.sh index 2dec8963d9d..ab677d0bf75 100755 --- a/scripts/prepare_binary_package.sh +++ b/scripts/prepare_binary_package.sh @@ -9,14 +9,18 @@ # Please contact info@sixtyfps.io for more information. # LICENSE END -if [ $# != 1 ]; then - echo "usage: $0 path/to/target/binary_package" +if [ $# -lt 1 ]; then + echo "usage: $0 path/to/target/binary_package --with-qt" echo echo "This prepares the specified binary_package folder for distribution" echo "by adding the legal copyright and license notices." echo echo "All files will be copied/created under the licenses folder" echo "along with an index.html" + echo + echo "If the --with-qt option is specified, it is assumed that Qt is bundled" + echo "with the binary package and license attribution is also copied into the" + echo "target path" exit 1 fi @@ -105,4 +109,6 @@ EOT cargo about generate about.hbs -o $target_path/index.html -cp sixtyfps_runtime/rendering_backends/qt/LICENSE.QT sixtyfps_runtime/rendering_backends/qt/QtThirdPartySoftware_Listing.txt $target_path/ +if [ "$2x" == "--with-qtx" ]; then + cp sixtyfps_runtime/rendering_backends/qt/LICENSE.QT sixtyfps_runtime/rendering_backends/qt/QtThirdPartySoftware_Listing.txt $target_path/ +fi