From: Takashi Iwai Date: Thu, 27 Oct 2005 18:34:18 +0000 (+0000) Subject: Optimize aoss wrapper X-Git-Tag: v1.0.10rc3~1 X-Git-Url: https://git.alsa-project.org/?a=commitdiff_plain;h=b6980429b95eed061fa6ad0e6bd6dbae4f303a26;p=alsa-oss.git Optimize aoss wrapper - Don't set LD_PRELOAD if no ALSA driver exists. - Inheret the previous LD_PRELOAD setting. --- diff --git a/alsa/aoss.in b/alsa/aoss.in index ff707c1..c551431 100644 --- a/alsa/aoss.in +++ b/alsa/aoss.in @@ -4,6 +4,11 @@ # Usage: # aoss -prefix=@prefix@ -exec_prefix=@exec_prefix@ -LD_PRELOAD=${exec_prefix}/\$LIB/libaoss.so exec "$@" +if [ -d /proc/asound ]; then + prefix=@prefix@ + exec_prefix=@exec_prefix@ + LD_PRELOAD=${exec_prefix}/\$LIB/libaoss.so${LD_PRELOAD:+:$LD_PRELOAD} exec "$@" +else + exec "$@" +fi +exit 1