tDo three expansions so that ${prefix} gets expanded out. - vaccinewars - be a doctor and try to vaccinate the world
git clone git://src.adamsgaard.dk/vaccinewars
Log
Files
Refs
README
LICENSE
---
commit d487e2e1094442091f5b7f971de1501ccc83dd68
parent 2ed4b6e9b5e6256a43812764d888c9f52893b6f2
Author: Ben Webb 
Date:   Sun, 21 Jul 2013 20:38:42 +0000

Do three expansions so that ${prefix} gets expanded out.


Diffstat:
  M m4/dp_expand_dir.m4                 |       7 ++++++-

1 file changed, 6 insertions(+), 1 deletion(-)
---
diff --git a/m4/dp_expand_dir.m4 b/m4/dp_expand_dir.m4
t@@ -5,7 +5,7 @@ dnl example: DP_EXPAND_DIR(LOCALEDIR, "$datadir/locale")
 dnl eg, then: AC_DEFINE_UNQUOTED(LOCALEDIR, "$LOCALEDIR")
 dnl by Alexandre Oliva 
 dnl from http://www.cygnus.com/ml/automake/1998-Aug/0040.html
-dnl Modified by Ben Webb, 2002, to perform two expansions; this
+dnl Modified by Ben Webb, 2013, to perform three expansions; this
 dnl handles the case where DIR is something like ${datadir}
 dnl (first expansion -> ${prefix}/share,
 dnl  second expansion -> /usr/local/share)
t@@ -21,4 +21,9 @@ AC_DEFUN([DP_EXPAND_DIR], [
             test "x$exec_prefix" = xNONE && exec_prefix="${prefix}"
             eval echo \""[$]$1"\"
         )`
+        $1=`(
+            test "x$prefix" = xNONE && prefix="$ac_default_prefix"
+            test "x$exec_prefix" = xNONE && exec_prefix="${prefix}"
+            eval echo \""[$]$1"\"
+        )`
 ])