[article] trimming down autoconf's configure scripts by using pkg-config

Miles Bader miles.bader at necel.com
Mon Mar 27 18:02:37 PST 2006


Enrico Weigelt <weigelt at metux.de> writes:
> Why can't we just define strict interfaces and maintain an database
> for each target system, which tells the buildsystem what features 
> the target system has.

You can certainly _define_ such interfaces, but they are useless unless
a sufficient proportion of systems actually _provide_ them.  Likewise
the "database" -- it could work if enough systems provided such a thing.
If.

The basic point being that autconf actually works, and is fairly robust
in the real world, which is not quite so squeaky clean and dependable as
you'd like.

The thing is that we _know_ that it's good to have common interfaces,
and people are trying to work towards that end (the growing popularity
pkg-config is a good example of that).  As the computing world (slowly)
gets more sane, configure files will get simpler and simpler, and maybe
eventually become mostly wrappers that invoke pkg-config a bunch of
times.

But in the meantime, it's a jumble; sometimes you depend on pkg-config
to give you the info you need (because you know a particular library
always has pkg-config support), sometimes you've got to probe for
functionality, sometimes even just make a guess based on system type.
Autoconf caters to all these approaches -- not always elegantly, but
at least it usually works, and can be made fairly robust.

If you want to get _rid_ of autoconf (as you seem to want to), however,
you're going to have to demonstrate an alternative that actually works,
in the real world.  Unless you can do that, why would anybody follow you?

-Miles
-- 
We have met the enemy, and he is us.  -- Pogo



More information about the xorg mailing list