gfx/harfbuzz/src/check-libstdc++.sh

Fri, 16 Jan 2015 18:13:44 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Fri, 16 Jan 2015 18:13:44 +0100
branch
TOR_BUG_9701
changeset 14
925c144e1f1f
permissions
-rwxr-xr-x

Integrate suggestion from review to improve consistency with existing code.

     1 #!/bin/sh
     3 LC_ALL=C
     4 export LC_ALL
     6 test -z "$srcdir" && srcdir=.
     7 stat=0
    10 if which ldd 2>/dev/null >/dev/null; then
    11 	:
    12 else
    13 	echo "check-libstdc++.sh: 'ldd' not found; skipping test"
    14 	exit 77
    15 fi
    17 tested=false
    18 for suffix in so dylib; do
    19 	so=.libs/libharfbuzz.$suffix
    20 	if test -f "$so"; then
    21 		echo "Checking that we are not linking to libstdc++"
    22 		if ldd $so | grep 'libstdc[+][+]'; then
    23 			echo "Ouch, linked to libstdc++"
    24 			stat=1
    25 		fi
    26 		tested=true
    27 	fi
    28 done
    29 if ! $tested; then
    30 	echo "check-libstdc++.sh: libharfbuzz shared library not found; skipping test"
    31 	exit 77
    32 fi
    34 exit $stat

mercurial