From: Soeren Apel Date: Tue, 5 Mar 2024 19:37:47 +0000 (+0100) Subject: build.yml: Add debug/release to the PV matrix X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=bbfa83a773133b8cd4c585d5cf81ca42cf6ab785;p=sigrok-build.git build.yml: Add debug/release to the PV matrix --- diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 32a6dca..3c93ef3 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -25,8 +25,6 @@ env: SIGROK_FIRMWARE_FX2LAFW_REPO: "git://sigrok.org/sigrok-firmware-fx2lafw" # Git URL for the sigrok-dumps dependency SIGROK_DUMPS_REPO: "git://sigrok.org/sigrok-dumps" - # Build type for PulseView (Debug, Release, RelWithDebInfo, MinSizeRel) - BUILD_TYPE: "Release" # Misc commands WGET: "wget -c --quiet" GIT_CLONE: "git clone --depth=1" @@ -34,7 +32,7 @@ env: jobs: build_pulseview_mxe: - name: PulseView MXE build (${{ matrix.target.target }}) + name: PulseView MXE build (${{ matrix.target.target }}) (${{ matrix.build_type.type }}) runs-on: ubuntu-latest container: @@ -45,6 +43,9 @@ jobs: target: - { target: "i686", nsis_param: "" } - { target: "x86_64", nsis_param: "-DPE64=1" } + build_type: + - { type: "Release", name: "release" } + - { type: "Debug", name: "debug" } env: TARGET: ${{ matrix.target.target }} @@ -78,7 +79,7 @@ jobs: cd pulseview/build $CMAKE \ -DCMAKE_INSTALL_PREFIX:PATH=$INSTALL_DIR \ - -DCMAKE_BUILD_TYPE=$BUILD_TYPE \ + -DCMAKE_BUILD_TYPE=${{ matrix.build_type.type }} \ -DDISABLE_WERROR=FALSE \ -DENABLE_TESTS=FALSE \ .. @@ -99,12 +100,12 @@ jobs: - name: Rename artifact run: | cd pulseview/build/contrib - mv pulseview-*installer.exe pulseview-NIGHTLY-${{ matrix.target.target }}-static-$BUILD_TYPE-installer.exe + mv pulseview-*installer.exe pulseview-NIGHTLY-${{ matrix.target.target }}-static-${{ matrix.build_type.name }}-installer.exe - name: Upload artifact uses: actions/upload-artifact@v4 with: - name: artifact-pulseview-mxe + name: artifact-pulseview-${{ matrix.target.target }}-mxe path: pulseview/build/contrib/pulseview*installer.exe overwrite: true @@ -169,18 +170,18 @@ jobs: - name: Rename artifact run: | cd sigrok-cli/contrib - mv sigrok-cli-*installer.exe sigrok-cli-NIGHTLY-${{ matrix.target.target }}-static-$BUILD_TYPE-installer.exe + mv sigrok-cli-*installer.exe sigrok-cli-NIGHTLY-${{ matrix.target.target }}-static-debug-installer.exe - name: Upload artifact uses: actions/upload-artifact@v4 with: - name: artifact-sigrok-cli-mxe + name: artifact-sigrok-cli-${{ matrix.target.target }}-mxe path: sigrok-cli/contrib/sigrok-cli*installer.exe overwrite: true build_pulseview_appimage: - name: PulseView AppImage build (${{ matrix.target.target }}) + name: PulseView AppImage build (${{ matrix.target.target }}) (${{ matrix.build_type.type }}) runs-on: ubuntu-latest container: @@ -201,6 +202,9 @@ jobs: cxx: "g++" ld: "ld" ldflags: "" + build_type: + - { type: "Release", name: "release" } + - { type: "Debug", name: "debug" } env: TARGET: ${{ matrix.target.target }} @@ -249,7 +253,7 @@ jobs: cd pulseview/build PKG_CONFIG_PATH=$P cmake \ -DCMAKE_INSTALL_PREFIX:PATH="$APP_DIR"/usr \ - -DCMAKE_BUILD_TYPE=$BUILD_TYPE \ + -DCMAKE_BUILD_TYPE=${{ matrix.build_type.type }} \ -DDISABLE_WERROR=FALSE \ -DENABLE_TESTS=FALSE \ .. @@ -265,7 +269,7 @@ jobs: - name: Upload artifact uses: actions/upload-artifact@v4 with: - name: artifact-pulseview-appimage + name: artifact-pulseview-${{ matrix.target.target }}-appimage path: sigrok-build/ci/appimage/appimage-build/PulseView-*.AppImage overwrite: true @@ -357,10 +361,16 @@ jobs: build_pulseview_macos: - name: PulseView macOS build + name: PulseView macOS build (${{ matrix.build_type.type }}) ${{ matrix.build_type.type }} runs-on: macos-11 + strategy: + matrix: + build_type: + - { type: "Release", name: "release" } + - { type: "Debug", name: "debug" } + env: TARGET: "x86" # We use Homebrew Qt 5.15.x (current) @@ -398,7 +408,7 @@ jobs: uses: actions/checkout@v4 with: # TODO: Clone from sigrok.org - repository: abraxa/pulseview + repository: sigrokproject/pulseview path: pulseview - name: Build PulseView @@ -408,7 +418,7 @@ jobs: cd pulseview/build PKG_CONFIG_PATH=$P cmake \ -DCMAKE_INSTALL_PREFIX:PATH=$INSTALL_DIR \ - -DCMAKE_BUILD_TYPE=$BUILD_TYPE \ + -DCMAKE_BUILD_TYPE=${{ matrix.build_type.type }} \ -DDISABLE_WERROR=FALSE \ -DENABLE_TESTS=FALSE \ .. @@ -424,7 +434,7 @@ jobs: - name: Upload artifact uses: actions/upload-artifact@v4 with: - name: artifact-pulseview-macos + name: artifact-pulseview-${{ matrix.build_type.name }}-macos path: sigrok-build/ci/macos/PulseView*.dmg overwrite: true @@ -522,8 +532,10 @@ jobs: uses: softprops/action-gh-release@v1 with: files: | - artifact-sigrok-cli-mxe/sigrok-cli-* - artifact-pulseview-mxe/pulseview-* + artifact-sigrok-cli-i686-mxe/sigrok-cli-* + artifact-sigrok-cli-x86_64-mxe/sigrok-cli-* + artifact-pulseview-i686-mxe/pulseview-* + artifact-pulseview-x86_64-mxe/pulseview-* tag_name: continuous generate_release_notes: false draft: false