Skip to content

fix(linux-deploy): skip all glibc libraries when bundling - #375

Merged
fbraz3 merged 1 commit into
fbraz3:mainfrom
elmeriniemela:fix/deploy-skip-glibc-arch
Oct 17, 2026
Merged

fbraz3 merged 1 commit into
fbraz3:mainfrom
elmeriniemela:fix/deploy-skip-glibc-arch

Conversation

@elmeriniemela

@elmeriniemela elmeriniemela commented Oct 17, 2026 •

Copy link
Copy Markdown

On Arch Linux, ldd reports glibc as /usr/lib/libc.so.6. The copy_ldd_deps() skip list only matched multiarch (/usr/lib/*/) and /usr/lib64/ paths, so libc.so.6 and libm.so.6 were bundled into the runtime directory while the loader was not. With RPATH $ORIGIN the game then mixes the bundled libc with the host loader, which breaks startup after a host glibc update or on another machine.

The other glibc libraries (libmvec, libresolv, libutil, libanl, libnsl.so.1, libnss_*, libthread_db and a few more) were missing from the skip list entirely, so they were bundled on every distro when a dependency needed them, for example libmvec.so.1 via libx265.

Add /usr/lib/.so.* patterns for libc, libm, libpthread, librt and libdl, and */ patterns for the remaining glibc libraries, in the deploy, bundle and AppImage scripts for both Zero Hour and Generals.

Summary by CodeRabbit

  • Bug Fixes
    • Linux deployments, bundles, and AppImages now skip additional glibc runtime and support libraries when collecting dependencies, while continuing to include other dependencies.
  • Documentation
    • Added a worklog entry recording the updated library exclusions and validation against Arch, Debian, and Fedora paths.

On Arch Linux, ldd reports glibc as /usr/lib/libc.so.6. The
copy_ldd_deps() skip list only matched multiarch (/usr/lib/*/) and
/usr/lib64/ paths, so libc.so.6 and libm.so.6 were bundled into the
runtime directory while the loader was not. With RPATH $ORIGIN the
game then mixes the bundled libc with the host loader, which breaks
startup after a host glibc update or on another machine.

The other glibc libraries (libmvec, libresolv, libutil, libanl,
libnsl.so.1, libnss_*, libthread_db and a few more) were missing
from the skip list entirely, so they were bundled on every distro
when a dependency needed them, for example libmvec.so.1 via libx265.

Add /usr/lib/<lib>.so.* patterns for libc, libm, libpthread, librt
and libdl, and */<lib> patterns for the remaining glibc libraries,
in the deploy, bundle and AppImage scripts for both Zero Hour and
Generals.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Oct 17, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository: fbraz3/GeneralsX/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 411a8822-5fd7-4d0f-9e85-7431789327fd
📥 Commits

Reviewing files that changed from the base of the PR and between f6e8ddb and ce43bb2.

📒 Files selected for processing: 7
  • docs/WORKLOG/2026-10-DIARY.md
  • scripts/build/linux/build-linux-appimage-generals.sh
  • scripts/build/linux/build-linux-appimage-zh.sh
  • scripts/build/linux/bundle-linux-zh.sh
  • scripts/build/linux/bundle-linux.sh
  • scripts/build/linux/deploy-linux-zh.sh
  • scripts/build/linux/deploy-linux.sh

Included review availability: This review used your included allowance. Your plan provides up to 2 included reviews per hour; 1 remain after this review.

📝 Walkthrough

Six Linux deployment, bundling, and AppImage scripts add patterns that skip additional glibc runtime and support libraries during dependency copying. A worklog entry records the patterns and reports validation against Arch, Debian, and Fedora library paths.

Changes: Linux dependency exclusions

Layer / File(s) Summary
Add glibc dependency exclusions
scripts/build/linux/deploy-linux*.sh, scripts/build/linux/bundle-linux*.sh, scripts/build/linux/build-linux-appimage-*.sh, docs/WORKLOG/2026-10-DIARY.md
The six Linux packaging scripts add skip patterns for additional glibc runtime and support libraries. The worklog records the exclusions and reports that non-glibc libraries remain copied.

Priority: ➖ Normal

Estimated code review effort: 2 (Simple) | ~8 minutes

Change: Bug fix

Suggested reviewers: fbraz3

Merge Risk: ⚪ Minimal · up to ce43b

The Linux bundles will omit the targeted glibc libraries, avoiding mixed bundled and host glibc. The inspected patterns are consistent across the scripts, with no actionable merge risk identified.

Pre-merge checks: Passed 10
Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title follows Conventional Commits with the valid type "fix", the scope "linux-deploy", and a concise description that matches the glibc exclusion changes.
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Platform Isolation Passed The pull request changes only six Linux deployment/AppImage shell scripts and one worklog. The authoritative diff contains no changes under Generals/, GeneralsMD/, or Core/GameEngine/. The added…
Cross-Platform Determinism Passed PASS: The pull request changes only Linux shell bundling scripts and a worklog. It does not change simulation/game logic, math operations, divisions, or integer casts. The WWMath and NaN/Inf requireme…
Openal / Miniaudio Parity Passed PASS: The pull request changes only Linux bundling scripts and a worklog. The authoritative diff contains no OpenAL or MiniAudio audio modifications, so there is no audio change that requires parity r…
Conventional Commit Standards Passed The reviewed commit subject is fix(linux-deploy): skip all glibc libraries when bundling. It follows Conventional Commits syntax and contains no @ character. The pull request title matches the sub…
No Hardcoded Local Paths / Sensitive Info Passed PASS: The pull request adds only standard Linux library match patterns (/usr/lib/... and wildcard library names) and documentation describing those paths. The added $ORIGIN token is a standard ELF…
Ngmp Protocol Integrity Passed PASS: The pull request changes only seven Linux bundling/deployment shell scripts and one worklog entry. The diff adds glibc skip patterns inside copy_ldd_deps(); it does not modify GeneralsOnline/, N…
Full details: Platform Isolation

Explanation

The pull request changes only six Linux deployment/AppImage shell scripts and one worklog. The authoritative diff contains no changes under Generals/, GeneralsMD/, or Core/GameEngine/. The added code is Linux dependency path filtering in copy_ldd_deps(), not Win32, Cocoa, or raw POSIX API usage in game logic. Platform behavior remains isolated from the specified game-logic directories.

Full details: Cross-Platform Determinism

Explanation

PASS: The pull request changes only Linux shell bundling scripts and a worklog. It does not change simulation/game logic, math operations, divisions, or integer casts. The WWMath and NaN/Inf requirements are therefore not applicable to this diff.

Full details: Openal / Miniaudio Parity

Explanation

PASS: The pull request changes only Linux bundling scripts and a worklog. The authoritative diff contains no OpenAL or MiniAudio audio modifications, so there is no audio change that requires parity review.

Full details: Conventional Commit Standards

Explanation

The reviewed commit subject is fix(linux-deploy): skip all glibc libraries when bundling. It follows Conventional Commits syntax and contains no @ character. The pull request title matches the subject.

Full details: No Hardcoded Local Paths / Sensitive Info

Explanation

PASS: The pull request adds only standard Linux library match patterns (/usr/lib/... and wildcard library names) and documentation describing those paths. The added $ORIGIN token is a standard ELF runtime variable, not a private environment variable. The reviewed additions contain no personal home paths (/Users, /home), workspace paths, internal URLs, or sensitive data.

Full details: Ngmp Protocol Integrity

Explanation

PASS: The pull request changes only seven Linux bundling/deployment shell scripts and one worklog entry. The diff adds glibc skip patterns inside copy_ldd_deps(); it does not modify GeneralsOnline/, NextGenMP/, cmake/ngmp.cmake, NGMP-related C++ files, UI event handling, loading-screen ticking, transport code, WebSocket/REST protocol code, or platform networking APIs. The existing deployment logic still copies GameNetworkingSockets unchanged.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Six scripts scan the paths,
Glibc libraries skip the copy,
Bundles keep their course,
AppImages follow suit,
The worklog marks the change.

Comment @coderabbitai help to get the list of available commands.

@fbraz3
fbraz3 merged commit 0c67ff1 into fbraz3:main Oct 17, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants