DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

(autocf21.info.gz) Making configure Scripts

Info Catalog (autocf21.info.gz) Introduction (autocf21.info.gz) Top (autocf21.info.gz) Setup
 
 2 Making `configure' Scripts
 ****************************
 
 The configuration scripts that Autoconf produces are by convention
 called `configure'.  When run, `configure' creates several files,
 replacing configuration parameters in them with appropriate values.
 The files that `configure' creates are:
 
    * one or more `Makefile' files, one in each subdirectory of the
      package ( Makefile Substitutions);
 
    * optionally, a C header file, the name of which is configurable,
      containing `#define' directives ( Configuration Headers);
 
    * a shell script called `config.status' that, when run, will recreate
      the files listed above ( Invoking config.status);
 
    * a shell script called `config.cache' that saves the results of
      running many of the tests ( Cache Files);
 
    * a file called `config.log' containing any messages produced by
      compilers, to help debugging if `configure' makes a mistake.
 
    To create a `configure' script with Autoconf, you need to write an
 Autoconf input file `configure.in' and run `autoconf' on it.  If you
 write your own feature tests to supplement those that come with
 Autoconf, you might also write files called `aclocal.m4' and
 `acsite.m4'.  If you use a C header file to contain `#define'
 directives, you might also write `acconfig.h', and you will distribute
 the Autoconf-generated file `config.h.in' with the package.
 
    Here is a diagram showing how the files that can be used in
 configuration are produced.  Programs that are executed are suffixed by
 `*'.  Optional files are enclosed in square brackets (`[]').
 `autoconf' and `autoheader' also read the installed Autoconf macro
 files (by reading `autoconf.m4').
 
 Files used in preparing a software package for distribution:
      your source files --> [autoscan*] --> [configure.scan] --> configure.in
 
      configure.in --.   .------> autoconf* -----> configure
                     +---+
      [aclocal.m4] --+   `---.
      [acsite.m4] ---'       |
                             +--> [autoheader*] -> [config.h.in]
      [acconfig.h] ----.     |
                       +-----'
      [config.h.top] --+
      [config.h.bot] --'
 
      Makefile.in -------------------------------> Makefile.in
 
 Files used in configuring a software package:
                             .-------------> config.cache
      configure* ------------+-------------> config.log
                             |
      [config.h.in] -.       v            .-> [config.h] -.
                     +--> config.status* -+               +--> make*
      Makefile.in ---'                    `-> Makefile ---'
 

Menu

 
* Writing configure.in        What to put in an Autoconf input file.
* Invoking autoscan           Semi-automatic `configure.in' writing.
* Invoking ifnames            Listing the conditionals in source code.
* Invoking autoconf           How to create configuration scripts.
* Invoking autoreconf         Remaking multiple `configure' scripts.
 
Info Catalog (autocf21.info.gz) Introduction (autocf21.info.gz) Top (autocf21.info.gz) Setup
automatically generated byinfo2html