[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section
From: |
Bruno Haible |
Subject: |
Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section |
Date: |
Mon, 6 Dec 2004 17:10:57 +0100 |
User-agent: |
KMail/1.5 |
Jim Meyering wrote:
> This philosophy is nothing new, just not as widespread as it should be.
> It's been done for obstack and error via their AC_ macros for ages.
> I wish we had adopted the practice sooner.
'obstack' and 'error' in autoconf predate gnulib.
The arguments against dealing with filenames in autoconf macros that come
to mind:
- Filename processing goes from
*.m4 -> aclocal.m4 -> Makefile.in -> Makefile
which is a longer chain than
Makefile.am -> Makefile.in -> Makefile.
Thus it reduces transparency. Also when you write them, you need to
think not only about Makefile syntax escaping, but also about
shell and m4 syntax escaping.
- Specifying filenames in autoconf macros makes for a temptation to use
the filename already using autoconfiguration. Which doesn't work if
the filename contains references to Makefile variables, such as
vacall-$(CPU).$lo
- Specifying filenames in autoconf macros makes it hard for two packages
to have different directory layout. For example, the gnulib stuff
goes into gettext-tools/lib/ but into libiconv/srclib/ - because lib/
already holds other stuff.
- Makefiles also contains build rules. You cannot currently (and
hopefully won't try to!) specify Makefile rules from within an
autoconf macro.
- Each time a developer adds a source file, what happens? If the filename
is stored it the Makefile.am, and the developer changes this, just
config.status gets run again. If the filename is stored in an autoconf
macro, and the developer changes this, it will rebuild aclocal.m4,
configure, and re-configure the whole package.
- AC_CONFIG_LIBOBJ_DIR provides for a single lib directory only.
In gettext I already have two such directories.
- There is another macro in autoconf that deals with files, namely
AC_CONFIG_LINKS. I've had only problems with it.
Bruno
- [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section, Jim Meyering, 2004/12/06
- Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section, Bruno Haible, 2004/12/06
- Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section, Jim Meyering, 2004/12/06
- Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section, Stepan Kasal, 2004/12/06
- Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section, Jim Meyering, 2004/12/06
- Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section, Stepan Kasal, 2004/12/06
- Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section, Jim Meyering, 2004/12/08
- Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section, Stepan Kasal, 2004/12/08
- Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section, Bruno Haible, 2004/12/06
- Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section,
Bruno Haible <=
- Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section, Jim Meyering, 2004/12/07
- Re: [bug-gnulib] using AC_LIBSOURCES: complementing the `Files:' section, Karl Berry, 2004/12/07