]> git.tdb.fi Git - builder.git/commitdiff
Detect multiarch in bootstrap.sh as well
authorMikko Rasa <tdb@tdb.fi>
Mon, 19 Sep 2011 09:07:07 +0000 (09:07 +0000)
committerMikko Rasa <tdb@tdb.fi>
Mon, 19 Sep 2011 09:07:07 +0000 (09:07 +0000)
bootstrap.sh

index 26b8b31ba7c17f96557504e4f5a16b63d80a2a2e..0bf6c3d3739e558d97ab24d8a4568c8291359814 100755 (executable)
@@ -6,7 +6,13 @@ set -e
 REQUIRED="core datafile"
 CFLAGS="-Iinclude `pkg-config --cflags sigc++-2.0`"
 LIBS="`pkg-config --libs sigc++-2.0` -lpthread"
-if [ -e /usr/lib/libdl.so ]; then
+MACHINE="`uname -m`"
+if [ "$MACHINE" = "x86_64" ]; then
+       MULTIARCH="x86_64-linux-gnu"
+else
+       MULTIARCH="i386-linux-gnu"
+fi
+if [ -e /usr/lib/libdl.so -o -e /usr/lib/$MULTIARCH/libdl.so ]; then
        LIBS="$LIBS -ldl"
 fi
 if [ -z "$LIBPATH" -o "${LIBPATH%%/*}" ]; then