[Top][All Lists]

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

[REPOST] Using result of AC_PROG_SED as sed program in config.status

From: Albert Chin
Subject: [REPOST] Using result of AC_PROG_SED as sed program in config.status
Date: Thu, 3 Feb 2005 16:03:32 -0600
User-agent: Mutt/1.5.6i

Because some's can contain long lines (e.g. kdevelop from
KDE), using the normal 'sed' command can break substition or even
pass-thru when creating Makefile. It makes sense to use the sed
determined by AC_PROG_SED as the "best" sed to perform the

albert chin (address@hidden)

-- snip snip
2005-02-03  Albert Chin-A-Young  <address@hidden>
            Stepan Kasal  <address@hidden>

        * lib/autoconf/status.m4 (_AC_OUTPUT_CONFIG_STATUS,
        _AC_OUTPUT_FILES): Use the "best" sed as determined by
        AC_PROG_SED to perform substitutions to work around
        limitation on some systems by the default sed when
        the input file contains very long lines. Even if no
        substitutions are made on these lines, the default sed
        command might truncate them.

Index: lib/autoconf/status.m4
RCS file: /cvsroot/autoconf/autoconf/lib/autoconf/status.m4,v
retrieving revision 1.48
diff -u -3 -p -r1.48 status.m4
--- lib/autoconf/status.m4      21 Dec 2004 14:24:01 -0000      1.48
+++ lib/autoconf/status.m4      7 Jan 2005 23:09:59 -0000
@@ -918,9 +918,9 @@ dnl Here, there are 2 cmd per line, and 
       (echo [':t
   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b'] && cat "$tmp/subs.frag") 
       if test -z "$ac_sed_cmds"; then
-       ac_sed_cmds="sed -f '$tmp/subs-$ac_sed_frag.sed'"
+       ac_sed_cmds="$SED -f '$tmp/subs-$ac_sed_frag.sed'"
-       ac_sed_cmds="$ac_sed_cmds | sed -f '$tmp/subs-$ac_sed_frag.sed'"
+       ac_sed_cmds="$ac_sed_cmds | $SED -f '$tmp/subs-$ac_sed_frag.sed'"
       ac_sed_frag=`expr $ac_sed_frag + 1`
@@ -999,7 +999,7 @@ AC_PROVIDE_IFELSE([AC_PROG_INSTALL],
 dnl Neutralize VPATH when `$srcdir' = `.'.
-  sed "$ac_vpsub
+  \$SED "$ac_vpsub
 dnl Shell code in might set extrasub.
 dnl FIXME: do we really want to maintain this feature?
@@ -1273,8 +1273,9 @@ AC_PROVIDE_IFELSE([AC_CONFIG_SUBDIRS], [
 # Produce config.status.  Called by AC_OUTPUT.
 # Pay special attention not to have too long here docs: some old
 # shells die.  Unfortunately the limit is not known precisely...
 #! $SHELL
 # Generated by $as_me.
@@ -1285,6 +1286,7 @@ cat >$CONFIG_STATUS <<_ACEOF

reply via email to

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