summaryrefslogtreecommitdiffstats
path: root/ds9/make.include
blob: 0cb8da58a64c75902fa5c3dcdab039839fecc510 (plain)
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
#--------------------------parsers

vpath %.tac $(prefix)/ds9/parsers
vpath %.fcl $(prefix)/ds9/parsers

$(prefix)/ds9/parsers/%parser.tcl : %parser.tac
	tclsh $(prefix)/taccle/taccle.tcl -p $* -d -v -w $<

$(prefix)/ds9/parsers/%lex.tcl : %lex.fcl
	tclsh $(prefix)/fickle/fickle.tcl -P $* $<


#--------------------------library

PARSERS = \
	$(prefix)/ds9/parsers/zoomparser.tcl \
	$(prefix)/ds9/parsers/zoomparser.tab.tcl \
	$(prefix)/ds9/parsers/zoomlex.tcl \
	$(prefix)/ds9/parsers/panparser.tcl \
	$(prefix)/ds9/parsers/panparser.tab.tcl \
	$(prefix)/ds9/parsers/panlex.tcl

#PARSERS = \
#	$(wildcard $(prefix)/ds9/library/*parser.tcl) \
#	$(wildcard $(prefix)/ds9/library/*parser.tab.tcl) \
#	$(wildcard $(prefix)/ds9/library/*lex.tcl)

$(LIBDIR)/library : $(PARSERS) $(prefix)/ds9/library/*.tcl
	mkdir -p "$@"
	cp -prf $? "$@"
# must do it this way for win
	cd "$@"; \
	echo "pkg_mkIndex . *.tcl; exit" | tclsh
	touch "$@"

#--------------------------support

$(LIBDIR)/msgs : $(prefix)/ds9/msgs
	cp -prf $? "$@"

$(LIBDIR)/doc : $(prefix)/ds9/doc
	cp -prf $? "$@"

$(LIBDIR)/cmaps : $(prefix)/ds9/cmaps
	cp -prf $? "$@"

$(LIBDIR)/template : $(prefix)/ds9/template
	cp -prf $? "$@"

#--------------------------tls

$(LIBDIR)/tls	: $(prefix)/tls/tls.tcl
	mkdir -p "$@"
	cp -prf $? "$@"
# must do it this way for win
	cd "$@"; \
	echo "pkg_mkIndex . *.tcl; exit" | tclsh

#--------------------------tkblt

$(LIBDIR)/tkblt	: $(prefix)/tkblt/library/*.tcl
	mkdir -p "$@"
	cp -p $? "$@"
# must do it this way for win
	cd "$@"; \
	echo "pkg_mkIndex . *.tcl; exit" | tclsh

#--------------------------tkcon

$(LIBDIR)/tkcon	: $(prefix)/tkcon
	cp -prf $? "$@"
# must do it this way for win
	cd "$@"; \
	echo "pkg_mkIndex . *.tcl; exit" | tclsh

#--------------------------tcllib

$(LIBDIR)/base64: $(prefix)/tcllib/modules/base64
	cp -prf $? "$@"

$(LIBDIR)/ftp	: $(prefix)/tcllib/modules/ftp
	cp -prf $? "$@"

$(LIBDIR)/log	: $(prefix)/tcllib/modules/log
	cp -prf $? "$@"

$(LIBDIR)/textutil: $(prefix)/tcllib/modules/textutil
	cp -prf $? "$@"

$(LIBDIR)/math	: $(prefix)/tcllib/modules/math
	cp -prf $? "$@"

#--------------------------distclean

.PHONY	: distclean

distclean: clean
	-rm -f Makefile config.cache config.log config.status
	-rm -rf $(prefix)/ds9/parsers/*.tcl $(prefix)/ds9/parsers/*.out
	-rm -rf autom4te.cache