bug-automake
[Top][All Lists]
Advanced

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

.m4 dependencies: automake is smarter than aclocal


From: Jim Meyering
Subject: .m4 dependencies: automake is smarter than aclocal
Date: Mon, 03 May 2004 11:19:44 +0200

Hi Alexandre!

[ I've Cc'd bug-gettext, since this may affect other packages
  that use AM_GNU_GETTEXT. ]

I've just recently removed coreutils' m4/Makefile* files, since
I was pleasantly surprised to see that they are no longer necessary:
automake determines which .m4 files are actually used and lists them
in every Makefile.in.

That led to my noticing that several .m4 files previously included
in coreutils distributions (and still in CVS) are no longer included
in dist tarballs.  I confirmed that surprising fact and removed them,
then ran `make distcheck' which passed, so I cvs-removed them.  However,
the next time I ran aclocal, I saw these errors:

  aclocal: m4/gettext.m4: 430: macro `AM_LC_MESSAGES' not found in library
  aclocal: macro `gt_TYPE_INTMAX_T' required but not defined
  aclocal: macro `gt_PRINTF_POSIX' required but not defined
  aclocal: macro `gt_INTDIV0' required but not defined
  aclocal: macro `gl_XSIZE' required but not defined

Of course, those macros correspond to the files I'd removed,
and the root of this trouble lies with a conditional dependency
in gettext.m4's AM_GNU_GETTEXT:

  ifelse(gt_included_intl, yes, [
    AC_REQUIRE([AM_INTL_SUBDIR])dnl
  ])

Since that condition is always false in coreutils (the sole use
of AM_GNU_GETTEXT looks like this):

  AM_GNU_GETTEXT([external], [need-ngettext])

automake is right in not including any of the .m4 files
needed for when gettext's intl/ directory is included as part
of the package.

In any case, as what I hope is just a temporary measure, I've
commented out the above part of gettext.m4 as well as the body
of the AM_INTL_SUBDIR macro, and now aclocal works once again.

On one hand, it seems like it'd be better to have a separate gettext
macro for this less-encumbered, no-intl/ case, but I can also see the
case for leaving things the way they are and making aclocal smarter.

This is mainly just a heads-up, since I do have a work-around.

Thanks for all your work on automake!

Jim




reply via email to

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