Hi,
On Fri, Jan 14, 2005 at 04:49:54PM +0100, Peter Simons wrote:
> I have applied the last patch you sent to the macro and
...
> dnl @author Stepan Kasal <[EMAIL PROTECTED]>, ...
Thanks. Perhaps we should give credit to Andreas, too.
There is still one problem with the macro--it changes prefix=NONE
to prefix="$ac_default_prefix", so subsequent macros don't have
the information whether prefix is defaulted or not.
The patch attached to this mail fixes this issue. It also sets
exec_prefix to current value of prefix, thus we need one less level of
indirection.
Do you like the patch?
Regards,
Stepan
Index: legacy/misc/ac_define_dir.m4
===================================================================
RCS file: /cvsroot/ac-archive/ac-archive/legacy/misc/ac_define_dir.m4,v
retrieving revision 1.6
diff -u -r1.6 ac_define_dir.m4
--- legacy/misc/ac_define_dir.m4 14 Jan 2005 15:28:54 -0000 1.6
+++ legacy/misc/ac_define_dir.m4 17 Jan 2005 16:02:57 -0000
@@ -15,13 +15,16 @@
dnl AC_DEFINE_DIR(PROG_PATH, bindir, [Location of installed binaries])
dnl
dnl @version $Id: ac_define_dir.m4,v 1.6 2005/01/14 15:28:54 simons Exp $
-dnl @author Stepan Kasal <[EMAIL PROTECTED]>, Guido Draheim <[EMAIL
PROTECTED]>, Alexandre Oliva
+dnl @author Stepan Kasal <[EMAIL PROTECTED]>, Andreas Schwab <[EMAIL
PROTECTED]>, Guido Draheim <[EMAIL PROTECTED]>, Alexandre Oliva
AC_DEFUN([AC_DEFINE_DIR], [
- test "x$prefix" = xNONE && prefix="$ac_default_prefix"
- test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
+ prefix_NONE=
+ exec_prefix_NONE=
+ test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix
+ test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix
eval ac_define_dir="\"[$]$2\""
- eval ac_define_dir="\"[$]ac_define_dir\""
AC_SUBST($1, "$ac_define_dir")
AC_DEFINE_UNQUOTED($1, "$ac_define_dir", [$3])
+ test "$prefix_NONE" && prefix=NONE
+ test "$exec_prefix_NONE" && exec_prefix=NONE
])
_______________________________________________
Autoconf mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/autoconf