]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
build: No more need to rebuild a Makefile after POTFILES.in or LINGUAS changed.
authorBruno Haible <bruno@clisp.org>
Fri, 6 Dec 2024 22:25:01 +0000 (23:25 +0100)
committerBruno Haible <bruno@clisp.org>
Sat, 7 Dec 2024 04:49:45 +0000 (05:49 +0100)
* gettext-runtime/m4/po.m4 (AM_PO_SUBDIRS): Don't set or substitute
POMAKEFILEDEPS.
(AM_POSTPROCESS_PO_MAKEFILE): Remove dependency from Makefile on LINGUAS.
* gettext-runtime/po/Makefile.in.in (Makefile): Remove dependency on
@POMAKEFILEDEPS@.

gettext-runtime/m4/po.m4
gettext-runtime/po/Makefile.in.in

index 53ee71f7fa192fad945f96a4a5f79f0efd17bb94..1c1d11cfc7b325f56e6d8bc4f345010023519266 100644 (file)
@@ -127,12 +127,8 @@ changequote([,])dnl
         # POTFILES.in file. This allows packages to have multiple PO
         # directories under different names or in different locations.
         if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
-          POMAKEFILEDEPS="POTFILES.in"
-          if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
-            POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
-          fi
           test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
-          sed -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
+          sed -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
           for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
             if test -f "$f"; then
               case "$f" in
@@ -151,22 +147,7 @@ changequote([,])dnl
 dnl Postprocesses a Makefile in a directory containing PO files.
 AC_DEFUN([AM_POSTPROCESS_PO_MAKEFILE],
 [
-changequote(,)dnl
-  # Adjust a relative srcdir.
-  ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
-changequote([,])dnl
-
-  POMAKEFILEDEPS=""
-  if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
-    POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
-  fi
-
   sed -e 's,^#distdir:,distdir:,' < "$ac_file" > "$ac_file.tmp"
-  if test -n "$POMAKEFILEDEPS"; then
-    cat >> "$ac_file.tmp" <<EOF
-Makefile: $POMAKEFILEDEPS
-EOF
-  fi
   mv "$ac_file.tmp" "$ac_file"
 ])
 
index 0537642a57761ae629212af2861bc0a20cba3d87..04ad6c297a75fe16525e96de0d39e2afa890a782 100644 (file)
@@ -546,7 +546,7 @@ update-gmo: Makefile $(GMOFILES)
 # because execution permission bits may not work on the current file system.
 # Use @SHELL@, which is the shell determined by autoconf for the use by its
 # scripts, not $(SHELL) which is hardwired to /bin/sh and may be deficient.
-Makefile: Makefile.in.in Makevars $(top_builddir)/config.status @POMAKEFILEDEPS@
+Makefile: Makefile.in.in Makevars $(top_builddir)/config.status
        cd $(top_builddir) \
          && @SHELL@ ./config.status $(subdir)/$@.in po-directories