[gparted] Stop using locate in autogen.sh (#702040)
- From: Curtis Gedak <gedakc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gparted] Stop using locate in autogen.sh (#702040)
- Date: Fri, 14 Jun 2013 16:52:26 +0000 (UTC)
commit f77d4e65a92a721d61a1212b3282a6cc87de8579
Author: Mike Fleetwood <mike fleetwood googlemail com>
Date: Fri Jun 14 12:35:40 2013 +0100
Stop using locate in autogen.sh (#702040)
If the gnome-doc-utils package isn't installed and you try to compile
GParted from git it will fail with this:
$ ./autogen.sh
/usr/bin/gnome-autogen.sh
Cannot find file: gnome-doc-utils.make
You need to install gnome-doc-utils
After installing the gnome-doc-utils package the same error will be
reported again unless you also update the locate database.
Instead query the full path to the gnome-doc-utils.make file from the
gnome-doc-utils' pkg-config metadata.
Closes Bug #702040 - very strange gnome-doc-utils check in gparted
autogen.sh | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/autogen.sh b/autogen.sh
index a64577d..aa80930 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -27,8 +27,9 @@ fi
# Check for GNOME-DOC-UTILS
GDUMAKE="gnome-doc-utils.make"
-GDUMAKEFULLPATH=`locate $GDUMAKE | grep -m 1 "gnome-doc-utils/"`
-if test "x${GDUMAKEFULLPATH}" = "x" ; then
+datadir=`pkg-config --variable=datadir gnome-doc-utils`
+GDUMAKEFULLPATH="$datadir/gnome-doc-utils/$GDUMAKE"
+if test "X$datadir" = 'X' || ! test -f "${GDUMAKEFULLPATH}" ; then
echo "Cannot find file: $GDUMAKE"
echo "You need to install gnome-doc-utils"
exit 1
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]