]> git.saurik.com Git - apt.git/blame - buildlib/configure.mak
fix crash in order writing in pkgDPkgPM::WriteApportReport()
[apt.git] / buildlib / configure.mak
CommitLineData
46976ca4
AL
1# -*- make -*-
2
3# This make fragment is included by the toplevel make to handle configure
4# and setup. It defines a target called startup that when run will init
ed9ba607 5# the build directory, generate configure from configure.ac, create aclocal
46976ca4
AL
6# and has rules to run config.status should one of the .in files change.
7
8# Input
53da8d70 9# BUILDDIR - The build directory
46976ca4
AL
10# CONVERTED - List of files output by configure $(BUILD) is prepended
11# The caller must provide depends for these files
12# It would be a fairly good idea to run this after a cvs checkout.
53da8d70 13BUILDDIR=build
46976ca4 14
7f9692a9 15.PHONY: startup missing-config-files
b2e465d6 16startup: configure $(BUILDDIR)/config.status $(addprefix $(BUILDDIR)/,$(CONVERTED))
46976ca4 17
3e2f480d
MV
18# use the files provided from the system instead of carry around
19# and use (most of the time outdated) copycats
7f9692a9
DK
20ifeq (file-okay,$(shell test -r buildlib/config.sub && echo 'file-okay'))
21buildlib/config.sub:
22else
23 ifeq (file-okay,$(shell test -r /usr/share/misc/config.sub && echo 'file-okay'))
3e2f480d 24buildlib/config.sub:
f6ffd375 25 ln -sf /usr/share/misc/config.sub buildlib/config.sub
7f9692a9
DK
26 else
27buildlib/config.sub: missing-config-files
28 endif
29endif
30
31ifeq (file-okay,$(shell test -r buildlib/config.guess && echo 'file-okay'))
32buildlib/config.guess:
33else
34 ifeq (file-okay,$(shell test -r /usr/share/misc/config.guess && echo 'file-okay'))
3e2f480d 35buildlib/config.guess:
742f5705 36 ln -sf /usr/share/misc/config.guess buildlib/config.guess
7f9692a9
DK
37 else
38buildlib/config.guess: missing-config-files
39 endif
40endif
41
42missing-config-files:
43 @echo "APT needs 'config.guess' and 'config.sub' in buildlib/ for configuration."
44 @echo "On Debian systems these are available in the 'autotools-dev' package."
45 @echo
46 @echo "The latest versions can be acquired from the upstream git repository:"
47 @echo "http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD"
48 @echo "http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD"
49 exit 100
50
ed9ba607 51configure: aclocal.m4 configure.ac buildlib/config.guess buildlib/config.sub
2ccad029
AL
52 autoconf
53
33ca57b6 54aclocal.m4: $(wildcard buildlib/*.m4)
46976ca4 55 aclocal -I buildlib
742f5705 56
53da8d70 57$(BUILDDIR)/config.status: configure
742f5705 58 /usr/bin/test -e $(BUILDDIR) || mkdir $(BUILDDIR)
53da8d70 59 (HERE=`pwd`; cd $(BUILDDIR) && $$HERE/configure)
742f5705
DK
60
61$(addprefix $(BUILDDIR)/,$(CONVERTED)): $(BUILDDIR)/config.status