]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Upgrade to automake-1.5.
authorBruno Haible <bruno@clisp.org>
Wed, 24 Oct 2001 09:13:30 +0000 (09:13 +0000)
committerBruno Haible <bruno@clisp.org>
Wed, 24 Oct 2001 09:13:30 +0000 (09:13 +0000)
14 files changed:
ChangeLog
Makefile.am
aclocal.sh [deleted file]
configure.in
lib/ChangeLog
lib/Makefile.am
misc/ChangeLog
misc/automake.diff [deleted file]
missing
src/ChangeLog
src/Makefile.am
tests/ChangeLog
tests/Makefile.am
ylwrap [moved from src/ylwrap with 57% similarity]

index 450111deebc22440571d44324e7443b056d4100f..d207a8f6e8195b6c6134e16baf490e73df1fd10f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+2001-09-25  Bruno Haible  <haible@clisp.cons.org>
+
+       Upgrade to automake-1.5.
+       * aclocal.sh: Remove file.
+       * Makefile.am (AUTOMAKE_OPTIONS): Add 'no-dependencies'.
+       (EXTRA_DIST): Remove aclocal.sh.
+       * configure.in: Add some postprocessing to lib/Makefile, src/Makefile,
+       tests/Makefile.
+       * missing: Upgrade to automake-1.5.
+       * ylwrap: New file, from automake-1.5.
+
 2001-09-23  Bruno Haible  <haible@clisp.cons.org>
 
        * configure.in: Call gt_SIGINFO.
index f42c3e27fc068ed42e52c005db32956a704bd7be..bcd747bfab82a90ac0c1d0d12ff03b7ae051c332 100644 (file)
@@ -17,8 +17,7 @@
 
 ## Process this file with automake to produce Makefile.in.
 
-AUTOMAKE_OPTIONS = 1.4 gnu
-ACLOCAL = ./aclocal.sh @ACLOCAL@
+AUTOMAKE_OPTIONS = 1.5 gnu no-dependencies
 ACLOCAL_AMFLAGS = -I m4
 
 gettextsrcdir = $(datadir)/gettext
@@ -26,7 +25,7 @@ gettextsrc_DATA = ABOUT-NLS
 
 SUBDIRS = doc intl intl-java lib src po man m4 misc tests
 
-EXTRA_DIST = BUGS DISCLAIM README.gemtext aclocal.sh \
+EXTRA_DIST = BUGS DISCLAIM README.gemtext \
              djgpp/Makefile.maint djgpp/README.in djgpp/README \
              djgpp/config.bat djgpp/config.in djgpp/config.sed \
              djgpp/config.site djgpp/edtests.bat djgpp/fnchange.in \
