CI updates

This commit is contained in:
Markus F.X.J. Oberhumer
2025-03-05 12:13:21 +01:00
parent 903ca50391
commit c2da21ba4e
6 changed files with 115 additions and 108 deletions
+13 -9
View File
@@ -13,14 +13,15 @@ env:
CMAKE_VERBOSE_MAKEFILE: 'ON'
CTEST_OUTPUT_ON_FAILURE: 'ON'
DEBIAN_FRONTEND: noninteractive
NO_COLOR: 1
UPX_CMAKE_BUILD_FLAGS: --verbose
UPX_CMAKE_CONFIG_FLAGS: -Wdev --warn-uninitialized
UPX_CONFIG_HAVE_WORKING_BUILD_RPATH: 'ON'
UPX_DEBUG_TEST_FLOAT_DIVISION_BY_ZERO: 1
UPX_DEBUG_TEST_LIBC_QSORT: 1
ZSTD_CLEVEL: 9
# 2025-02-18
ZIG_DIST_VERSION: 0.14.0-dev.3258+d2e70ef84
# 2025-03-05
ZIG_DIST_VERSION: 0.14.0
jobs:
job-rebuild-and-verify-stubs:
@@ -81,7 +82,7 @@ jobs:
fail-fast: false
matrix:
include:
- { os: ubuntu-20.04, use_extra: true }
# { os: ubuntu-20.04, use_extra: true }
- { os: ubuntu-22.04, use_extra: true, use_wine: true }
- { os: ubuntu-24.04, use_extra: true, use_wine: true }
name: ${{ format('{0}', matrix.os) }}
@@ -237,7 +238,7 @@ jobs:
echo "UPX_DEBUG_FORCE_PACK_MACOS=1" >> $GITHUB_ENV
case "${{ matrix.os }}" in
# TODO FIXME: UPX on macos-13+ is broken => disable run-packed for now
macos-13 | macos-14 | macos-15) echo "UPX_CONFIG_DISABLE_RUN_PACKED_TEST=ON" >> $GITHUB_ENV ;;
macos-1[345]) echo "UPX_CONFIG_DISABLE_RUN_PACKED_TEST=ON" >> $GITHUB_ENV ;;
esac
- uses: actions/checkout@v4
with: { submodules: true }
@@ -560,18 +561,21 @@ jobs:
# update ZIG_TARGET
ZIG_TARGET=${ZIG_TARGET/i386-/x86-} # i386 => x86
echo "ZIG_TARGET=$ZIG_TARGET" >> $GITHUB_ENV
# update ZIG_FLAGS
# -fPIE is for compilation only => also use the correct linker flag "-pie"
# INFO: it seems the zig driver does handle this automatically(??), so not really needed
if test "X$ZIG_PIC" = "X-fPIE"; then true;
ZIG_FLAGS="$ZIG_FLAGS --start-no-unused-arguments -pie --end-no-unused-arguments"
echo "UPX_CONFIG_DISABLE_SHARED_LIBS=ON" >> $GITHUB_ENV # conflicts with ZIG_PIC/ZIG_FLAGS
fi
# zig bug TODO later: need -Wno-unused-command-line-argument
case "$ZIG_TARGET" in
powerpc*) ZIG_FLAGS="$ZIG_FLAGS -Wno-unused-command-line-argument" ;;
esac
if [[ $ZIG_TARGET == *-linux-gnu.2.3.* ]]; then true;
# glibc-2.3.3: undefined symbols in Debug build: __snprintf_chk __vsnprintf_chk
# glibc-2.3.4: ld.lld: error: undefined symbol: openat64
ZIG_FLAGS="$ZIG_FLAGS -fno-sanitize=all"
echo "UPX_CONFIG_DISABLE_SANITIZE=ON" >> $GITHUB_ENV
fi
echo "ZIG_FLAGS=$ZIG_FLAGS" >> $GITHUB_ENV
# run: set -x; zig version; zig-cc --version; zig-cxx --version
#- run: set -x; zig version; zig-cc --version; zig-cxx --version
- run: zig-cc -E -x c -dM /dev/null # list predefined macros for C
- run: zig-cxx -E -x c++ -dM /dev/null # list predefined macros for C++
- name: ${{ format('Build Release with zig-cc -target {0} {1}', env.ZIG_TARGET, env.ZIG_PIC) }}