* [PATCH v2] xfsprogs: Search path for utilities unified
@ 2015-07-16 16:13 Jan Tulak
2015-07-26 16:20 ` Christoph Hellwig
0 siblings, 1 reply; 2+ messages in thread
From: Jan Tulak @ 2015-07-16 16:13 UTC (permalink / raw)
To: xfs
UPDATE: Fixed commit message
-------------
Currently, when autoconf is checking for an utility, every utility has
its own pathes defined independently. Unify it in a single variable
used for (almost) all utilities.
Also, add /opt/local/bin to the path.
Signed-off-by: Jan Tulak <jtulak@redhat.com>
---
m4/package_utilies.m4 | 19 +++++++++++--------
1 file changed, 11 insertions(+), 8 deletions(-)
diff --git a/m4/package_utilies.m4 b/m4/package_utilies.m4
index 475ce0b..49f4dfb 100644
--- a/m4/package_utilies.m4
+++ b/m4/package_utilies.m4
@@ -1,3 +1,6 @@
+# Path to search an utility
+PATH=/bin:/usr/bin:/usr/local/bin:/usr/freeware/bin:/opt/local/bin
+
#
# Check for specified utility (env var) - if unset, fail.
#
@@ -40,22 +43,22 @@ AC_DEFUN([AC_PACKAGE_UTILITIES],
AC_PACKAGE_NEED_UTILITY($1, "$cc", cc, [C compiler])
if test -z "$MAKE"; then
- AC_PATH_PROG(MAKE, gmake,, /usr/bin:/usr/local/bin:/usr/freeware/bin)
+ AC_PATH_PROG(MAKE, gmake,, $PATH)
fi
if test -z "$MAKE"; then
- AC_PATH_PROG(MAKE, make,, /usr/bin)
+ AC_PATH_PROG(MAKE, make,, $PATH)
fi
make=$MAKE
AC_SUBST(make)
AC_PACKAGE_NEED_UTILITY($1, "$make", make, [GNU make])
if test -z "$TAR"; then
- AC_PATH_PROG(TAR, tar,, /usr/freeware/bin:/bin:/usr/local/bin:/usr/bin)
+ AC_PATH_PROG(TAR, tar,, $PATH)
fi
tar=$TAR
AC_SUBST(tar)
if test -z "$ZIP"; then
- AC_PATH_PROG(ZIP, gzip,, /bin:/usr/bin:/usr/local/bin:/usr/freeware/bin)
+ AC_PATH_PROG(ZIP, gzip,, $PATH)
fi
zip=$ZIP
@@ -97,21 +100,21 @@ AC_DEFUN([AC_PACKAGE_UTILITIES],
if test "$enable_gettext" = yes; then
if test -z "$MSGFMT"; then
- AC_PATH_PROG(MSGFMT, msgfmt,, /usr/bin:/usr/local/bin:/usr/freeware/bin)
+ AC_PATH_PROG(MSGFMT, msgfmt,, $PATH)
fi
msgfmt=$MSGFMT
AC_SUBST(msgfmt)
AC_PACKAGE_NEED_UTILITY($1, "$msgfmt", msgfmt, gettext)
if test -z "$MSGMERGE"; then
- AC_PATH_PROG(MSGMERGE, msgmerge,, /usr/bin:/usr/local/bin:/usr/freeware/bin)
+ AC_PATH_PROG(MSGMERGE, msgmerge,, $PATH)
fi
msgmerge=$MSGMERGE
AC_SUBST(msgmerge)
AC_PACKAGE_NEED_UTILITY($1, "$msgmerge", msgmerge, gettext)
if test -z "$XGETTEXT"; then
- AC_PATH_PROG(XGETTEXT, xgettext,, /usr/bin:/usr/local/bin:/usr/freeware/bin)
+ AC_PATH_PROG(XGETTEXT, xgettext,, $PATH)
fi
xgettext=$XGETTEXT
AC_SUBST(xgettext)
@@ -119,7 +122,7 @@ AC_DEFUN([AC_PACKAGE_UTILITIES],
fi
if test -z "$RPM"; then
- AC_PATH_PROG(RPM, rpm,, /bin:/usr/bin:/usr/freeware/bin)
+ AC_PATH_PROG(RPM, rpm,, $PATH)
fi
rpm=$RPM
AC_SUBST(rpm)
--
2.4.3
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v2] xfsprogs: Search path for utilities unified
2015-07-16 16:13 [PATCH v2] xfsprogs: Search path for utilities unified Jan Tulak
@ 2015-07-26 16:20 ` Christoph Hellwig
0 siblings, 0 replies; 2+ messages in thread
From: Christoph Hellwig @ 2015-07-26 16:20 UTC (permalink / raw)
To: Jan Tulak; +Cc: xfs
Looks fine,
Reviewed-by: Christoph Hellwig <hch@lst.de>
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-07-26 16:20 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-16 16:13 [PATCH v2] xfsprogs: Search path for utilities unified Jan Tulak
2015-07-26 16:20 ` Christoph Hellwig
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox