[Pkg-alsa-devel] aoss not setting LD_PRELOAD correctly (with solution)

Aaron McDaid aaron at aaronmcdaid.com
Fri Jul 6 00:19:10 UTC 2007


Hi,
I've had to edit /usr/bin/aoss to get it to work correctly. In fact,
I'm surprised it works for anybody!

When I run
  aoss env | grep LD_PR
I get
  LD_PRELOAD=/usr/$LIB/libaoss.so
However, it should output something like this instead
  LD_PRELOAD=/usr/lib/libaoss.so


In order to get this correct LD_PRELOAD, I edited /usr/bin/aoss like so.
I simply removed the backslash from in front of $LIB and define LIB on
the previous line. I'm surprised that aoss works for anybody!

Aaron McDaid
Dublin, Ireland

--- aoss        2007-07-06 01:13:43.644281960 +0100
+++ /usr/bin/aoss       2007-07-06 01:00:22.000000000 +0100
@@ -7,8 +7,7 @@
 if [ -d /proc/asound ]; then
   prefix=/usr
   exec_prefix=${prefix}
-  LIB=lib
-  LD_PRELOAD=${exec_prefix}/$LIB/libaoss.so${LD_PRELOAD:+:$LD_PRELOAD}
exec "$@"
+  LD_PRELOAD=${exec_prefix}/\$LIB/libaoss.so${LD_PRELOAD:+:$LD_PRELOAD}
exec "$@"
 else
   exec "$@"
 fi



More information about the Pkg-alsa-devel mailing list