bug-autoconf
[Top][All Lists]
Advanced

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

AM_GNU_GETTEXT and autoconf 2.50


From: karl
Subject: AM_GNU_GETTEXT and autoconf 2.50
Date: Thu, 7 Jun 2001 13:04:00 -0400

(Sorry for sending to all three lists, but it's not clear to me whether
this needs to be addressed in autoconf, automake, gettext, or some
combination.)

The AM_GNU_GETTEXT macro (actually the AM_WITH_NLS macro that it calls)
did not work for me (in the Texinfo distribution) after updating to
autoconf 2.50.  po/Makefile did not get created from po/Makefile.in.

After running sh -vx config.status, I saw that this line was the problem:
          if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
ac_given_srcdir is no longer set by config.status, so this was checking
for /po/POTFILES.in, which naturally didn't exist.

The right correction is not obvious to me.  It looks like that part of
AM_WITH_NLS needs to use AC_CONFIG_COMMANDS instead of
AC_OUTPUT_COMMANDS, its computation of top_srcdir seems unnecessary
since there is now ac_top_srcdir (not that any *top_srcdir is useful
here as far as I can tell), etc., etc.

And since we probably don't want to force all users of gettext to update
to the new autoconf when gettext itself does, it all has to be
conditional, or something.  Argh.  Thus I was wondering if a change
could be made in autoconf that would allow the existing AM_GNU_GETTEXT
to continue to work.

Anyway, so that I could get on with work, I changed the two occurrences
of $ac_given_srcdir there to $ac_srcdir, which I doubt is sufficient in
general, but at least then po/Makefile gets created again.

Looking forward to a real fix :),
karl


diff -c /usr/local/gnu/src/gettext-0.10.38/ORIG/aclocal.m4 
/usr/local/gnu/src/gettext-0.10.38/aclocal.m4
*** /usr/local/gnu/src/gettext-0.10.38/ORIG/aclocal.m4  Wed May 23 13:48:43 2001
--- /usr/local/gnu/src/gettext-0.10.38/aclocal.m4       Thu Jun  7 09:54:52 2001
***************
*** 1031,1040 ****
              /*) top_srcdir="$ac_given_srcdir" ;;
              *)  top_srcdir="$ac_dots$ac_given_srcdir" ;;
            esac
!           if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
              rm -f "$ac_dir/POTFILES"
              echo creating "$ac_dir/POTFILES"
!             sed -e "/^#/d" -e "/^[    ]*\$/d" -e "s,.*,     $top_srcdir/& 
\\\\," -e "\$s/\(.*\) \\\\/\1/" < "$ac_given_srcdir/$ac_dir/POTFILES.in" > 
"$ac_dir/POTFILES"
              echo creating "$ac_dir/Makefile"
              sed -e "/POTFILES =/r $ac_dir/POTFILES" "$ac_dir/Makefile.in" > 
"$ac_dir/Makefile"
            fi
--- 1031,1040 ----
              /*) top_srcdir="$ac_given_srcdir" ;;
              *)  top_srcdir="$ac_dots$ac_given_srcdir" ;;
            esac
!           if test -f "$ac_srcdir/$ac_dir/POTFILES.in"; then
              rm -f "$ac_dir/POTFILES"
              echo creating "$ac_dir/POTFILES"
!             sed -e "/^#/d" -e "/^[    ]*\$/d" -e "s,.*,     $ac_srcdir/& 
\\\\," -e "\$s/\(.*\) \\\\/\1/" < "$ac_srcdir/$ac_dir/POTFILES.in" > 
"$ac_dir/POTFILES"
              echo creating "$ac_dir/Makefile"
              sed -e "/POTFILES =/r $ac_dir/POTFILES" "$ac_dir/Makefile.in" > 
"$ac_dir/Makefile"
            fi

Diff finished at Thu Jun  7 09:56:40



reply via email to

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