autoconf-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[SCM] GNU Autoconf source repository branch, master, updated. v2.63-15-g


From: Eric Blake
Subject: [SCM] GNU Autoconf source repository branch, master, updated. v2.63-15-gb30850a
Date: Tue, 07 Oct 2008 03:05:17 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Autoconf source repository".

http://git.sv.gnu.org/gitweb/?p=autoconf.git;a=commitdiff;h=b30850a851f566f71f4a23c68a403326e1ca867b

The branch, master has been updated
       via  b30850a851f566f71f4a23c68a403326e1ca867b (commit)
       via  c1a0d34e262ce8179fe3386041e59c263ea3f52b (commit)
      from  5917ea5541576fd6a127c3db53716fd53b41db45 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit b30850a851f566f71f4a23c68a403326e1ca867b
Author: Eric Blake <address@hidden>
Date:   Tue Sep 23 06:57:15 2008 -0600

    Add m4_default_quoted.
    
    * lib/m4sugar/m4sugar.m4 (m4_default_quoted): New macro.
    (m4_for, m4_expand_once, m4_text_wrap, m4_text_box): Use it.
    * doc/autoconf.texi (Conditional constructs): Document it.
    * NEWS: Likewise.
    
    Signed-off-by: Eric Blake <address@hidden>

commit c1a0d34e262ce8179fe3386041e59c263ea3f52b
Author: Eric Blake <address@hidden>
Date:   Mon Oct 6 20:06:00 2008 -0600

    Fix build with case-insensitive make, again.
    
    * Makefile.am (pkgdata_DATA): Protect by MAKE_CASE_SENSITIVE.
    Reported via Keith Marshall, originally by newthinker in
    <http://thread.gmane.org/gmane.comp.gnu.mingw.user/27725>.
    
    Signed-off-by: Eric Blake <address@hidden>

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog              |   13 +++++++++++++
 Makefile.am            |    2 +-
 NEWS                   |    3 +++
 doc/autoconf.texi      |   23 ++++++++++++++++++++---
 lib/m4sugar/m4sugar.m4 |   33 +++++++++++++++++++++++++--------
 5 files changed, 62 insertions(+), 12 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 049fd32..f7833fa 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,16 @@
+2008-10-06  Eric Blake  <address@hidden>
+
+       Add m4_default_quoted.
+       * lib/m4sugar/m4sugar.m4 (m4_default_quoted): New macro.
+       (m4_for, m4_expand_once, m4_text_wrap, m4_text_box): Use it.
+       * doc/autoconf.texi (Conditional constructs): Document it.
+       * NEWS: Likewise.
+
+       Fix build with case-insensitive make, again.
+       * Makefile.am (pkgdata_DATA): Protect by MAKE_CASE_SENSITIVE.
+       Reported via Keith Marshall, originally by newthinker in
+       <http://thread.gmane.org/gmane.comp.gnu.mingw.user/27725>.
+
 2008-10-06  Bruno Haible  <address@hidden>
 
        Warn about /usr/ucb on Solaris.
diff --git a/Makefile.am b/Makefile.am
index bd4b114..4da4b29 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -34,10 +34,10 @@ EXTRA_DIST = ChangeLog.0 ChangeLog.1 ChangeLog.2 \
 ## INSTALL.  ##
 ## --------- ##
 
-pkgdata_DATA = $(srcdir)/INSTALL
 AM_MAKEINFOFLAGS = --no-headers --no-validate --no-split
 
 if MAKE_CASE_SENSITIVE
+pkgdata_DATA = $(srcdir)/INSTALL
 
 MAINTAINERCLEANFILES = $(srcdir)/INSTALL
 $(srcdir)/INSTALL: $(top_srcdir)/doc/install.texi
diff --git a/NEWS b/NEWS
index c34bedb..0156127 100644
--- a/NEWS
+++ b/NEWS
@@ -7,6 +7,9 @@ GNU Autoconf NEWS - User visible changes.
 
 ** Autotest testsuites accept an option --jobs[=N] for parallel testing.
 
+** The following m4sugar macros are new:
+   m4_default_quoted
+
 
 * Major changes in Autoconf 2.63 (2008-09-09) [stable]
   Released by Eric Blake, based on git versions 2.62.*.
