1 | # compile task doesn't compile sources, but just copy some files |
---|
2 | # this should be changed |
---|
3 | # |
---|
4 | |
---|
5 | # I put here some variables |
---|
6 | |
---|
7 | # path, where binaries are placed |
---|
8 | # (they will be processed for making distribution) |
---|
9 | export _UTT_DIST_DIR=$(shell pwd)/bin |
---|
10 | # path, where distribution file should be placed |
---|
11 | export _UTT_DIST_OUTPUT=$(shell pwd) |
---|
12 | |
---|
13 | |
---|
14 | # ----------------------------------------------------------- |
---|
15 | # default task should display options |
---|
16 | .PHONY: default |
---|
17 | defaul: |
---|
18 | @echo "Using: make compile|tarball|rpm|deb" |
---|
19 | |
---|
20 | |
---|
21 | # ----------------------------------------------------------- |
---|
22 | # ----------------------------------------------------------- |
---|
23 | # this task should compile utt application |
---|
24 | .PHONY: compile |
---|
25 | compile: |
---|
26 | if test -d ${_UTT_DIST_DIR}; then rm -fr ${_UTT_DIST_DIR}; fi |
---|
27 | mkdir -p ${_UTT_DIST_DIR} |
---|
28 | @# fake compilation |
---|
29 | cp -r ../utt-0.9/* ${_UTT_DIST_DIR}/ |
---|
30 | @# we add some extra file (required during instalation) |
---|
31 | cp common/create_utt_config.pl ${_UTT_DIST_DIR}/ |
---|
32 | chmod 700 ${_UTT_DIST_DIR}/create_utt_config.pl |
---|
33 | |
---|
34 | |
---|
35 | # ----------------------------------------------------------- |
---|
36 | # this task should compile utt (if nesessery) and create tar.gz version |
---|
37 | .PHONY: tarball |
---|
38 | tarball: compile |
---|
39 | cd tarball && make |
---|
40 | |
---|
41 | # ----------------------------------------------------------- |
---|
42 | # this task should compile utt (if nesessery) and create rpm version |
---|
43 | .PHONY: rpm |
---|
44 | rpm: compile |
---|
45 | @#we build rpm (see spec/README for details) |
---|
46 | cd spec && make |
---|
47 | |
---|
48 | # ----------------------------------------------------------- |
---|
49 | # this task should compile utt (if nesessery) and create deb version |
---|
50 | .PHONY: deb |
---|
51 | deb: compile |
---|
52 | @#we build deb (see deb/README for details) |
---|
53 | cd deb && make |
---|
54 | |
---|
55 | # ----------------------------------------------------------- |
---|
56 | # this task should remove compiled files and directories |
---|
57 | .PHONY: clean |
---|
58 | clean: |
---|
59 | # finally the line below should be uncomment |
---|
60 | rm -fr ${_UTT_DIST_DIR} |
---|
61 | |
---|