Table of Contents
The make+ command looks to the end user a lot like ordinary make. It is invoked with a list of targets, each target telling make+ to perform a particular task. The common targets, which will be familiar to people who use make are:
Configure the package, ready to compile it.
Compile the package. (Because "all" is the default target, it can be omitted if it is the only target).
Run any provided tests on the package.
Install the package.
Create a source tarball of the package.
Create a binary tarball of the package.
Create an RPM (Red Hat Linux Package Manager) package, if this is supported by the architecture.
Create a Debian GNU/Linux package, if this is supported by the architecture.
Create all possible package formats, create the website, and upload everything to the web server.
This step replaces the ./configure command generated by other build systems, notably autoconf. The configuration step is intended to sniff out the capabilities of the system and decide which optional parts of the package should be built.
Typical capabilities include detecting that the required compiler tools are installed, checking for header files, and checking whether libraries are installed.
Your Makefile+ should contain a configure target similar to this one:
Example 4.1. Basic configure target
configure: $(MP_CONFIGURE_START) $(MP_CHECK_HEADERS) string.h unistd.h $(MP_CONFIGURE_END)
In the example above, make+ will generate a C header file called config.h (in the build subdirectory, naturally) containing:
/* Generated automatically by make+. */ #ifndef MP_CONFIG_H #define MP_CONFIG_H #define PACKAGE "foo" #define VERSION "0.0.1" #define HAVE_STRING_H 1 #define HAVE_UNISTD_H 1 #endif /* MP_CONFIG_H */