diff --git a/doc/autoconf.texi b/doc/autoconf.texi
index 939eaea..f258666 100644
--- a/doc/autoconf.texi
+++ b/doc/autoconf.texi
@@ -10720,10 +10720,27 @@ m4_cond([m4_index([$1], [\])], [-1], [$2],
 @end defmac
 
 @defmac m4_default (@var{expr-1}, @var{expr-2})
address@hidden m4_default_quoted (@var{expr-1}, @var{expr-2})
 @msindex{default}
-If @var{expr-1} is not empty, use it.  Otherwise, expand to
address@hidden  Useful for providing a fixed default if the expression
-that results in @var{expr-1} would otherwise be empty.
address@hidden
+If @var{expr-1} is not empty, use it.  Otherwise, select @var{expr-2}.
address@hidden expands the result, while @code{m4_default_quoted}
+does not.  Useful for providing a fixed default if the expression that
+results in @var{expr-1} would otherwise be empty.
+
address@hidden
+m4_define([active], [ACTIVE])dnl
+m4_define([demo1], [m4_default([$1], [$2])])dnl
+m4_define([demo2], [m4_default_quoted([$1], [$2])])dnl
+demo1([active], [default])
address@hidden
+demo1([], [active])
address@hidden
+demo2([active], [default])
address@hidden
+demo2([], [active])
address@hidden
address@hidden example
 @end defmac
 
 @defmac m4_ifndef (@var{macro}, @var{if-not-defined}, @ovar{if-defined})
diff --git a/lib/m4sugar/m4sugar.m4 b/lib/m4sugar/m4sugar.m4
index 3607e45..04a41e3 100644
--- a/lib/m4sugar/m4sugar.m4
+++ b/lib/m4sugar/m4sugar.m4
@@ -510,7 +510,7 @@ m4_define([m4_define_default],
 
 # m4_default(EXP1, EXP2)
 # ----------------------
-# Returns EXP1 if non empty, otherwise EXP2.
+# Returns EXP1 if non empty, otherwise EXP2.  Expand the result.
 #
 # This macro is called on hot paths, so inline the contents of m4_ifval,
 # for one less round of expansion.
@@ -518,6 +518,23 @@ m4_define([m4_default],
 [m4_if([$1], [], [$2], [$1])])
 
 
+# m4_default_quoted(EXP1, EXP2)
+# -----------------------------
+# Returns EXP1 if non empty, otherwise EXP2.  Leave the result quoted.
+#
+# For comparison:
+#   m4_define([active], [ACTIVE])
+#   m4_default([active], [default]) => ACTIVE
+#   m4_default([], [active]) => ACTIVE
+#   m4_default_quoted([active], [default]) => active
+#   m4_default_quoted([], [active]) => active
+#
+# This macro is called on hot paths, so inline the contents of m4_ifval,
+# for one less round of expansion.
+m4_define([m4_default_quoted],
+[m4_if([$1], [], [[$2]], [[$1]])])
+
+
 # m4_defn(NAME)
 # -------------
 # Like the original, except guarantee a warning when using something which is
@@ -866,12 +883,12 @@ m4_define([m4_unquote], [$*])
 m4_define([m4_for],
 [m4_pushdef([$1], m4_eval([$2]))]dnl
 [m4_cond([m4_eval(([$3]) > ([$2]))], 1,
-          [m4_pushdef([_m4_step], m4_eval(m4_default([$4],
+          [m4_pushdef([_m4_step], m4_eval(m4_default_quoted([$4],
              1)))m4_assert(_m4_step > 0)_$0([$1], _m4_defn([$1]),
   m4_eval((([$3]) - ([$2])) / _m4_step * _m4_step + ([$2])),
   _m4_step, [$5])],
         [m4_eval(([$3]) < ([$2]))], 1,
-          [m4_pushdef([_m4_step], m4_eval(m4_default([$4],
+          [m4_pushdef([_m4_step], m4_eval(m4_default_quoted([$4],
              -1)))m4_assert(_m4_step < 0)_$0([$1], _m4_defn([$1]),
   m4_eval((([$2]) - ([$3])) / -(_m4_step) * _m4_step + ([$2])),
   _m4_step, [$5])],
@@ -1698,9 +1715,9 @@ m4_define([_m4_divert_grow], _m4_divert([GROW]))
 # If TEXT has never been expanded, expand it *here*.  Use WITNESS as
 # as a memory that TEXT has already been expanded.
 m4_define([m4_expand_once],
-[m4_provide_if(m4_ifval([$2], [[$2]], [[$1]]),
+[m4_provide_if(m4_default_quoted([$2], [$1]),
               [],
-              [m4_provide(m4_ifval([$2], [[$2]], [[$1]]))[]$1])])
+              [m4_provide(m4_default_quoted([$2], [$1]))[]$1])])
 
 
 # m4_provide(MACRO-NAME)
@@ -2160,8 +2177,8 @@ m4_define([m4_append_uniq_w],
 # with m4_do, to avoid time wasted on dnl during expansion (since this is
 # already a time-consuming macro).
 m4_define([m4_text_wrap],
-[_$0([$1], [$2], m4_if([$3], [], [[$2]], [[$3]]),
-     m4_if([$4], [], [79], [[$4]]))])
+[_$0([$1], [$2], m4_default_quoted([$3], [$2]),
+     m4_default_quoted([$4], [79]))])
 m4_define([_m4_text_wrap],
 m4_do(dnl set up local variables, to avoid repeated calculations
 [[m4_pushdef([m4_Indent], m4_qlen([$2]))]],
@@ -2203,7 +2220,7 @@ dnl finally, clean up the local variabls
 m4_define([m4_text_box],
 [m4_pushdef([m4_Border],
            m4_translit(m4_format([%*s], m4_qlen(m4_expand([$1])), []),
-                       [ ], m4_if([$2], [], [[-]], [[$2]])))dnl
+                       [ ], m4_default_quoted([$2], [-])))dnl
 @%:@@%:@ m4_Border @%:@@%:@
 @%:@@%:@ $1 @%:@@%:@
 @%:@@%:@ m4_Border @%:@@%:@_m4_popdef([m4_Border])dnl


hooks/post-receive
--
GNU Autoconf source repository




reply via email to

[Prev in Thread] Current Thread [Next in Thread]