[project @ 1997-03-17 20:34:25 by simonpj]
[ghc-hetmet.git] / Makefile
1 #################################################################################
2 #
3 #                       fptools/Makefile
4 #
5 #               This is the main Makefile for fptools.
6 #
7 #################################################################################
8
9 TOP=.
10 include $(TOP)/mk/boilerplate.mk
11 SRC_DIST_DIR=$(shell pwd)/$(SRC_DIST_NAME)
12
13 SUBDIRS = $(ProjectsToBuild)
14
15 #
16 # Files to include in fptools source distribution
17 #
18 SRC_DIST_DIRS += mk $(ProjectsToBuild)
19 SRC_DIST_FILES += configure.in config.guess config.sub configure README ANNOUNCE NEWS INSTALL Makefile
20
21
22 #
23 # Making a binary distribution
24 #
25 BIN_DIST_TMPDIR=$(shell pwd)
26 BIN_DIST_NAME=fptools
27
28 #
29 # list of toplevel `projects' to include in binary distrib.
30 #
31 BIN_DIST_DIRS=ghc
32
33 binary-dist:: binary-dist-pre
34
35 BIN_DIST_TOP= distrib/Makefile-bin.in \
36               distrib/configure-bin.in \
37               distrib/README \
38               distrib/INSTALL \
39               distrib/ANNOUNCE
40
41 binary-dist::
42         @for i in $(BIN_DIST_TOP); do \
43           @echo cp $$i $(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME) \
44           cp $$i $(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME) \
45         done;
46
47 #
48 # Creating and copying the documentation into the bin-dist tree.
49 #
50 binary-dist::
51         $(MKDIRHIER) $(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/html
52         $(MKDIRHIER) $(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/dvi
53         $(MKDIRHIER) $(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/info
54         @echo "Making html documentation.."
55         $(MAKE) -C docs --no-print-directory $(MFLAGS) html
56         cp docs/html/* $(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/html
57         @echo "Making dvi files.."
58         $(MAKE) -C docs --no-print-directory $(MFLAGS) dvi
59         cp docs/*.dvi  $(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/dvi
60         @echo "Making info files.."
61         $(MAKE) -C docs --no-print-directory $(MFLAGS) info
62         cp docs/*.info* $(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/info
63
64 dist :: dist-pre
65 include $(TOP)/mk/target.mk
66 dist :: dist-post
67