autoheader, configure.in de yazılı olan AC_CONFIG_HEADER makrosu ile belirlenmiş olan dosya için include dosyasını yaratır.
Örnek:
AC_CONFIG_HEADER(config.h)
# autoheader
Bu işlemden sonra config.h.in dosyası
yaratılır. config.h.in içeriğinde ise AC_DEFINE ve AC_DEFINE_UNQUOTED ile belirlediğiniz
tanımlamaların #undef olarak yer
aldığını görebilirsiniz. configure, yukarıdaki örneğimize göre config.h.in dosyasını prototip olarak alacak ve topladığı verilere göre config.h'ı yaratacaktır.
--- configure.in ---
AC_INIT(deneme.c)
AC_CONFIG_HEADER(config.h)
AC_PROG_CC
AC_LANG_C
AC_HEADER_STDC
AC_CHECK_FUNCS(atol)
AC_DEFINE(DENEME, 1, [Ornek define])
AC_OUTPUT(Makefile)
--------------------
# autoheader
--- config.h.in ---
/* config.h.in Generated automatically from configure.in by autoheader */
/* Define if you have the ANSI C header files */
#undef STDC_HEADERS
/* Define if you have the atol function */
#undef HAVE_ATOL
/* Ornek define */
#undef DENEME
-------------------
# ./configure
...
...
--- config.h ---
/* config.h Generated automatically by configure */
/* config.h.in Generated automatically from configure.in by autoheader */
/* Define if you have the ANSI C header files */
#define STDC_HEADERS 1
/* Define if you have the atol function */
#define HAVE_ATOL 1
/* Ornek define */
#define DENEME 1
----------------
Programınızda bu tanımlamaları kullanabilmek için #include "config.h" işlemini yapmayı unutmayın.