[Top][All Lists]

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

Re: An autoconf tutorial.

From: Andre Caldas
Subject: Re: An autoconf tutorial.
Date: Thu, 26 May 2005 09:59:42 +0900
User-agent: Debian Thunderbird 1.0.2 (X11/20050331)

Hello, Ed!

There are many things that are considered "bad practice". There are many things that are "old deprecated" ways to do things.

For example, using the file name "" is outdated. You should use "". I guess (I don't really know) that the reason for this is that "in" is supposed to mean "input". "" is an input file to generate a "configure" script. This, however, assumes you have only one program processing the inputs:
       ---> configure
if you have something like this
       ---> something.aa ---> something,
the extension "in" makes no sense. It is much better to name the file after the program that is supposed to process it: autoconf ---> ac, aumotmake ---> am.

Ralf Wildenhues wrote:
Hi Ed,

Please keep the mailing list copied, this is interesting for others as
well.  Thank you.

* E. Rosten wrote on Wed, May 25, 2005 at 10:53:13AM CEST:

On Wed, 25 May 2005, Ralf Wildenhues wrote:

* E. Rosten wrote on Mon, May 23, 2005 at 06:59:05PM CEST:

| M4 arguments are quoted with [ and ]. There is NO WAY to escape these,
| however, you can change the quoting using:
|                          changequote(<<,>>)


Please don't encourage use of changequote.

How come?

Documented in
  info Autoconf 'Changequote is Evil'

It is at least as bad as changing the value of a global variable that is supposed to be constant.

Rather quadrigraphs.

I didn't know about it. Its nice beeing on the mailing list. :-)

What are they (I haven't encountered them)? Is it a way of entering [ and ] without [ and ] actually appearing?

Documented in
  info Autoconf Quadrigraphs

Ed, it would be very nice if you could put "warnings" in your tutorial telling people to avoid every "bad practice" you know about. When I started using autoconf, I used to visit some tutorial websites. Some would say "do like this", and others would say "never do this" for the same thing. It is very confusing. There is already a lot of information to memorize. One ends up not knowing what you should or shouldn't do. You never know what source of information you should trust. A good tutorial IMHO would say:

"You will see that in a lot of places the macro AC_XXX is used like [this or that]. This is not considered 'good practice' because of [this and that]. The correct aproach is [this and that]."

This way one knows exactly what source of information to trust. Of course not everybody agrees in what is or isn't "good practice". If you are aware of such divergencies, it would be nice to have a comment about it, too.

The important thing to learn about autotools, is not how to get the job done. But how to do it in a clean way.

Please, keep doing the good work. And be open to criticism. This way, you will not only help lots of people, but probably the one who will learn most is going to be you.

Andre Caldas.

reply via email to

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