mirror of
https://github.com/upx/upx
synced 2025-09-28 19:06:07 +08:00
CI updates
This commit is contained in:
parent
e85e8bec5d
commit
404fb48668
24
.github/workflows/ci.yml
vendored
24
.github/workflows/ci.yml
vendored
|
@ -22,8 +22,8 @@ env:
|
||||||
UPX_DEBUG_TEST_FLOAT_DIVISION_BY_ZERO: 1
|
UPX_DEBUG_TEST_FLOAT_DIVISION_BY_ZERO: 1
|
||||||
UPX_DEBUG_TEST_LIBC_QSORT: 1
|
UPX_DEBUG_TEST_LIBC_QSORT: 1
|
||||||
ZSTD_CLEVEL: 17
|
ZSTD_CLEVEL: 17
|
||||||
# 2025-05-21
|
# 2025-08-19
|
||||||
ZIG_DIST_VERSION: 0.14.1
|
ZIG_DIST_VERSION: 0.15.1
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
job-rebuild-and-verify-stubs:
|
job-rebuild-and-verify-stubs:
|
||||||
|
@ -102,7 +102,7 @@ jobs:
|
||||||
- run: (sudo dmidecode | sed -n -e '/System Information/,/^$/p') || true
|
- run: (sudo dmidecode | sed -n -e '/System Information/,/^$/p') || true
|
||||||
- run: sudo dmidecode -q || true
|
- run: sudo dmidecode -q || true
|
||||||
- run: sudo dmidecode || true
|
- run: sudo dmidecode || true
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v5
|
||||||
with: { submodules: true }
|
with: { submodules: true }
|
||||||
- run: make build/extra/gcc/all
|
- run: make build/extra/gcc/all
|
||||||
- run: make build/extra/clang/all
|
- run: make build/extra/clang/all
|
||||||
|
@ -181,7 +181,7 @@ jobs:
|
||||||
sudo apt-get install -y wine wine32:i386 wine64
|
sudo apt-get install -y wine wine32:i386 wine64
|
||||||
ls -l /usr/bin/wine*
|
ls -l /usr/bin/wine*
|
||||||
mkdir -p -v ~/.wine && wineboot --init
|
mkdir -p -v ~/.wine && wineboot --init
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v5
|
||||||
with: { submodules: true }
|
with: { submodules: true }
|
||||||
- name: Check out test suite
|
- name: Check out test suite
|
||||||
run: git clone --depth=1 https://github.com/upx/upx-testsuite ../deps/upx-testsuite
|
run: git clone --depth=1 https://github.com/upx/upx-testsuite ../deps/upx-testsuite
|
||||||
|
@ -322,7 +322,7 @@ jobs:
|
||||||
# TODO FIXME: UPX on macos-13+ is broken => disable run-packed for now
|
# TODO FIXME: UPX on macos-13+ is broken => disable run-packed for now
|
||||||
macos-1[345]) echo "UPX_CONFIG_DISABLE_RUN_PACKED_TEST=ON" >> $GITHUB_ENV ;;
|
macos-1[345]) echo "UPX_CONFIG_DISABLE_RUN_PACKED_TEST=ON" >> $GITHUB_ENV ;;
|
||||||
esac
|
esac
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v5
|
||||||
with: { submodules: true }
|
with: { submodules: true }
|
||||||
- name: Check out test suite
|
- name: Check out test suite
|
||||||
if: ${{ matrix.testsuite }}
|
if: ${{ matrix.testsuite }}
|
||||||
|
@ -423,7 +423,7 @@ jobs:
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
- run: git config --global core.autocrlf false
|
- run: git config --global core.autocrlf false
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v5
|
||||||
with: { submodules: true }
|
with: { submodules: true }
|
||||||
- name: Check out test suite
|
- name: Check out test suite
|
||||||
run: git clone --depth=1 https://github.com/upx/upx-testsuite ../deps/upx-testsuite
|
run: git clone --depth=1 https://github.com/upx/upx-testsuite ../deps/upx-testsuite
|
||||||
|
@ -502,7 +502,7 @@ jobs:
|
||||||
B: release
|
B: release
|
||||||
steps:
|
steps:
|
||||||
- run: git config --global core.autocrlf false
|
- run: git config --global core.autocrlf false
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v5
|
||||||
with: { submodules: true }
|
with: { submodules: true }
|
||||||
- name: Prepare sources and Check out test suite
|
- name: Prepare sources and Check out test suite
|
||||||
run: |
|
run: |
|
||||||
|
@ -635,7 +635,7 @@ jobs:
|
||||||
git config --global --add safe.directory '*' # needed when running in a container
|
git config --global --add safe.directory '*' # needed when running in a container
|
||||||
mkdir -p ~/.parallel && : > ~/.parallel/$(echo 6305-4721 | tr 0-7 leticlwi)
|
mkdir -p ~/.parallel && : > ~/.parallel/$(echo 6305-4721 | tr 0-7 leticlwi)
|
||||||
- run: (sudo dmidecode | sed -n -e '/System Information/,/^$/p') || true
|
- run: (sudo dmidecode | sed -n -e '/System Information/,/^$/p') || true
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v5
|
||||||
with: { submodules: true }
|
with: { submodules: true }
|
||||||
- name: ${{ format('Install Zig {0}', env.ZIG_DIST_VERSION) }}
|
- name: ${{ format('Install Zig {0}', env.ZIG_DIST_VERSION) }}
|
||||||
run: |
|
run: |
|
||||||
|
@ -655,7 +655,8 @@ jobs:
|
||||||
ZIG_DIST_NAME=zig-linux-x86_64-${ZIG_DIST_VERSION}
|
ZIG_DIST_NAME=zig-linux-x86_64-${ZIG_DIST_VERSION}
|
||||||
ZIG_DIST_NAME=zig-x86_64-linux-${ZIG_DIST_VERSION}
|
ZIG_DIST_NAME=zig-x86_64-linux-${ZIG_DIST_VERSION}
|
||||||
#curl -sS -L -O https://ziglang.org/builds/${ZIG_DIST_NAME}.tar.xz
|
#curl -sS -L -O https://ziglang.org/builds/${ZIG_DIST_NAME}.tar.xz
|
||||||
curl -sS -L -O https://ziglang.org/download/0.14.1/${ZIG_DIST_NAME}.tar.xz
|
#curl -sS -L -O https://ziglang.org/download/0.14.1/${ZIG_DIST_NAME}.tar.xz
|
||||||
|
curl -sS -L -O https://ziglang.org/download/0.15.1/${ZIG_DIST_NAME}.tar.xz
|
||||||
ls -l ${ZIG_DIST_NAME}.tar.xz
|
ls -l ${ZIG_DIST_NAME}.tar.xz
|
||||||
file ${ZIG_DIST_NAME}.tar.xz || true
|
file ${ZIG_DIST_NAME}.tar.xz || true
|
||||||
tar -xoJf ${ZIG_DIST_NAME}.tar.xz
|
tar -xoJf ${ZIG_DIST_NAME}.tar.xz
|
||||||
|
@ -665,7 +666,7 @@ jobs:
|
||||||
echo -n 'zig version: '; zig version
|
echo -n 'zig version: '; zig version
|
||||||
# patch zig
|
# patch zig
|
||||||
ls -la "$HOME" "$GITHUB_WORKSPACE" || true
|
ls -la "$HOME" "$GITHUB_WORKSPACE" || true
|
||||||
#(cd ${ZIG_DIST_NAME} && patch --verbose -p1 -i "$GITHUB_WORKSPACE"/misc/patches/zig/0001-x.patch)
|
(cd ${ZIG_DIST_NAME} && patch --verbose -p1 -i "$GITHUB_WORKSPACE"/misc/patches/zig/0001-x.patch)
|
||||||
# create wrapper scripts (needed for CMake)
|
# create wrapper scripts (needed for CMake)
|
||||||
log=
|
log=
|
||||||
log='set -x\n'
|
log='set -x\n'
|
||||||
|
@ -762,7 +763,8 @@ jobs:
|
||||||
echo "===== parallel jobs: $jobs"
|
echo "===== parallel jobs: $jobs"
|
||||||
parallel -kv --lb 'cd build/zig/{} && bash ../../../../misc/testsuite/mimic_ctest.sh' ::: $jobs
|
parallel -kv --lb 'cd build/zig/{} && bash ../../../../misc/testsuite/mimic_ctest.sh' ::: $jobs
|
||||||
- name: Mimic ctest tests with Valgrind
|
- name: Mimic ctest tests with Valgrind
|
||||||
if: ${{ matrix.zig_target == 'x86_64-linux-musl' || contains(matrix.zig_target, 'x86_64-linux-gnu.2') }}
|
#if: ${{ matrix.zig_target == 'x86_64-linux-musl' || contains(matrix.zig_target, 'x86_64-linux-gnu.2') }}
|
||||||
|
if: false
|
||||||
run: |
|
run: |
|
||||||
export UPX_CONFIG_DISABLE_EXHAUSTIVE_TESTS=ON # valgrind is SLOW
|
export UPX_CONFIG_DISABLE_EXHAUSTIVE_TESTS=ON # valgrind is SLOW
|
||||||
apk add coreutils valgrind
|
apk add coreutils valgrind
|
||||||
|
|
|
@ -40,7 +40,7 @@ elif [[ -n $CMAKE_CROSSCOMPILING_EMULATOR ]]; then
|
||||||
true
|
true
|
||||||
else
|
else
|
||||||
upx_exe_runner=emu_gdb
|
upx_exe_runner=emu_gdb
|
||||||
: ${upx_run_packed_test_count:=100}
|
: ${upx_run_packed_test_count:=20}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
source "$argv0dir/mimic_ctest.sh"
|
source "$argv0dir/mimic_ctest.sh"
|
||||||
|
|
|
@ -1418,6 +1418,7 @@ void PackMachBase<T>::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e
|
||||||
unsigned const sz_threado = threado_size();
|
unsigned const sz_threado = threado_size();
|
||||||
MemBuffer space(sz_threado); memset(space, 0, sz_threado);
|
MemBuffer space(sz_threado); memset(space, 0, sz_threado);
|
||||||
fo->write(space, sz_threado);
|
fo->write(space, sz_threado);
|
||||||
|
UNUSED(cmdsize);
|
||||||
}
|
}
|
||||||
else if (my_filetype == Mach_header::MH_DYLIB) {
|
else if (my_filetype == Mach_header::MH_DYLIB) {
|
||||||
Mach_command const *ptr = (Mach_command const *)rawmseg;
|
Mach_command const *ptr = (Mach_command const *)rawmseg;
|
||||||
|
@ -1449,6 +1450,7 @@ void PackMachBase<T>::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e
|
||||||
}
|
}
|
||||||
memset(&linkitem, 0, sizeof(linkitem));
|
memset(&linkitem, 0, sizeof(linkitem));
|
||||||
fo->write(&linkitem, sizeof(linkitem));
|
fo->write(&linkitem, sizeof(linkitem));
|
||||||
|
UNUSED(cmdsize);
|
||||||
}
|
}
|
||||||
sz_mach_headers = fo->getBytesWritten();
|
sz_mach_headers = fo->getBytesWritten();
|
||||||
gap = secTEXT.offset - sz_mach_headers;
|
gap = secTEXT.offset - sz_mach_headers;
|
||||||
|
|
|
@ -56,7 +56,7 @@
|
||||||
#include "p_wince_arm.h"
|
#include "p_wince_arm.h"
|
||||||
|
|
||||||
/*************************************************************************
|
/*************************************************************************
|
||||||
//
|
// dispatch to a concrete subclass of class PackerBase; see work.cpp
|
||||||
**************************************************************************/
|
**************************************************************************/
|
||||||
|
|
||||||
PackMaster::PackMaster(InputFile *f, Options *o) noexcept : fi(f) {
|
PackMaster::PackMaster(InputFile *f, Options *o) noexcept : fi(f) {
|
||||||
|
|
|
@ -550,6 +550,7 @@ amd64-win64.pe.h : tc_objdump_disasm_options = -M intel-mnemonic
|
||||||
|
|
||||||
tc.amd64-win64.pe.gcc = amd64-linux-gcc-4.1.1 -m64 -nostdinc -DWINDOWS_BACK=1 -MMD -MT $@
|
tc.amd64-win64.pe.gcc = amd64-linux-gcc-4.1.1 -m64 -nostdinc -DWINDOWS_BACK=1 -MMD -MT $@
|
||||||
tc.amd64-win64.pe.gcc += -fno-exceptions -fno-asynchronous-unwind-tables
|
tc.amd64-win64.pe.gcc += -fno-exceptions -fno-asynchronous-unwind-tables
|
||||||
|
tc.amd64-win64.pe.gcc += -mno-red-zone
|
||||||
tc.amd64-win64.pe.gcc += -Wall -W -Wcast-align -Wcast-qual -Wstrict-prototypes -Wwrite-strings -Werror
|
tc.amd64-win64.pe.gcc += -Wall -W -Wcast-align -Wcast-qual -Wstrict-prototypes -Wwrite-strings -Werror
|
||||||
tc.amd64-win64.pe.objdump = multiarch-objdump-2.23.90
|
tc.amd64-win64.pe.objdump = multiarch-objdump-2.23.90
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user