-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
83 lines (59 loc) · 1.85 KB
/
Copy pathMakefile
File metadata and controls
83 lines (59 loc) · 1.85 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
# This GNU Makefile is mainly for setup, running tests, and producing
# doc files. After running make once, running the build tools of the
# respective compilers should be sufficient.
# For GNAT, there is a GNAT project file.
# If you have ObjectAda, see Makefile.OA.
# how to remove a file
delete = del /q
#delete = rm -f
dirsep=\\
#dirsep=/
exe=.exe
ADAC = GNAT
FLAVOR = Tricks
# "Plain" or "Tricks". See file "asnip.gpr".
all: $(ADAC)
#all: $(ADAC) test
################################################################
export delete exe dirsep
test: $(ADAC) force test/asnip-testing.bdy vartest
$(MAKE) -C test
vartest:
@echo > xxx.xxx
@echo "----------------------------------------------------------------"
@echo "Does the file deletion command, $(delete), work?"
@echo "Be sure to adjust the Makefile as explained in README.txt"
@echo "----------------------------------------------------------------"
$(delete) xxx.xxx
.PHONY: force clean $(ADAC) test vartest GNAT RELEASE
obj:
-mkdir obj
doc: force
xmlto -o doc html-nochunks asnip.xml
xmlto -o doc man asnip.xml
# splitting a file with both spec and body in it so GNAT can process them:
spec-and-body = asnip-support binary_search
chopped = $(foreach name,$(spec-and-body),obj/$(name).ads obj/$(name).adb)
obj/%.ads obj/%.adb: %.ada
gnatchop -r -w $< obj
GNAT: obj $(chopped)
gnatmake -Pasnip -XFLAVOR=$(FLAVOR)
force:
clean:
-$(delete) obj$(dirsep)*
-$(delete) doc$(dirsep)asnip.l
-$(delete) doc$(dirsep)asnip.html
$(MAKE) -C test rmtestfiles
################
# Making a distribution zip
NAME = ASnip
# Name of project, and of project directory
REL = test3
# Major version identifier
# Each release needs a differen realease identifier!
export NAME REL
RELEASE:
$(MAKE) -C dist -f Makefile.dist zip binzip
echo RELEASED >RELEASE
distclean: clean
$(MAKE) -C dist -f Makefile.dist clean