fix(full+build): unblock glib/mesa/libinput; close fork-staleness gap
- build-redbear.sh: detect changes to the 4 forks the staleness loop missed (userutils pkgar; syscall/libredox/redox-scheme crate path-deps force a full userspace relink) — prevents stale-binary skew (bash -n validated). - glib: drop the stale '#undef AT_FDCWD' Redox workaround — relibc now provides faccessat()/AT_FDCWD, and glib's HAVE_FACCESSAT path needs AT_FDCWD. - mesa: remove the dropped '-Dosmesa=true' meson option (unknown option) and guard the osmesa.pc pkg-config edit. - libinput: unblocked by syncing the fresh relibc libc.a (with timerfd_*) into the stale prefix sysroot (prefix-sysroot staleness — see notes).
This commit is contained in:
@@ -623,6 +623,34 @@ if [ "$NO_CACHE" != "1" ]; then
|
||||
fi
|
||||
done
|
||||
|
||||
# Shared forks not covered by the pkgar loop above. userutils ships a pkgar
|
||||
# (login/getty/etc); syscall/libredox/redox-scheme are Cargo path-dep crates
|
||||
# with NO pkgar of their own but are linked into most of userspace, so
|
||||
# cookbook's per-recipe cache cannot detect a change in them. Detect a source
|
||||
# change and force a full userspace relink to prevent stale-binary skew.
|
||||
for src in userutils syscall libredox redox-scheme; do
|
||||
src_dir="$PROJECT_ROOT/local/sources/$src"
|
||||
fingerprint="$PROJECT_ROOT/repo/x86_64-unknown-redox/$src.source-fingerprint"
|
||||
[ -d "$src_dir/.git" ] || continue
|
||||
src_commit=$(git -C "$src_dir" rev-parse HEAD 2>/dev/null || echo "")
|
||||
last_commit=$(cat "$fingerprint" 2>/dev/null || echo "")
|
||||
src_dirty=0
|
||||
if ! git -C "$src_dir" diff --quiet HEAD 2>/dev/null \
|
||||
|| ! git -C "$src_dir" diff --cached --quiet HEAD 2>/dev/null \
|
||||
|| [ -n "$(git -C "$src_dir" ls-files --others --exclude-standard 2>/dev/null)" ]; then
|
||||
src_dirty=1
|
||||
fi
|
||||
# Only act when a prior fingerprint exists (skip the first build, which
|
||||
# cooks everything anyway).
|
||||
if [ -n "$last_commit" ] && { [ "$src_commit" != "$last_commit" ] || [ "$src_dirty" = "1" ]; }; then
|
||||
echo ">>> Stale shared fork $src detected; forcing full userspace relink (correctness)..."
|
||||
STALE_DETECTED=1
|
||||
USERSPACE_RUNTIME_STALE=1
|
||||
[ "$src" = "userutils" ] && rm -f "$PROJECT_ROOT/repo/x86_64-unknown-redox/userutils".*
|
||||
fi
|
||||
done
|
||||
|
||||
|
||||
if [ "$USERSPACE_RUNTIME_STALE" = "1" ]; then
|
||||
echo ">>> Cleaning stale build/sysroot dirs (userspace-linked runtime changed)..."
|
||||
find "$PROJECT_ROOT/recipes" "$PROJECT_ROOT/local/recipes" \
|
||||
@@ -867,7 +895,7 @@ for pkg in $PRECOOK_PKGS; do
|
||||
fi
|
||||
done
|
||||
|
||||
for src in relibc kernel base bootloader installer; do
|
||||
for src in relibc kernel base bootloader installer userutils syscall libredox redox-scheme; do
|
||||
src_dir="$PROJECT_ROOT/local/sources/$src"
|
||||
if [ -d "$src_dir/.git" ]; then
|
||||
git -C "$src_dir" rev-parse HEAD 2>/dev/null > \
|
||||
|
||||
Reference in New Issue
Block a user