Original author(s)David Mackenzie
Developer(s)GNU Project
Initial release1991
Stable release
2.72[1] Edit this on Wikidata / 22 December 2023; 6 months ago (22 December 2023)
Written inPerl
Operating systemCross-platform
TypeProgramming tool
LicenseGNU GPL

GNU Autoconf is a tool for producing configure scripts for building, installing, and packaging software on computer systems where a Bourne shell is available.

Autoconf is agnostic about the programming languages used, but it is often used for projects using C, C++, Fortran, Fortran 77, Erlang, or Objective-C.

A configure script configures a software package for installation on a particular target system. After running a series of tests on the target system, the configure script generates header files and a makefile from templates, thus customizing the software package for the target system. Together with Automake and Libtool, Autoconf forms the GNU Build System, which comprises several other tools, notably Autoheader.

Usage overview

Flow diagram of Autoconf and Automake. Note that "configure.ac" was named "configure.in" in early versions of Autoconf.

The developer specifies the desired behaviour of the configure script by writing a list of instructions in the GNU m4 language in a file called "configure.ac". A library of pre-defined m4 macros is available to describe common configure script instructions. Autoconf transforms the instructions in "configure.ac" into a portable configure script. The system that will be doing the building need not have Autoconf installed: Autoconf is needed only to build the configure script, that is usually shipped with the software.


Autoconf was begun in the summer of 1991 by David Mackenzie to support his work at the Free Software Foundation. In the subsequent years it grew to include enhancements from a variety of authors and became the most widely used build configuration system for writing portable free or open-source software.


Autoconf is similar to the Metaconfig package used by Perl. The imake system formerly used by the X Window System (up to X11R6.9) is closely related, but has a different philosophy.

The Autoconf approach to portability is to test for features, not for versions. For example, the native C compiler on SunOS 4 did not support ISO C. However, it is possible for the user or administrator to have installed an ISO C-compliant compiler. A pure version-based approach would not detect the presence of the ISO C compiler, but a feature-testing approach would be able to discover the ISO C compiler the user had installed. The rationale of this approach is to gain the following advantages:

Autoconf provides extensive documentation around the non-portability of many POSIX shell constructs to older shells and bugs therein. It also provides M4SH, a macro-based replacement for shell syntax.[2]


There is some criticism that states that Autoconf uses dated technologies, has a lot of legacy restrictions, and complicates simple scenarios unnecessarily for the author of configure.ac scripts. In particular, often cited weak points of Autoconf are:

Due to these limitations, several projects that used GNU Build System switched to different build systems, such as CMake and SCons.[3][9]

See also


  1. ^ Zachary Weinberg (22 December 2023). "autoconf-2.72 released [stable]". Retrieved 25 December 2023.
  2. ^ "Portable Shell". Autoconf. Retrieved 20 January 2020.
  3. ^ a b Neundorf, Alexander (2006-06-21). "Why the KDE project switched to CMake -- and how".
  4. ^ Kamp, Poul-Henning (2012-08-15). "A Generation Lost in the Bazaar". ACM Queue. 10 (8): 20–23. doi:10.1145/2346916.2349257. S2CID 11656592.
  5. ^ a b McCall, Andrew (2003-06-21). "Stop the autoconf insanity! Why we need a new build system".
  6. ^ "GNU Coding Standards".
  7. ^ Kamp, Poul-Henning (2010-04-20). "Did you call them autocrap tools?". Archived from the original on 2017-09-11. Retrieved 2017-08-16.
  8. ^ Dickey, Thomas. "why i still use autoconf 2.13".
  9. ^ "Blender.org - Build systems". Archived from the original on 2008-12-02. Retrieved 2009-06-10.