~ubuntu-branches/ubuntu/natty/libtext-autoformat-perl/natty

« back to all changes in this revision

Viewing changes to debian/rules

  • Committer: Bazaar Package Importer
  • Author(s): gregor herrmann
  • Date: 2008-03-06 18:20:51 UTC
  • mfrom: (1.1.3 upstream) (4.1.1 hardy)
  • Revision ID: james.westby@ubuntu.com-20080306182051-0tcj7rqxsw4p5kx8
Tags: 1.14.0-1
* debian/control: Added: Vcs-Svn field (source stanza); Vcs-Browser
  field (source stanza); Homepage field (source stanza). Removed: XS-
  Vcs-Svn fields.
* debian/rules: delete /usr/lib/perl5 only if it exists (closes: #468013).
* debian/watch: use dist-based URL.

* New upstream release.
* debian/copyright: add specific upstream source location, about years of
  copyright, license wording, and references to license file on Debian
  systems.
* Set Standards-Version to 3.7.3 (no changes).
* debian/rules: update with dh-make-perl's help.
* Drop debian/libtext-autoformat-perl.*: don't install README anymore;
  handle examples from debian/rules.
* debian/control: add libversion-perl to Build-Depends-Indep, add /me to
  Uploaders.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#!/usr/bin/make -f
2
 
## ----------------------------------------------------------------------
3
 
## debian/rules : package script for libtext-autoformat-perl
4
 
## ----------------------------------------------------------------------
 
2
# This debian/rules file is provided as a template for normal perl
 
3
# packages. It was created by Marc Brockschmidt <marc@dch-faq.de> for
 
4
# the Debian Perl Group (http://pkg-perl.alioth.debian.org/) but may
 
5
# be used freely wherever it is useful.
5
6
 
6
 
## ----------------------------------------------------------------------
7
 
## uncomment this to turn on verbose mode
 
7
# Uncomment this to turn on verbose mode.
8
8
#export DH_VERBOSE=1
9
9
 
10
 
## ----------------------------------------------------------------------
 
10
# If set to a true value then MakeMaker's prompt function will
 
11
# always return the default without waiting for user input.
 
12
export PERL_MM_USE_DEFAULT=1
 
13
 
11
14
PACKAGE=$(shell dh_listpackages)
 
15
 
 
16
ifndef PERL
 
17
PERL = /usr/bin/perl
 
18
endif
 
19
 
12
20
TMP     =$(CURDIR)/debian/$(PACKAGE)
13
21
 
14
 
## ----------------------------------------------------------------------
15
 
## targets
 
22
build: build-stamp
 
23
build-stamp:
 
24
        dh_testdir
 
25
 
 
26
        $(PERL) Makefile.PL INSTALLDIRS=vendor
 
27
        $(MAKE)
 
28
        $(MAKE) test
 
29
 
 
30
        touch $@
16
31
 
17
32
clean:
18
 
                dh_testdir
19
 
                dh_testroot
20
 
                [ ! -f Makefile ] || $(MAKE) realclean
21
 
                dh_clean
22
 
                rm -f build-stamp install-stamp
23
 
 
24
 
build:          build-stamp
25
 
build-stamp:
26
 
                dh_testdir
27
 
                perl Makefile.PL INSTALLDIRS=vendor
28
 
                $(MAKE) OPTIMIZE="-O2 -g -Wall"
29
 
                $(MAKE) test
30
 
                touch build-stamp
31
 
 
32
 
install:        install-stamp
33
 
install-stamp:  build
34
 
                dh_testdir
35
 
                dh_testroot
36
 
                dh_clean -k
37
 
                dh_installdirs
38
 
                $(MAKE) install DESTDIR=$(TMP) PREFIX=/usr
39
 
                #As this is a architecture independent package, we are not supposed to install
40
 
                #stuff to /usr/lib. MakeMaker creates the dirs, we delete them from the deb:
41
 
                rmdir --ignore-fail-on-non-empty --parents $(TMP)/usr/lib/perl5
42
 
                touch install-stamp
43
 
 
44
 
binary-indep:   build install
45
 
                dh_testdir
46
 
                dh_testroot
47
 
                dh_installdocs
48
 
                dh_installexamples
49
 
                dh_installchangelogs Changes
50
 
                dh_compress
51
 
                dh_fixperms
52
 
                chmod 644 $(TMP)/usr/share/doc/$(PACKAGE)/examples/*
53
 
                dh_installdeb
54
 
                dh_perl
55
 
                dh_gencontrol
56
 
                dh_md5sums
57
 
                dh_builddeb
 
33
        dh_testdir
 
34
        dh_testroot
 
35
 
 
36
        dh_clean build-stamp install-stamp
 
37
        [ ! -f Makefile ] || $(MAKE) realclean
 
38
 
 
39
install: install-stamp
 
40
install-stamp: build-stamp
 
41
        dh_testdir
 
42
        dh_testroot
 
43
        dh_clean -k
 
44
 
 
45
        $(MAKE) install DESTDIR=$(TMP) PREFIX=/usr
 
46
        [ ! -d $(TMP)/usr/lib/perl5 ] || rmdir --ignore-fail-on-non-empty --parents --verbose $(TMP)/usr/lib/perl5
 
47
 
 
48
        touch $@
58
49
 
59
50
binary-arch:
60
 
 
61
 
binary:         binary-indep binary-arch
62
 
 
63
 
.PHONY:         clean build install binary-indep binary-arch binary
64
 
 
65
 
## ----------------------------------------------------------------------
 
51
# We have nothing to do here for an architecture-independent package
 
52
 
 
53
binary-indep: build install
 
54
        dh_testdir
 
55
        dh_testroot
 
56
 
 
57
        dh_installexamples config.emacs config.vim
 
58
        # no exec bit on samples
 
59
        chmod 644 $(TMP)/usr/share/doc/$(PACKAGE)/examples/*
 
60
 
 
61
        dh_installdocs
 
62
        dh_installchangelogs Changes
 
63
        dh_perl
 
64
        dh_compress
 
65
        dh_fixperms
 
66
        dh_installdeb
 
67
        dh_gencontrol
 
68
        dh_md5sums
 
69
        dh_builddeb
 
70
 
 
71
source diff:
 
72
        @echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
 
73
 
 
74
binary: binary-indep binary-arch
 
75
.PHONY: build clean binary-indep binary-arch binary