diff --git a/aclocal.sh b/aclocal.sh
deleted file mode 100755 (executable)
index 03585c8..0000000
+++ /dev/null
@@ -1,100 +0,0 @@
-#! /bin/sh
-
-# This script is a work-alike of `aclocal' contained in the GNU automake
-# package. It is needed because our aclocal.m4 must be generated from the
-# non-gettext .m4 files in /usr/share/aclocal and from the gettext specific
-# .m4 files in the local m4 directory.
-# With   "aclocal --acdir=m4"
-# we get an error: macro `AM_INIT_AUTOMAKE' not found in library
-# With   "aclocal -I m4"
-# we get an error: duplicated macro `AM_GNU_GETTEXT'
-# The solution is to put all the .m4 files into a temporary directory.
-
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
-# 02111-1307, USA.
-
-set -e
-
-if test $# = 0; then
-  echo "Usage: $0 aclocal-program [aclocal-options]" 1>&2
-  exit 1
-fi
-
-# The command line is of the form
-#   /somepath/aclocal ...
-# or
-#   /somepath/missing aclocal ...
-# or
-#   /bin/sh /somepath/missing aclocal ...
-# or
-#   /bin/sh /somepath/missing aclocal --run ...
-# Extract the first part.
-ACLOCAL="$1"
-shift
-ACLOCAL2=
-ACLOCAL3=
-case "$ACLOCAL" in
-  *sh)
-    ACLOCAL="$1"
-    shift
-    ;;
-esac
-case "$ACLOCAL" in
-  *missing)
-    ACLOCAL2="$1"
-    shift
-    case "$1" in
-      --run)
-        ACLOCAL3="$1"
-        shift
-        ;;
-    esac
-    ;;
-esac
-
-# Prepare temporary directory.
-mkdir aclocal.tmp
-trap "rm -rf aclocal.tmp; exit 1" 1 2 15
-
-# First, copy the standard m4 files.
-for f in `"$ACLOCAL" $ACLOCAL2 $ACLOCAL3 --print-ac-dir`/*.m4; do
-  cp $f aclocal.tmp
-done
-
-# Then, copy the contents of any -I directories, overriding previously
-# copied files of the same name.
-options=""
-last_was_I=no
-for arg
-do
-  if test $last_was_I = yes; then
-    for f in "$arg"/*.m4; do
-      cp $f aclocal.tmp
-    done
-    last_was_I=no
-  else
-    case "$arg" in
-      -I) last_was_I=yes;;
-      *)  last_was_I=no options="$options $arg";;
-    esac
-  fi
-done
-
-# Now call `aclocal' for real.
-"$ACLOCAL" $ACLOCAL2 $ACLOCAL3 --acdir=aclocal.tmp $options
-
-# Clean up temporary directory.
-rm -rf aclocal.tmp
-
index 124a28a17e97803bd69357c538c6438b345dff8a..0fd11eeea314e6b690c173624b665c227e69db3a 100644 (file)
@@ -127,4 +127,12 @@ AC_OUTPUT([Makefile \
            doc/Makefile man/Makefile man/x-to-1 \
            tests/Makefile \
            m4/Makefile \
-           misc/Makefile misc/gettextize])
+           misc/Makefile misc/gettextize], [
+  dnl Fix unesthetic build commands generated by automake.
+changequote(,)dnl
+  for m in lib/Makefile src/Makefile tests/Makefile; do
+    sed -e "s,\`test -f \\\$< || echo '\\\$(srcdir)/'\`\\\$<,\\\$<," < $m > $m.tmp
+    mv $m.tmp $m
+  done
+changequote([, ])dnl
+])
index 0b86420b270c9fb95d9b171865061aa143328d97..ce99523aff61e675e158af9766f9ffd5cd9f77d4 100644 (file)
@@ -1,3 +1,8 @@
+2001-09-25  Bruno Haible  <haible@clisp.cons.org>
+
+       Upgrade to automake-1.5.
+       * Makefile.am (AUTOMAKE_OPTIONS): Add 'no-dependencies'.
+
 2001-10-20  Bruno Haible  <haible@clisp.cons.org>
 
        Assume strchr() exists.
index 324a20aac12c66a18ae4f1e4bf04183b0d14ef8e..92d8ffa56b30107abaed25e17c930464aa900385 100644 (file)
@@ -17,7 +17,7 @@
 
 ## Process this file with automake to produce Makefile.in.
 
-AUTOMAKE_OPTIONS = 1.2 gnits
+AUTOMAKE_OPTIONS = 1.5 gnits no-dependencies
 
 noinst_LIBRARIES = libnlsut.a
 
index 64cda748abbb931b5aca31b04ebccded924eff75..3f4bd8099b4d9ade64d1b2436363661dec191786 100644 (file)
@@ -1,3 +1,8 @@
+2001-09-25  Bruno Haible  <haible@clisp.cons.org>
+
+       Upgrade to automake-1.5.
+       * automake.diff: Remove file.
+
 2001-09-08  Bruno Haible  <haible@clisp.cons.org>
 
        * gettextize.in: Don't copy installed jar files.
diff --git a/misc/automake.diff b/misc/automake.diff
deleted file mode 100644 (file)
index f7aaaf3..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-*** automake.bak       Thu Jul 26 13:12:18 2001
---- automake   Thu Jul 26 13:17:36 2001
-***************
-*** 3362,3368 ****
-      }
-      else
-      {
-!      &am_error ("AM_GNU_GETTEXT in \`$configure_ac' but \`ALL_LINGUAS' not defined");
-      }
-  }
-  
---- 3362,3369 ----
-      }
-      else
-      {
-!      &am_error ("AM_GNU_GETTEXT in \`$configure_ac' but po/LINGUAS doesn't exist and \`ALL_LINGUAS' not defined")
-!          if ! -f "po/LINGUAS";
-      }
-  }
-  
diff --git a/missing b/missing
index c60e9d772f4b24b4e22b0a8a26a359a5e858e433..0a7fb5a2acec32d1ef949e5e7e7fb11460c5e021 100755 (executable)
--- a/missing
+++ b/missing
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Common stub for a few missing GNU programs while installing.
-# Copyright (C) 1996, 1997, 1999 Free Software Foundation, Inc.
+# Copyright 1996, 1997, 1999, 2000 Free Software Foundation, Inc.
 # Originally by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
 
 # This program is free software; you can redistribute it and/or modify
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 # 02111-1307, USA.
 
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+
 if test $# -eq 0; then
   echo 1>&2 "Try \`$0 --help' for more information"
   exit 1
@@ -25,6 +30,14 @@ fi
 
 run=:
 
+# In the cases where this matters, `missing' is being run in the
+# srcdir already.
+if test -f configure.ac; then
+  configure_ac=configure.ac
+else
+  configure_ac=configure.in
+fi
+
 case "$1" in
 --run)
   # Try to run requested program, and just exit if it succeeds.
@@ -57,6 +70,7 @@ Supported PROGRAM values:
   automake     touch all \`Makefile.in' files
   bison        create \`y.tab.[ch]', if possible, from existing .[ch]
   flex         create \`lex.yy.c', if possible, from existing .c
+  help2man     touch the output file
   lex          create \`lex.yy.c', if possible, from existing .c
   makeinfo     touch the output file
   tar          try tar, gnutar, gtar, then tar without non-portable flags
@@ -64,7 +78,7 @@ Supported PROGRAM values:
     ;;
 
   -v|--v|--ve|--ver|--vers|--versi|--versio|--version)
-    echo "missing 0.2 - GNU automake"
+    echo "missing 0.3 - GNU automake"
     ;;
 
   -*)
@@ -76,7 +90,7 @@ Supported PROGRAM values:
   aclocal)
     echo 1>&2 "\
 WARNING: \`$1' is missing on your system.  You should only need it if
-         you modified \`acinclude.m4' or \`configure.in'.  You might want
+         you modified \`acinclude.m4' or \`${configure_ac}'.  You might want
          to install the \`Automake' and \`Perl' packages.  Grab them from
          any GNU archive site."
     touch aclocal.m4
@@ -85,7 +99,7 @@ WARNING: \`$1' is missing on your system.  You should only need it if
   autoconf)
     echo 1>&2 "\
 WARNING: \`$1' is missing on your system.  You should only need it if
-         you modified \`configure.in'.  You might want to install the
+         you modified \`${configure_ac}'.  You might want to install the
          \`Autoconf' and \`GNU m4' packages.  Grab them from any GNU
          archive site."
     touch configure
@@ -94,10 +108,10 @@ WARNING: \`$1' is missing on your system.  You should only need it if
   autoheader)
     echo 1>&2 "\
 WARNING: \`$1' is missing on your system.  You should only need it if
-         you modified \`acconfig.h' or \`configure.in'.  You might want
+         you modified \`acconfig.h' or \`${configure_ac}'.  You might want
          to install the \`Autoconf' and \`GNU m4' packages.  Grab them
          from any GNU archive site."
-    files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' configure.in`
+    files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}`
     test -z "$files" && files="config.h"
     touch_files=
     for f in $files; do
@@ -113,7 +127,7 @@ WARNING: \`$1' is missing on your system.  You should only need it if
   automake)
     echo 1>&2 "\
 WARNING: \`$1' is missing on your system.  You should only need it if
-         you modified \`Makefile.am', \`acinclude.m4' or \`configure.in'.
+         you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'.
          You might want to install the \`Automake' and \`Perl' packages.
          Grab them from any GNU archive site."
     find . -type f -name Makefile.am -print |
@@ -174,7 +188,32 @@ WARNING: \`$1' is missing on your system.  You should only need it if
     fi
     ;;
 
+  help2man)
+    echo 1>&2 "\
+WARNING: \`$1' is missing on your system.  You should only need it if
+        you modified a dependency of a manual page.  You may need the
+        \`Help2man' package in order for those modifications to take
+        effect.  You can get \`Help2man' from any GNU archive site."
+
+    file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'`
+    if test -z "$file"; then
+       file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'`
+    fi
+    if [ -f "$file" ]; then
+       touch $file
+    else
+       test -z "$file" || exec >$file
+       echo ".ab help2man is required to generate this page"
+       exit 1
+    fi
+    ;;
+
   makeinfo)
+    if test -z "$run" && (makeinfo --version) > /dev/null 2>&1; then
+       # We have makeinfo, but it failed.
+       exit 1
+    fi
+
     echo 1>&2 "\
 WARNING: \`$1' is missing on your system.  You should only need it if
          you modified a \`.texi' or \`.texinfo' file, or any other file
index 2cbd5234e1eeff262bf143c878910c4e78ed0f30..816c378ae50d93c1cf458f76c5f3279dbeeac3b5 100644 (file)
@@ -1,3 +1,9 @@
+2001-09-25  Bruno Haible  <haible@clisp.cons.org>
+
+       Upgrade to automake-1.5.
+       * Makefile.am (AUTOMAKE_OPTIONS): Add 'no-dependencies'.
+       * ylwrap: Remove file.
+
 2001-09-22  Bruno Haible  <haible@clisp.cons.org>
 
        * xgettext.c (extractor_func): New typedef.
index 3165737d3f2f5f5c5747542b2d655c92f7e5a19a..82fd2efb4a7b45ac0e606aed6127cd89c9577db5 100644 (file)
@@ -17,7 +17,7 @@
 
 ## Process this file with automake to produce Makefile.in.
 
-AUTOMAKE_OPTIONS = 1.2 gnits
+AUTOMAKE_OPTIONS = 1.5 gnits no-dependencies
 
 bin_PROGRAMS = gettext ngettext \
 msgcmp msgfmt msgmerge msgunfmt xgettext \
index f649d2a624df7b28dd163aadf90201830f77d66c..f1a00318d268b26758483dbb2e307a1e13d6b1f7 100644 (file)
@@ -1,3 +1,8 @@
+2001-09-25  Bruno Haible  <haible@clisp.cons.org>
+
+       Upgrade to automake-1.5.
+       * Makefile.am (AUTOMAKE_OPTIONS): Add 'no-dependencies'.
+
 2001-09-23  Bruno Haible  <haible@clisp.cons.org>
 
        * msgfmt-6: New file.
index cd2507c76feac9fd5d937858506ade31aa12716f..f2b9bf8dea9ab2c63f2fd00685e77e961b5dd689 100644 (file)
@@ -17,7 +17,7 @@
 
 ## Process this file with automake to produce Makefile.in.
 
-AUTOMAKE_OPTIONS = 1.2 gnits
+AUTOMAKE_OPTIONS = 1.5 gnits no-dependencies
 
 TESTS = gettext-1 gettext-2 \
        msgcat-1 \
similarity index 57%
rename from src/ylwrap
rename to ylwrap
index 13fc38d75f2a47bc55e90ad5bf8d8a0184b14878..5ea68e4fcd33b2bcc19f9ee975458b49060157f2 100755 (executable)
+++ b/ylwrap
@@ -1,6 +1,6 @@
 #! /bin/sh
 # ylwrap - wrapper for lex/yacc invocations.
-# Copyright (C) 1996, 1997, 1998 Free Software Foundation, Inc.
+# Copyright 1996, 1997, 1998, 1999 Free Software Foundation, Inc.
 # Written by Tom Tromey <tromey@cygnus.com>.
 #
 # This program is free software; you can redistribute it and/or modify
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+
 # Usage:
-#     ylwrap PROGRAM INPUT [OUTPUT DESIRED]... -- [ARGS]...
-# * PROGRAM is program to run.
+#     ylwrap INPUT [OUTPUT DESIRED]... -- PROGRAM [ARGS]...
 # * INPUT is the input file
 # * OUTPUT is file PROG generates
 # * DESIRED is file we actually want
+# * PROGRAM is program to run
 # * ARGS are passed to PROG
 # Any number of OUTPUT,DESIRED pairs may be used.
 
-# The program to run.
-prog="$1"
-shift
-# Make any relative path in $prog absolute.
-case "$prog" in
- /* | [A-Za-z]:\\*) ;;
- */*) prog="`pwd`/$prog" ;;
-esac
-
 # The input.
 input="$1"
 shift
 case "$input" in
