1 #################################################################################
5 # The Glorious fptools Boilerplate Makefile
7 # This one file should be included (directly or indirectly) by all Makefiles
8 # in the fptools hierarchy.
10 #################################################################################
12 # We want to disable all the built-in rules that make uses; having them
13 # just slows things down, and we write all the rules ourselves.
14 # Setting .SUFFIXES to empty disables them all.
15 MAKEFLAGS += --no-builtin-rules
17 # FPTOOLS_TOP is the *relative* path to the fptools toplevel directory from the
18 # location where a project Makefile was invoked. It is set by looking at the
19 # current value of TOP.
24 # This rule makes sure that "all" is the default target, regardless of where it appears
25 # THIS RULE MUST REMAIN FIRST!
29 # -----------------------------------------------------------------------------
30 # make sure the autoconf stuff is up to date...
32 $(TOP)/mk/config.mk : $(TOP)/mk/config.mk.in $(TOP)/mk/config.h.in $(TOP)/configure
33 @if test ! -f $(FPTOOLS_TOP)/config.status; then \
34 echo "You haven't run $(FPTOOLS_TOP)/configure yet."; \
37 @echo "Running $(FPTOOLS_TOP)/config.status to update configuration info..."
38 @( cd $(FPTOOLS_TOP) && ./config.status )
40 $(TOP)/configure : $(TOP)/configure.in $(TOP)/aclocal.m4
41 @echo "Regenerating $(FPTOOLS_TOP)/configure..."
42 @( cd $(FPTOOLS_TOP) && $(MAKE) -f Makefile.config ./configure )
44 # -----------------------------------------------------------------------------
47 # If $(way) is set then we define $(way_) and $(_way) from it in the
48 # obvious fashion. This must be done before suffix.mk is included,
49 # because the pattern rules in that file depend on these variables.
56 # -----------------------------------------------------------------------------
57 # Now follow the pieces of boilerplate
58 # The "-" signs tell make not to complain if they don't exist
60 include $(TOP)/mk/config.mk
61 # All configuration information
62 # (generated by "configure" from config.mk.in)
66 include $(TOP)/mk/paths.mk
67 # Variables that say where things belong (e.g install directories)
68 # and where we are right now
69 # Also defines variables for standard files (SRCS, LIBS etc)
72 include $(TOP)/mk/opts.mk
73 # Variables that control the option flags for all the
76 ifeq "$(BootingFromHc)" "YES"
77 include $(TOP)/mk/bootstrap.mk
80 -include $(TOP)/mk/build.mk
81 # (Optional) build-specific configuration
87 # The dependencies file from the current directory