-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmakefile
More file actions
82 lines (68 loc) · 2.52 KB
/
Copy pathmakefile
File metadata and controls
82 lines (68 loc) · 2.52 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
# Version - these values are mastered here and overwrite the generated values in makefiles for Debug and Release
APPNAME = bluescsiui
BINNAME = bsui
VERSIONMAJOR = 1
VERSIONMINOR = 2
DEVDATE = "23.02.2026"
RELEASEDIR = Release
DEBUGDIR = Debug
RELEASE = $(RELEASEDIR)/makefile
DEBUG = $(DEBUGDIR)/makefile
TEMPLATEMAKEFILE = makefile.master
# optimised and release version
PRODCOPTS = OPTIMIZE Optimizerinline OptimizerComplexity=10 OptimizerGlobal OptimizerDepth=1 OptimizerTime OptimizerSchedule OptimizerPeephole PARAMETERS=stack
# debug version build options
DBGCOPTS = DEFINE=_DEBUG DEFINE=DEBUG_SERIAL debug=full
all: $(RELEASE) $(DEBUG) lib
execute <<
cd $(RELEASEDIR)
smake VERSIONMAJOR=$(VERSIONMAJOR) VERSIONMINOR=$(VERSIONMINOR) DEVDATE=$(DEVDATE) APPNAME=$(APPNAME) BINNAME=$(BINNAME)
cd /
<
execute <<
cd $(DEBUGDIR)
smake VERSIONMAJOR=$(VERSIONMAJOR) VERSIONMINOR=$(VERSIONMINOR) DEVDATE=$(DEVDATE) APPNAME=$(APPNAME) BINNAME=$(BINNAME)
cd /
<
lib: $(APPNAME).lha
install: $(APPNAME).lha
copy $(APPNAME)/$(BINNAME) C:
clean:
execute <<
cd $(RELEASEDIR)
smake clean
cd /
<
execute <<
cd $(DEBUGDIR)
smake clean
cd /
<
- delete $(APPNAME).lha $(APPNAME)/$(BINNAME)
$(RELEASE): $(TEMPLATEMAKEFILE) makefile
copy $(TEMPLATEMAKEFILE) $(RELEASE)
splat -o "^SCOPTS.+\$" "SCOPTS = $(PRODCOPTS)" $(RELEASE)
splat -o "^BINNAME.+\$" "BINNAME = $(BINNAME)" $(RELEASE)
splat -o "^VERSIONMAJOR.+\$" "VERSIONMAJOR = $(VERSIONMAJOR)" $(RELEASE)
splat -o "^VERSIONMINOR.+\$" "VERSIONMINOR = $(VERSIONMINOR)" $(RELEASE)
# splat -o "^DEVDATE.+\$" "DEVDATE = $(DEVDATE)" $(RELEASE)
splat -o "^BUILD.+\$" "BUILD = Release" $(RELEASE)
splat -o "^APPNAME.+\$" "APPNAME = $(APPNAME)" $(RELEASE)
$(DEBUG): $(TEMPLATEMAKEFILE) makefile
copy $(TEMPLATEMAKEFILE) $(DEBUG)
splat -o "^SCOPTS.+\$" "SCOPTS = $(DBGCOPTS)" $(DEBUG)
splat -o "^BINNAME.+\$" "BINNAME = $(BINNAME)" $(DEBUG)
splat -o "^VERSIONMAJOR.+\$" "VERSIONMAJOR = $(VERSIONMAJOR)" $(DEBUG)
splat -o "^VERSIONMINOR.+\$" "VERSIONMINOR = $(VERSIONMINOR)" $(DEBUG)
# splat -o "^DEVDATE.+\$" "DEVDATE = $(DEVDATE)" $(DEBUG)
splat -o "^BUILD.+\$" "BUILD = Debug" $(DEBUG)
splat -o "^APPNAME.+\$" "APPNAME = $(APPNAME)" $(DEBUG)
$(APPNAME).lha: $(RELEASE) $(APPNAME)/$(BINNAME) $(APPNAME)/$(APPNAME).readme
lha -Qr -x u $(APPNAME).lha $(APPNAME)
$(APPNAME)/$(APPNAME).readme:
$(APPNAME)/$(BINNAME):
execute <<
cd $(RELEASEDIR)
smake lib VERSIONMAJOR=$(VERSIONMAJOR) VERSIONMINOR=$(VERSIONMINOR) DEVDATE=$(DEVDATE) APPNAME=$(APPNAME) BINNAME=$(BINNAME)
cd /
<