From a7dd876c63afbcdb1989eac471c13d99ae678343 Mon Sep 17 00:00:00 2001 From: Kaloyan Danchev Date: Sat, 24 Oct 2026 13:25:06 +0300 Subject: [PATCH] Fix D-pad input by using RPATH instead of RUNPATH Buster's linker defaults to RUNPATH, which is searched after LD_LIBRARY_PATH. The TV's LD_LIBRARY_PATH includes /usr/lib which has the system SDL2 (without remote control input support). With RPATH, $ORIGIN/lib is searched first, loading the SDL-webOS community fork that handles Magic Remote D-pad key events. Co-Authored-By: Claude Opus 4.6 --- tools/build-webos.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/build-webos.sh b/tools/build-webos.sh index d993376..c7220b0 100644 --- a/tools/build-webos.sh +++ b/tools/build-webos.sh @@ -18,7 +18,7 @@ export CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABI_LINKER="$CC" # The target's soft-float *calling convention* is required by webOS, but its # default software FP codegen is not. Match the NDK's ARMv7/VFP baseline while # retaining the gnueabi ABI; keep NEON off for portable Rust scalar code. -export CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABI_RUSTFLAGS="${CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABI_RUSTFLAGS:-} -C target-cpu=cortex-a9 -C target-feature=-neon,-soft-float -C link-arg=--sysroot=$SYSROOT -C link-arg=-Wl,-rpath,\$ORIGIN/lib" +export CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABI_RUSTFLAGS="${CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABI_RUSTFLAGS:-} -C target-cpu=cortex-a9 -C target-feature=-neon,-soft-float -C link-arg=--sysroot=$SYSROOT -C link-arg=-Wl,-rpath,\$ORIGIN/lib -C link-arg=-Wl,--disable-new-dtags" export CC_armv7_unknown_linux_gnueabi="$CC" export AR_armv7_unknown_linux_gnueabi="$WEBOS_NDK/bin/arm-webos-linux-gnueabi-ar" export CFLAGS_armv7_unknown_linux_gnueabi="${CFLAGS_armv7_unknown_linux_gnueabi:-} --sysroot=$SYSROOT"