~ubuntu-branches/ubuntu/precise/enigmail/precise-updates

« back to all changes in this revision

Viewing changes to debian/rules

  • Committer: Package Import Robot
  • Author(s): Chris Coulson
  • Date: 2012-11-12 16:36:01 UTC
  • mfrom: (0.12.15)
  • Revision ID: package-import@ubuntu.com-20121112163601-t8e8skdfi3ni9iqp
Tags: 2:1.4.6-0ubuntu0.12.04.1
* New upstream release v1.4.6
  - see LP: #1080212 for USN information
* Drop unneeded patches
  - remove debian/patches/correct-version-number.diff
  - remove debian/patches/dont_register_cids_multiple_times.diff
  - update debian/patches/series
* Support building in an objdir
  - update debian/rules

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#!/usr/bin/make -f
2
2
 
3
 
#BUILDDIR = $(CURDIR)/objdir-enigmail
4
 
BUILDDIR = $(CURDIR)
5
 
 
6
 
CXXFLAGS+=-std=gnu++0x -fshort-wchar
7
 
 
 
3
BUILDDIR = $(CURDIR)/objdir-enigmail
8
4
DEB_BUILD_GNU_TYPE := $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
9
5
 
10
 
TBIRD_SDK = $(shell ls -d /usr/lib/thunderbird-devel* /usr/lib/icedove-devel* 2> /dev/null | head -n1)
11
 
 
12
 
#CONFIGFLAGS = --with-system-nspr --with-nspr-prefix=/usr
 
6
CONFIGFLAGS =   --target=$(DEB_BUILD_GNU_TYPE) \
 
7
                --with-libxul-sdk=/usr/lib/thunderbird-devel \
 
8
                --enable-application=extensions \
 
9
                --enable-extensions=enigmail \
 
10
                --enable-chrome-format=omni \
 
11
                $(NULL)
13
12
 
14
13
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
15
 
CONFIGFLAGS +=  --disable-optimize
 
14
CONFIGFLAGS +=  --disable-optimize
16
15
endif
17
16
 
18
 
 
19
17
%:
20
 
#       dh --with quilt --with xul-ext --builddirectory=$(BUILDDIR) $@
21
18
        dh --with quilt --with xul-ext $@
22
19
 
23
20
override_dh_auto_configure:
24
21
        mkdir -p $(BUILDDIR)
25
22
        autoconf2.13
26
 
        cd $(BUILDDIR); $(CURDIR)/configure --target=$(DEB_BUILD_GNU_TYPE) --with-libxul-sdk=$(TBIRD_SDK) --enable-application=extensions --enable-extensions=enigmail --disable-debug --disable-tests --disable-crashreporter --disable-ogg --disable-necko-wifi --disable-webm --disable-libjpeg-turbo --disable-elf-hack --enable-chrome-format=omni $(CONFIGFLAGS)
 
23
        cd $(BUILDDIR); \
 
24
                $(CURDIR)/configurehelper.sh $(CONFIGFLAGS)
27
25
 
28
26
override_dh_auto_build:
29
 
#       dh_auto_build --builddirectory=$(BUILDDIR)
30
 
        dh_auto_build
31
 
        cd $(BUILDDIR)/extensions/enigmail; make xpi
 
27
        dh_auto_build --builddirectory=$(BUILDDIR)
 
28
        make -C $(BUILDDIR)/extensions/enigmail xpi
32
29
 
33
30
override_dh_auto_clean:
34
 
        ( cd config && make distclean ) || true
35
 
        ( cd extensions/enigmail && make distclean ) || true
36
 
        ( cd extensions/enigmail/public && make distclean ) || true
 
31
        make -C $(BUILDDIR) distclean || true
37
32
        dh_auto_clean
38
33
 
39
 
 
40
34
override_dh_install:
41
35
        install-xpi -penigmail $(BUILDDIR)/dist/bin/enigmail-*.xpi
42
36
 
43
 
get-orig-source: DEB_UPSTREAM_VERSION=$(shell dpkg-parsechangelog | sed -rne 's/^Version: ([0-9]*\:)?([^-]+).*/\2/p')
44
 
get-orig-source:
45
 
        mkdir tmp
46
 
        bzr branch lp:~mozillateam/mozilla-build-system/beta tmp/enigmail-$(DEB_UPSTREAM_VERSION)
47
 
        cd tmp/enigmail-$(DEB_UPSTREAM_VERSION) ; \
 
37
get-orig-source:: DEB_UPSTREAM_VERSION := $(shell dpkg-parsechangelog | sed -rne 's/^Version: ([0-9]*\:)?([^-]+).*/\2/p')
 
38
get-orig-source:: TMPDIR := $(shell mktemp -d)
 
39
get-orig-source::
 
40
        bzr branch lp:~mozillateam/mozilla-build-system/beta $(TMPDIR)/enigmail-$(DEB_UPSTREAM_VERSION)
 
41
        cd $(TMPDIR)/enigmail-$(DEB_UPSTREAM_VERSION) ; \
48
42
                rm -rf .bzr ; \
49
43
                wget http://www.mozilla-enigmail.org/download/source/enigmail-$(DEB_UPSTREAM_VERSION).tar.gz ; \
50
44
                tar -C extensions -xf enigmail-$(DEB_UPSTREAM_VERSION).tar.gz ; \
51
45
                rm -f enigmail-$(DEB_UPSTREAM_VERSION).tar.gz
52
 
        cd tmp ; \
 
46
        cd $(TMPDIR) ; \
53
47
                tar -czvf enigmail_$(DEB_UPSTREAM_VERSION).orig.tar.gz enigmail-$(DEB_UPSTREAM_VERSION)
54
 
        mv tmp/enigmail_$(DEB_UPSTREAM_VERSION).orig.tar.gz ..
55
 
        rm -rf tmp
 
48
        mv $(TMPDIR)/enigmail_$(DEB_UPSTREAM_VERSION).orig.tar.gz $(CURDIR)/..
 
49
        rm -rf $(TMPDIR)