/* | [A-Za-z]:\\*)
[\\/]* | ?:[\\/]*)
     # Absolute path; do nothing.
     ;;
  *)
-    # Relative path.  Make it absolute.  Why?  Because otherwise any
-    # debugging info in the generated file will point to the wrong
-    # place.  This is really gross.
+    # Relative path.  Make it absolute.
     input="`pwd`/$input"
     ;;
 esac
 
-# We don't want to use the absolute path if the input in the current
-# directory like when making a tar ball.
-input_base=`echo $input | sed -e 's|.*/||'`
-if test -f $input_base && cmp $input_base $input >/dev/null 2>&1; then
-  input=$input_base
-fi
+# The directory holding the input.
+input_dir=`echo "$input" | sed -e 's,\([\\/]\)[^\\/]*$,\1,'`
+# Quote $INPUT_DIR so we can use it in a regexp.
+# FIXME: really we should care about more than `.' and `\'.
+input_rx=`echo "$input_dir" | sed -e 's,\\\\,\\\\\\\\,g' -e 's,\\.,\\\\.,g'`
+
+echo "got $input_rx"
 
 pairlist=
 while test "$#" -ne 0; do
@@ -67,6 +62,15 @@ while test "$#" -ne 0; do
    shift
 done
 
+# The program to run.
+prog="$1"
+shift
+# Make any relative path in $prog absolute.
+case "$prog" in
+ [\\/]* | ?:[\\/]*) ;;
+ *[\\/]*) prog="`pwd`/$prog" ;;
+esac
+
 # FIXME: add hostname here for parallel makes that run commands on
 # other machines.  But that might take us over the 14-char limit.
 dirname=ylwrap$$
