1#!/bin/sh 2 3# This is a simple script which is meant to help developers 4# better deal with the GNU autotools, specifically: 5# 6# aclocal 7# autoheader 8# autoconf 9# autromake 10# 11# The whole thing is quite complex... 12# 13# The idea is to run this collection of tools on a single platform, 14# typically the main development platform, running a recent version of 15# autoconf. In theory, if we had these tools on each platform where we 16# ever expected to port the software, we would never need to checkin 17# more than a few autotools configuration files. However, the whole 18# idea is to generate a configure script and associated files in a way 19# that is portable across platforms, so we *have* to check in a whole 20# bunch of files generated by all these tools. 21 22# The real source files are: 23# 24# acinclude.m4 (used by aclocal) 25# configure.ac (main autoconf file) 26# Makefile.am, */Makefile.am (automake config files) 27# 28# All the rest is auto-generated. 29 30 31# --- Step 1: Generate aclocal.m4 from: 32# . acinclude.m4 33# . config/*.m4 (these files are referenced in acinclude.m4) 34 35echo "Running aclocal" 36aclocal 37 38# --- Step 2: Generate config.h.in from: 39# . configure.ac (look for AM_CONFIG_HEADER tag or AC_CONFIG_HEADER tag) 40 41echo "Running autoheader" 42autoheader 43 44# --- Step 3: Generate configure and include/miaconfig.h from: 45# . configure.ac 46# 47 48echo "Running autoconf" 49autoconf 50 51# --- Step 4: Generate Makefile.in, src/Makefile.in, and a whole bunch of 52# files in config (config.guess, config.sub, depcomp, 53# install-sh, missing, mkinstalldirs) plus COPYING and 54# INSTALL from: 55# . Makefile.am 56# . src/Makefile.am 57# 58# Using --add-missing --copy makes sure that, if these files are missing, 59# they are copied from the system so they can be used in a distribution. 60 61echo "Running automake --add-missing --copy" 62automake --add-missing --copy 63 64echo "All done." 65echo "To build the software now, do something like:" 66echo "" 67echo "$ ./configure [--with-debug] [...other options]" 68echo "$ make" 69