[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Where Do All These Macros Come From?
From: |
Paul Smith |
Subject: |
Re: Where Do All These Macros Come From? |
Date: |
Fri, 24 May 2013 10:28:17 -0400 |
On Fri, 2013-05-24 at 07:25 -0700, Jordan H. wrote:
> Hello, folks!
>
> In learning automake I keep looking at example configure.ac files and in
> the tutorial someone says "oh, you can just use this here macro." I look
> in the automake manual, though
> (https://www.gnu.org/software/automake/manual/automake.html#Macro-Index)
> and find the macro to not be found. One example is AC_CHECK_LIB that's
> automatically generated by autoscan...I see very little documentation on
> this macro.
>
> Is there a special syntax for configure.ac? This is never really
> explained in any tutorial. All I see is someone pulling a variable out
> from who-knows-where and a different tutorial doing the exact same thing
> pulls a different macro from who-know-where.
>
> Thanks. Hope my question is clear. I'm still sort of a newbie with automake.
Your problem is that your confusing automake and autoconf.
Automake is the tool that manages makefiles: it turns a Makefile.am file
into a Makefile.in file.
Autoconf is the tool that manages configuration: it turns a configure.ac
file into the configure script.
When your user runs the configure script, one of the things it does is
convert the Makefile.in file to a normal Makefile.
As a general rule, the autoconf macros that begin with "AM_" are
automake macros. The macros that begin with "AC_" are autoconf macros,
and you need to read the autoconf documentation to learn about those.