Akim Demaille wrote:

> dv>         Would it be possible for autoconf to load the site and
> dv> local macro files (like aclocal.m4) *before* the call to AC_INIT ?

> Even if you know what you are doing, you are breaking the contract
> with Autoconf: if you want to include something before AC_INIT it
> means you want to teach nasty tricks to AC_INIT_*.

        Yes.

> Playing with internals is definitely not supported, and will never be. If
> you feel the problem you're addressing is generic enough, you should
> probably specify your needs.

        The problem is that with AC_PACKAGE for instance, you're beginning to
give users an influence on the result of AC_INIT, since AC_INIT uses macros
defined by AC_PACKAGE. In such a situation either you give users full support
to do what they want (that's what they will expect anyway), or you don't give
them any. For instance, the problem I have been faced with is that I can't
pass plain text arguments to AC_PACKAGE: I compute the VERSION argument from
PRCS keywords, and I have a macro for that.

        Since I know what I'm doing, this macro doesn't expand to anything I'd
like to see apearing in `configure', it is pure [lib]m4. However, I only know
what I'm doing because I know autoconf from the inside which you don't want to
require from everybody.

        So IMHO, the dilemma is the following: if AC_INIT does stuff that the
user should be able to customize, you've got to give them full capabilities to
do what they want. Otherwise, you've got to defer some of AC_INIT computation
somehow. Maybe we should have a finer grain in AC_INIT ? A hook mechanism ?

--
    /     /   _   _       Didier Verna        http://www.inf.enst.fr/~verna/
 - / / - / / /_/ /        EPITA / LRDE         mailto:[EMAIL PROTECTED]
/_/ / /_/ / /__ /      14-16 rue Voltaire        Tel. +33 (1) 44 08 01 77
                   94276 Kremlin-Bicêtre cedex   Fax. +33 (1) 44 08 01 99

Reply via email to