Samba 3.0.22 Porting by Vidya Sagar

your current working directory. If makefile does not exist, then make searches for a file named Makefile. If you don't want
to use one of the default names, other files can be used with the “
-f command-line” option. The convention used to identify
makefiles not named
makefile or Makefile is to use the .mk suffix (for example, foo.mk).
autoconf: Autoconf is a tool for producing shell scripts that automatically configure software source code packages to
adapt to many kinds of Posix-like systems. Autoconf takes input from a template file named configure.ac (or
configure.in) and generates a configure script conventionally called configure. The configuration script generated,
automatically checks for each feature the OS supports that is necessary for the software package. You may find an entry
for the well known UNIX flavors in the template file which defines specific behavior corresponding to the feature. Changes
relative to MPE/iX are required to be done in the configuration template file. The generated script, configure, also
produces a few intermediate and log files and those are: Makefile(s), config.status, config.cache
(optional), config.log, and an optional C header file which defines some #define directives. One or many (in the
source subdirectories) Makefile(s) are created by script configure by taking input from file Makefile.in. For
more information on autoconf and to learn the syntax rules of template file it is recommended to visit the site
http://www.gnu.org/software/autoconf/manual/autoconf.html.
autoheader: This tool reads the template file configure.ac (or configure.in) and generates an input file
config.h.in which in turn is read by script configure to produce a C header file conventionally called config.h.
The diagram below shows a typical build environment of an open source portable software package.
po
rt
e
r
In this paper we play the roles of “developer” & porter rather than “user”. That is we will not modify the “configure” script
or Makefile(s) directly as autoconf recreates script configure and the later recreates Makefile(s) by reading
Makefile.in. Rather, the changes will be done in the template or input files (configure.ac, Makefile.in and
config.h.in) so that the derived “user” steps will execute correctly and consistently.
4