File: Makefile

package info (click to toggle)
tophide 1.0.3-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 92 kB
  • ctags: 27
  • sloc: ml: 83; makefile: 82
file content (44 lines) | stat: -rw-r--r-- 1,301 bytes parent folder | download
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
# Copyright 2008 Martin Jambon. All rights reserved.
# This file is distributed under the terms stated in file LICENSE.

VERSION = 1.0.3
export VERSION

.PHONY: all install clean

all: META tophide.cmo
tophide.cmo: tophide.ml
	ocamlc -I +compiler-libs -c tophide.ml

install:
	ocamlfind install tophide META tophide.cmi tophide.cmo tophide.ml

uninstall:
	ocamlfind remove tophide

clean:
	rm -f *.cmo *.cmi

META: META.in Makefile
	cat META.in > META
	echo 'version = "$(VERSION)"' >> META

archive:
	rm -rf /tmp/tophide /tmp/tophide-$(VERSION) && \
	 	cp -r . /tmp/tophide && \
		cd /tmp/tophide && \
			$(MAKE) clean && \
			$(MAKE) META && \
			rm -f *~ tophide*.tar* && \
		cd /tmp && cp -r tophide tophide-$(VERSION) && \
		tar czf tophide.tar.gz tophide && \
		tar cjf tophide.tar.bz2 tophide && \
		tar czf tophide-$(VERSION).tar.gz tophide-$(VERSION) && \
		tar cjf tophide-$(VERSION).tar.bz2 tophide-$(VERSION)
	mv /tmp/tophide.tar.gz /tmp/tophide.tar.bz2 ..
	mv /tmp/tophide-$(VERSION).tar.gz /tmp/tophide-$(VERSION).tar.bz2 ..
	cp ../tophide.tar.gz ../tophide.tar.bz2 $$WWW/
	cp ../tophide-$(VERSION).tar.gz ../tophide-$(VERSION).tar.bz2 $$WWW/
	cp README $$WWW/tophide-readme.txt
	cp LICENSE $$WWW/tophide-license.txt
	echo 'let tophide_version = "$(VERSION)"' > $$WWW/tophide-version.ml