File: rules

package info (click to toggle)
sgmlspm 1.03ii-14
  • links: PTS
  • area: main
  • in suites: potato
  • size: 600 kB
  • ctags: 157
  • sloc: perl: 1,387; lisp: 262; makefile: 207
file content (121 lines) | stat: -rwxr-xr-x 3,511 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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
#!/usr/bin/make -f
## ----------------------------------------------------------------------
## debian/rules : package build and install script for sgmlspm
## ----------------------------------------------------------------------
## Copyright 1994,1995 by Ian Jackson.
## I hereby give you perpetual unlimited permission to copy,
## modify and relicense this file, provided that you do not remove
## my name from the file itself.  (I assert my moral right of
## paternity under the Copyright, Designs and Patents Act 1988.)
## ----------------------------------------------------------------------

## ----------------------------------------------------------------------
## uncomment this to turn on verbose mode
#export DH_VERBOSE=1

## ----------------------------------------------------------------------
## TMP settings
LIBTMP	= `pwd`/debian/tmp
BINTMP	= `pwd`/debian/sgmlspl
DOCTMP	= `pwd`/debian/sgmls-doc

## ----------------------------------------------------------------------
## perl settings
ifndef PERL
PERL	= /usr/bin/perl
endif
archlib	= `${PERL} -MConfig -e 'print $$Config{installarchlib}'`
config	= INSTALLDIRS=perl \
	  INSTALLMAN1DIR=${LIBTMP}/usr/share/man/man1 \
	  INSTALLMAN3DIR=${LIBTMP}/usr/share/man/man3 \
	  INSTALLPRIVLIB=${LIBTMP}/usr/lib/perl5 \
	  INSTALLARCHLIB=${LIBTMP}/${archlib} \
	  INSTALLBIN=$(LIBTMP)/usr/bin \
	  INSTALLSCRIPT=$(LIBTMP)/usr/bin \

## ----------------------------------------------------------------------
## targets
build:

		dh_testdir
		${PERL} Makefile.PL ${config}
		$(MAKE) OPTIMIZE="-O2 -g -Wall"

clean:

		dh_testdir
		dh_testroot
		-$(MAKE) realclean
		dh_clean

binary-indep:	build

		# create the libsgmls-perl package
		dh_testdir
		dh_testroot
		dh_clean -k
		dh_installdirs
		$(MAKE) pure_install
		chmod -R go=rX,u+wX ${LIBTMP}
		dh_installmanpages sgmlspl.1
		dh_installdocs BUGS TODO
		chmod a+x DOC/sample.pl
		dh_installexamples DOC/sample.pl
		dh_installchangelogs ChangeLog
		dh_compress
		dh_fixperms
		dh_installdeb
		dh_perl
		dh_gencontrol
		dh_md5sums
		dh_builddeb

		# create the sgmlspl package
		dh_testdir
		dh_testroot
		dh_clean -k
		dh_installdirs -psgmlspl usr/bin usr/lib/perl5/sgmlspl-specs
		cp -a sgmlspl.pl ${BINTMP}/usr/bin/sgmlspl
		cp -a skel.pl ${BINTMP}/usr/lib/perl5/sgmlspl-specs
		dh_installmanpages -psgmlspl \
		    SGMLS.3pm SGMLS::Output.3pm SGMLS::Refs.3pm
		dh_installdocs -psgmlspl
		dh_installchangelogs -psgmlspl ChangeLog
		dh_compress -psgmlspl
		dh_fixperms -psgmlspl
		dh_installdeb -psgmlspl
		dh_perl -psgmlspl
		dh_gencontrol -psgmlspl
		dh_md5sums -psgmlspl
		dh_builddeb -psgmlspl

		# create the sgmls-doc package
		dh_testdir
		dh_testroot
		dh_clean -k
		dh_installdirs -psgmls-doc
		dh_installdocs -psgmls-doc DOC/HTML/SGMLSpm DOC/HTML/sgmlspl
		ln -s sgmlspm.html \
		    ${DOCTMP}/usr/share/doc/sgmls-doc/SGMLSpm/index.html
		ln -s sgmlspl.html \
		    ${DOCTMP}/usr/share/doc/sgmls-doc/sgmlspl/index.html
		cp debian/SGMLSpm.dhelp \
		    ${DOCTMP}/usr/share/doc/sgmls-doc/SGMLSpm/.dhelp
		cp debian/sgmlspl.dhelp \
		    ${DOCTMP}/usr/share/doc/sgmls-doc/sgmlspl/.dhelp
		dh_installchangelogs -psgmls-doc ChangeLog
		dh_compress -psgmls-doc
		dh_fixperms -psgmls-doc
		dh_installdeb -psgmls-doc
		dh_perl -psgmls-doc
		dh_gencontrol -psgmls-doc
		dh_md5sums -psgmls-doc
		dh_builddeb -psgmls-doc

binary-arch:

binary:		binary-indep binary-arch

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

## ----------------------------------------------------------------------