File: rules

package info (click to toggle)
iwidgets4 4.0.1-3
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k, sarge
  • size: 4,244 kB
  • ctags: 17
  • sloc: tcl: 19,633; sh: 666; awk: 273; perl: 265; makefile: 159
file content (83 lines) | stat: -rwxr-xr-x 1,803 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
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
#!/usr/bin/make -f

v = 4.0
vv = 4.0.1
tcltk = 8.4
itcl = 3.2
dtmp=$(shell pwd)/debian/tmp

build: build-stamp
build-stamp:
	dh_testdir

	chmod u+x mkinstalldirs	# dpkg-source isn't very smart...
	sh ./configure --prefix=/usr --with-tcl=/usr/lib/tcl$(tcltk) \
	  --with-tk=/usr/lib/tk$(tcltk) --with-itcl=/usr/lib/itcl$(itcl)

	touch build-stamp

clean:
	dh_testdir
	dh_testroot
	rm -f build-stamp install-stamp

	-$(MAKE) clean
	-$(MAKE) distclean

	dh_clean

install: install-stamp
install-stamp: build-stamp
	dh_testdir
	dh_testroot
	dh_clean -k
	dh_installdirs

	mkdir -p $(dtmp)
	$(MAKE) INSTALL_ROOT=$(dtmp) \
		MAN_INSTALL_DIR=$(dtmp)/usr/share/man/man3 install
# remove redundant license file
	rm -f $(dtmp)/usr/lib/iwidgets$(vv)/license.terms

# Fix up the manpages.
	cd $(dtmp)/usr/share/man/man3 && \
	  for i in *.n; do \
	    mv $$i `basename $$i .n`.3iwidget; \
	  done

# Fix up the demos
	mkdir -p $(dtmp)/usr/share/iwidgets$(vv)/demos
	mv $(dtmp)/usr/lib/iwidgets$(vv)/demos/images \
		$(dtmp)/usr/share/iwidgets$(vv)/demos/images
	chmod -x $(dtmp)/usr/lib/iwidgets$(vv)/demos/*
	ln -s ../../../share/iwidgets$(vv)/demos/images \
		$(dtmp)/usr/lib/iwidgets$(vv)/demos/images

	dh_movefiles

	touch install-stamp

# Build architecture-independent files here.
binary-indep: build install
	dh_testdir
	dh_testroot
	dh_installdocs
	dh_installchangelogs ChangeLog
	#dh_installexamples
	ln -s ../../../lib/iwidgets$(vv)/demos \
		debian/iwidgets4/usr/share/doc/iwidgets4/examples
	dh_compress
	dh_fixperms
	dh_installdeb
	dh_gencontrol
	dh_md5sums
	dh_builddeb

# no arch-dependent packages to build.
binary-arch:

source diff:
	@echo >&2 'source and diff are obsolete - use dpkg-source -b'; false

binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary install