diff options
author | Brody Kenrick <user.fake@server.userfake> | 2013-12-12 06:48:55 (GMT) |
---|---|---|
committer | Brody Kenrick <user.fake@server.userfake> | 2013-12-12 06:48:55 (GMT) |
commit | 68c706da8c9ed5d7bc32d41d7cce86531eb2a673 (patch) | |
tree | a06535fcc684c41d5aa1c3d10dc72f6f70ecf3bb /scripts | |
parent | 509a466ddd903906d290e30e98e5b6b01359b2f4 (diff) |
Fix check_dependencies for Ubuntu 12.10 and ...
... and other platforms that report a different arch triplet than where
they store their libraries)
check-dependencies.sh doesn't find glib2 on Ubuntu 12.10 since glib is
installed in /usr/lib/i386-linux-gnu/glib-2.0/include/glibconfig.h while
gcc -dumpmachine reports the arch as i686-linux-gnu
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/check-dependencies.sh | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/scripts/check-dependencies.sh b/scripts/check-dependencies.sh index e587198..c431255 100755 --- a/scripts/check-dependencies.sh +++ b/scripts/check-dependencies.sh @@ -74,7 +74,19 @@ glib2_sysver() glib2archtriplet=`dpkg-architecture -qDEB_HOST_MULTIARCH 2>/dev/null` fi glib2path=$1/lib/$glib2archtriplet/glib-2.0/include/glibconfig.h - if [ ! -e $glib2path ]; then return; fi + if [ ! -e $glib2path ]; then + #No glib found + #glib can be installed in /usr/lib/i386-linux-gnu/glib-2.0/ on arch i686-linux-gnu (sometimes?) + if [ $glib2archtriplet = "i686-linux-gnu" ]; then + glib2archtriplet=i386-linux-gnu + glib2path=$1/lib/$glib2archtriplet/glib-2.0/include/glibconfig.h + if [ ! -e $glib2path ]; then + return; + fi + else + return; + fi + fi glib2major=`grep "define *GLIB_MAJOR_VERSION *[0-9.]*" $glib2path | awk '{print $3}'` glib2minor=`grep "define *GLIB_MINOR_VERSION *[0-9.]*" $glib2path | awk '{print $3}'` glib2micro=`grep "define *GLIB_MICRO_VERSION *[0-9.]*" $glib2path | awk '{print $3}'` |