125
|
1 ifeq (,$(wildcard config.mak))
|
|
2 $(error "config.mak is not present, run configure !")
|
|
3 endif
|
|
4 include config.mak
|
|
5
|
|
6 DISTFILE = recpt1-$(VERSION).tar.bz2
|
|
7
|
|
8 EXTRADIST = configure \
|
|
9
|
|
10 SUBDIRS = src \
|
|
11
|
|
12 all:
|
|
13 for subdir in $(SUBDIRS); do \
|
|
14 $(MAKE) -C $$subdir $@; \
|
|
15 done
|
|
16
|
|
17 clean:
|
|
18 for subdir in $(SUBDIRS); do \
|
|
19 $(MAKE) -C $$subdir $@; \
|
|
20 done
|
|
21
|
|
22 distclean: clean
|
|
23 for subdir in $(SUBDIRS); do \
|
|
24 $(MAKE) -C $$subdir $@; \
|
|
25 done
|
|
26 -$(RM) -f config.log
|
|
27 -$(RM) -f config.mak
|
|
28 -$(RM) -f config.h
|
|
29
|
|
30
|
|
31 install:
|
|
32 for subdir in $(SUBDIRS); do \
|
|
33 $(MAKE) -C $$subdir $@; \
|
|
34 done
|
|
35
|
|
36 .PHONY: clean distclean install
|
|
37
|
|
38 dist:
|
|
39 -$(RM) $(DISTFILE)
|
|
40 dist=$(shell pwd)/recpt1-$(VERSION) && \
|
|
41 for subdir in . $(SUBDIRS); do \
|
|
42 mkdir -p "$$dist/$$subdir"; \
|
|
43 $(MAKE) -C $$subdir dist-all DIST="$$dist/$$subdir"; \
|
|
44 done && \
|
|
45 tar cjf $(DISTFILE) recpt1-$(VERSION)
|
|
46 -$(RM) -rf recpt1-$(VERSION)
|
|
47
|
|
48 dist-all:
|
|
49 cp $(SRCS) Makefile $(DIST)
|
|
50
|
|
51 .PHONY: dist dist-all
|