@@ -74,15 +78,7 @@ trap "cd `pwd`; rm -rf $dirname > /dev/null 2>&1" 1 2 3 15
 mkdir $dirname || exit 1
 
 cd $dirname
-case "$input" in
- /* | [A-Za-z]:\\*)
-    # Absolute path; do nothing.
-    ;;
- *)
-    # Make a symbolic link, hard link or hardcopy.
-    ln -s ../"$input" . > /dev/null 2>&1 || ln ../"$input" . > /dev/null 2>&1 || cp ../"$input" .
-    ;;
-esac
+
 $prog ${1+"$@"} "$input"
 status=$?
 
@@ -90,15 +86,39 @@ if test $status -eq 0; then
    set X $pairlist
    shift
    first=yes
+   # Since DOS filename conventions don't allow two dots,
+   # the DOS version of Bison writes out y_tab.c instead of y.tab.c
+   # and y_tab.h instead of y.tab.h. Test to see if this is the case.
+   y_tab_nodot="no"
+   if test -f y_tab.c || test -f y_tab.h; then
+      y_tab_nodot="yes"
+   fi
+
    while test "$#" -ne 0; do
-      if test -f "$1"; then
+      from="$1"
+      # Handle y_tab.c and y_tab.h output by DOS
+      if test $y_tab_nodot = "yes"; then
+        if test $from = "y.tab.c"; then
+           from="y_tab.c"
+        else
+           if test $from = "y.tab.h"; then
+              from="y_tab.h"
+           fi
+        fi
+      fi
+      if test -f "$from"; then
          # If $2 is an absolute path name, then just use that,
          # otherwise prepend `../'.
          case "$2" in
-          /* | [A-Za-z]:\\*) target="$2";;
+          [\\/]* | ?:[\\/]*) target="$2";;
           *) target="../$2";;
         esac
-        mv "$1" "$target" || status=$?
+
+        # Edit out `#line' or `#' directives.  We don't want the
+        # resulting debug information to point at an absolute srcdir;
+        # it is better for it to just mention the .y file with no
+        # path.
+        sed -e "/^#/ s,$input_rx,," "$from" > "$target" || status=$?
       else
         # A missing file is only an error for the first file.  This
         # is a blatant hack to let us support using "yacc -d".  If -d