From 88dba64752e5cf48098aebf8f3bf570309c29e77 Mon Sep 17 00:00:00 2001 From: Alexandre Date: Wed, 7 Oct 2026 13:37:45 +0200 Subject: [PATCH] Update build_linux.yaml --- .gitea/workflows/build_linux.yaml | 49 ++++++++++++++++++++++++++----- 1 file changed, 41 insertions(+), 8 deletions(-) diff --git a/.gitea/workflows/build_linux.yaml b/.gitea/workflows/build_linux.yaml index 01586da..00121e4 100644 --- a/.gitea/workflows/build_linux.yaml +++ b/.gitea/workflows/build_linux.yaml @@ -34,15 +34,29 @@ jobs: nix develop --command cmake --build build \ --parallel 2 - - name: Check binary + - name: Install ELF inspection tools run: | - nix run nixpkgs\#findutils -- build -type f -executable - nix run nixpkgs\#findutils -- build -type f -executable \ - -exec sh -c ' - file "$1" - readelf -l "$1" | grep interpreter || true - readelf -d "$1" | grep -E "RPATH|RUNPATH|NEEDED" || true - ' _ {} \; + nix profile install \ + nixpkgs#binutils \ + nixpkgs#file \ + nixpkgs#gnugrep + + - name: Check binaries + run: | + for bin in build/server/server build/engine/engine; do + echo "========== $bin ==========" + + file "$bin" + + echo "--- INTERPRETER ---" + readelf -l "$bin" | grep 'Requesting program interpreter' || true + + echo "--- DYNAMIC SECTION ---" + readelf -d "$bin" | grep -E 'RPATH|RUNPATH|NEEDED' || true + + echo "--- NIX STORE REFERENCES ---" + strings "$bin" | grep '/nix/store' || true + done - name: Upload build uses: actions/upload-artifact@v4 @@ -50,6 +64,25 @@ jobs: name: VulkanEngine-linux-x86_64 path: build/ + - name: Verify Nix independence + run: | + mkdir -p /tmp/vulkan-test + cp build/server/server /tmp/vulkan-test/ + cp build/engine/engine /tmp/vulkan-test/ + + echo "=== Nix references ===" + if strings /tmp/vulkan-test/server | grep -q '/nix/store'; then + echo "ERROR: server contains /nix/store reference" + exit 1 + fi + + if strings /tmp/vulkan-test/engine | grep -q '/nix/store'; then + echo "ERROR: engine contains /nix/store reference" + exit 1 + fi + + echo "OK: no /nix/store references" + - name: Notify routine if: always() run: |