forked from debinix/openjensen
-
Notifications
You must be signed in to change notification settings - Fork 0
/
makefile
84 lines (63 loc) · 2.25 KB
/
makefile
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
#############################################################
# Do not edit. Managed by Puppet. Changes will be wiped out.#
#############################################################
#
# Project: openjensen
#
# Top Makefile (recurs down in source directories)
#
#############################################################################
# -- EXTERNAL SHELL VARIABLES
#############################################################################
QUIET = @
ECHO := /bin/echo
CP := /bin/cp
MKDIR := mkdir -p
TAR := /bin/tar
GZIP := /bin/gzip
RMDIR := /bin/rm -fr
#############################################################################
# -- INTERNAL VARIABLES
#############################################################################
GZIPOPT = -9 -c
TAROPT = chof -
package = openjensen
version = 0.$(shell date +%Y%m%d.%H%M)
tarname = $(package)
distdir = /home/bekr/$(tarname)-$(version)
#############################################################################
# 1 -- MAKE ALL, BUILD, DIST, CLEAN, CLEANALL
#############################################################################
all clean cleanall build:
cd src && $(MAKE) $@
cd lib && $(MAKE) $@
cd html && $(MAKE) $@
dist: $(distdir).tar.gz
$(distdir).tar.gz : $(distdir)
$(QUIET) - $(TAR) $(TAROPT) $(distdir) | $(GZIP) $(GZIPOPT) > $@
$(QUIET) - $(RMDIR) $(distdir)
$(QUIET) $(ECHO) [makefile]: Archive $(distdir).tar.gz created
$(distdir):
$(QUIET) $(MKDIR) $(distdir)
$(QUIET) - $(CP) makefile $(distdir)
#
$(QUIET) $(MKDIR) $(distdir)/src
$(QUIET) - $(CP) src/makefile $(distdir)/src/.
$(QUIET) - $(CP) src/*.cbl $(distdir)/src/.
#
$(QUIET) $(MKDIR) $(distdir)/lib
$(QUIET) - $(CP) lib/makefile $(distdir)/lib/.
$(QUIET) - $(CP) lib/*.cbl $(distdir)/lib/.
#
$(QUIET) $(MKDIR) $(distdir)/copy
$(QUIET) - $(CP) copy/*.cbl $(distdir)/copy/.
$(QUIET) - $(CP) copy/*.cpy $(distdir)/copy/.
#
$(QUIET) $(MKDIR) $(distdir)/html
$(QUIET) - $(CP) html/*.html $(distdir)/html/.
$(QUIET) - $(CP) html/*.png $(distdir)/html/.
$(QUIET) - $(CP) html/*.js $(distdir)/html/.
#############################################################################
# 2 -- PHONY TARGETS
#############################################################################
.PHONY: all clean cleanall build dist