~ubuntu-branches/ubuntu/oneiric/sbuild/oneiric

« back to all changes in this revision

Viewing changes to debian/rules

  • Committer: Bazaar Package Importer
  • Author(s): Lorenzo De Liso
  • Date: 2011-05-01 16:55:16 UTC
  • mfrom: (8.1.19 upstream) (3.3.17 sid)
  • Revision ID: james.westby@ubuntu.com-20110501165516-8g3uwrnhv2bzjt8y
Tags: 0.62.2-1ubuntu1
* Merge from debian unstable, remaining changes:
  - debian/patches/do-not-install-debfoster-into-chroots.patch: 
    do not install debfoster into the chroots because it is in universe and 
    not needed for package building itself.
  - debian/patches/run-pre-build-hooks-as-root.patch: 
    run pre-build hooks as root (Closes: #607228)
* Now that the package uses a patch system, don't modify the files directly;
  instead, put the changes in the respective patches and add the DEP-3
  patch tagging guidelines to them.

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
# Uncomment this to turn on verbose mode.
4
4
#export DH_VERBOSE=1
5
5
 
 
6
VERSION=$(shell dpkg-parsechangelog | grep '^Version:' | cut -d' ' -f 2)
 
7
BUILDD_BUILD=$(shell echo ${VERSION} | grep -q 'buildd' && echo yes || echo no)
 
8
 
6
9
debian/build/config.status: configure
7
10
        dh_testdir
8
11
 
11
14
        cd debian/build; \
12
15
        CFLAGS="$(CFLAGS)" ../../configure \
13
16
          --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) \
14
 
          --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/share \
 
17
          --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib \
15
18
          --localstatedir=/var --mandir=\$${prefix}/share/man
16
19
 
17
 
 
 
20
build-indep: build
 
21
build-arch: build
18
22
build: debian/build/config.status debian/build-stamp
19
23
debian/build-stamp:  debian/build/config.status
20
24
        dh_testdir
33
37
 
34
38
        dh_clean
35
39
 
 
40
install-indep: install
 
41
install-arch: install
36
42
install: build
37
43
        dh_testdir
38
44
        dh_testroot
42
48
        $(MAKE) -C debian/build install DESTDIR=$(CURDIR)/debian/install
43
49
 
44
50
        dh_install
 
51
 
45
52
        cp debian/buildd.forward debian/buildd/var/lib/buildd/.forward
46
53
 
 
54
        mkdir -p $(CURDIR)/debian/sbuild/usr/share/lintian/overrides
 
55
        cp $(CURDIR)/debian/sbuild.lintian-overrides $(CURDIR)/debian/sbuild/usr/share/lintian/overrides/sbuild
 
56
 
47
57
# Build architecture-independent files here.
48
 
binary-indep: build install
 
58
binary-indep: build install-indep
49
59
        dh_testdir -i
50
60
        dh_testroot -i
51
61
        dh_installchangelogs -i ChangeLog
53
63
        dh_installexamples -i
54
64
        dh_installman -i
55
65
        dh_installcron -i
56
 
        dh_installinit -i --no-start --no-restart-on-upgrade
 
66
        if [ "${BUILDD_BUILD}" = "no" ]; then \
 
67
          dh_installinit -i --no-start --no-restart-on-upgrade; \
 
68
        fi
57
69
        dh_perl -i
58
70
        dh_link -i
59
71
        dh_compress -i
70
82
        dh_builddeb -i
71
83
 
72
84
# Build architecture-dependent files here.
73
 
binary-arch: build install
 
85
binary-arch: build install-arch
 
86
        dh_testdir -a
 
87
        dh_testroot -a
 
88
        dh_installchangelogs -a ChangeLog
 
89
        dh_installdocs -a -A debian/cvslogs.old
 
90
        dh_installexamples -a
 
91
        dh_installman -a
 
92
        dh_installinit -a --no-start --no-restart-on-upgrade
 
93
        dh_perl -a
 
94
        dh_link -a
 
95
        dh_strip -a
 
96
        dh_compress -a
 
97
        dh_fixperms -a
 
98
        chmod 4755 $(CURDIR)/debian/sbuild/usr/lib/sbuild/sbuild-schroot
 
99
        dh_makeshlibs -a
 
100
        dh_installdeb -a
 
101
        dh_shlibdeps -a
 
102
        dh_gencontrol -a
 
103
        dh_md5sums -a
 
104
        dh_builddeb -a
74
105
 
75
106
binary: binary-indep binary-arch
76
 
.PHONY: build clean binary-indep binary-arch binary install
 
107
.PHONY: build build-indep build-arch clean binary-indep binary-arch binary install install-indep install-arch