From 31d5e5598b02fdb4fbc3715f53776359e9a8a1f5 Mon Sep 17 00:00:00 2001 From: bol-van Date: Thu, 26 Feb 2026 10:19:24 +0300 Subject: [PATCH] pie experiment --- .github/workflows/build.yml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d49427f..2c1c957 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -104,7 +104,12 @@ jobs: fi MINSIZE="$OPTIMIZE $MINSIZE" - [ "$ARCH" == lexra ] && LEXRA=1 + if [ "$ARCH" = lexra ] ; then + STATIC="-static-pie" + LEXRA=1 + else + STATIC="-static" + end if [[ "$ARCH" == lexra ]] || [[ "$ARCH" == riscv64 ]] || [[ "$ARCH" == x86 ]] ; then # use classic lua wget -qO- https://www.lua.org/ftp/lua-${LUA_RELEASE}.tar.gz | tar -xz @@ -169,10 +174,9 @@ jobs: # zapret2 OPTIMIZE=$OPTIMIZE \ - CFLAGS="-DZAPRET_GH_VER=${{ github.ref_name }} -DZAPRET_GH_HASH=${{ github.sha }} -static-libgcc -static -I$DEPS_DIR/include $CFLAGS" \ + CFLAGS="-DZAPRET_GH_VER=${{ github.ref_name }} -DZAPRET_GH_HASH=${{ github.sha }} -static-libgcc $STATIC -I$DEPS_DIR/include $CFLAGS" \ LDFLAGS="-L$DEPS_DIR/lib $LDFLAGS" \ - ${LEXRA:+CFLAGS_PIC= LDFLAGS_PIE=} \ - make -C zapret2 LUA_JIT=$LJIT LUA_CFLAGS="$LCFLAGS" LUA_LIB="$LLIB" -j$(nproc) + make -C zapret2 ${LEXRA:+CFLAGS_PIC= LDFLAGS_PIE=} LUA_JIT=$LJIT LUA_CFLAGS="$LCFLAGS" LUA_LIB="$LLIB" -j$(nproc) tar -C zapret2/binaries/my -cJf zapret2-linux-$ARCH.tar.xz .