From c9ca60a782d0ddd3e7d35093e7b7d359084c9dc3 Mon Sep 17 00:00:00 2001 From: Pierre Pronchery Date: Sun, 1 Jul 2018 05:08:12 +0200 Subject: [PATCH] Code cleanup --- doc/scripts/platform.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/doc/scripts/platform.sh b/doc/scripts/platform.sh index 2d29d46..f18aa34 100755 --- a/doc/scripts/platform.sh +++ b/doc/scripts/platform.sh @@ -27,6 +27,7 @@ #variables CONFIGSH="${0%/platform.sh}/config.sh" DESTDIR= +LDSOCONF="/etc/ld.so.conf" PREFIX="/usr/local" PROGNAME="platform.sh" SOEXT=".so" @@ -41,11 +42,11 @@ _platform_library() libdir=$(_platform_variable "LIBDIR") path="/lib:/usr/lib:$libdir" - if [ -f "$DESTDIR/etc/ld.so.conf" ]; then + if [ -f "$DESTDIR$LDSOCONF" ]; then while read line; do #XXX breaks on whitespace [ -n "${line%#*}" ] && path="$path:$line" - done < "$DESTDIR/etc/ld.so.conf" + done < "$DESTDIR$LDSOCONF" fi (IFS=:; for p in $path; do if [ -f "$DESTDIR$p/lib$library$SOEXT" ]; then