~xubuntu-dev/ubiquity/lp1437180_feh

« back to all changes in this revision

Viewing changes to debian/rules

  • Committer: Colin Watson
  • Date: 2006-04-05 13:14:56 UTC
  • Revision ID: colin.watson@canonical.com-20060405131456-53786dee285d816a
* Reorganise component packaging. Instead of having to modify each d-i
  component to produce an espresso-* binary package (in most cases) and
  having to do coordinated uploads of that package and espresso all the
  time, we now include all the relevant d-i source packages in this one
  (under d-i/source/), build them as part of our build process, and
  include all the components in the espresso binary package. 'debian/rules
  update' can be used to do automatic updates of these copied source
  packages. This should ultimately simplify maintenance work as well as
  making it much easier for third parties to make local changes to this
  installer.
* All FilteredCommand implementations for components now belong to
  espresso rather than to the component (because they were quite tightly
  bound to espresso's UI frontends anyway) and will be removed from
  component packages.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#!/usr/bin/make -f
2
2
 
3
 
export DH_OPTIONS
4
 
 
5
3
# Uncomment this to turn on verbose mode.
6
4
#export DH_VERBOSE=1
7
5
 
8
6
BUILDDIR=$(CURDIR)/debian/build
9
7
 
 
8
DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH)
10
9
DEB_HOST_ARCH_CPU ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_CPU 2>/dev/null)
11
10
 
12
11
# Take account of old dpkg-architecture output.
18
17
endif
19
18
 
20
19
ifneq (,$(findstring :$(DEB_HOST_ARCH_CPU):,:amd64:i386:))
21
 
  BOOTLOADER := espresso-grub (>= 1.12ubuntu3)
 
20
  bootloader-depends := grub, os-prober
22
21
else
23
22
ifeq ($(DEB_HOST_ARCH_CPU),powerpc)
24
 
  BOOTLOADER := espresso-yaboot
25
 
endif
26
 
endif
 
23
  bootloader-depends := yaboot, os-prober, hfsutils
 
24
endif
 
25
endif
 
26
 
 
27
update:
 
28
        $(MAKE) -C d-i update
27
29
 
28
30
build: build-stamp
29
31
 
32
34
 
33
35
        ./configure --prefix=/usr
34
36
        $(MAKE)
 
37
        $(MAKE) -C d-i build
35
38
 
36
39
        mkdir -p $(BUILDDIR)/ubuntu
37
40
        mkdir -p $(BUILDDIR)/guadalinex
50
53
        rm -fr build-stamp $(BUILDDIR)
51
54
        find -type f \( -name \*.pyc -o -name \*.pyo \) -print0 | xargs -0r rm -f
52
55
 
 
56
        $(MAKE) -C d-i clean
53
57
        -$(MAKE) distclean
54
58
 
55
 
        dh_clean 
 
59
        dh_clean debian/espresso.install
56
60
 
57
61
install:
58
62
        dh_testdir
63
67
        # For the meantime, everything automake wants to install is part of
64
68
        # the GTK frontend.
65
69
        $(MAKE) install DESTDIR=$(CURDIR)/debian/espresso-frontend-gtk
 
70
        $(MAKE) -C d-i install
66
71
 
 
72
        cp debian/espresso.install-any debian/espresso.install
 
73
ifneq (,$(wildcard debian/espresso.install-$(DEB_HOST_ARCH)))
 
74
        cat debian/espresso.install-$(DEB_HOST_ARCH) >> debian/espresso.install
 
75
endif
67
76
        dh_install -A
 
77
 
 
78
        # Bits of manual installation that can't be done by dh_install
68
79
        install installer $(CURDIR)/debian/espresso/usr/bin/espresso
 
80
        install d-i/source/tzsetup/prebaseconfig.d/*tzsetup \
 
81
                debian/espresso/usr/lib/espresso/tzsetup/prebaseconfig
 
82
        set -e; for x in user-setup user-setup-ask user-setup-apply; do \
 
83
                sed 's,/usr/lib/user-setup,/usr/lib/espresso/user-setup,g' \
 
84
                        d-i/source/user-setup/$$x \
 
85
                        > debian/espresso/usr/lib/espresso/user-setup/$$x; \
 
86
                chmod +x debian/espresso/usr/lib/espresso/user-setup/$$x; \
 
87
        done
 
88
ifeq ($(DEB_HOST_ARCH),powerpc)
 
89
        install d-i/source/yaboot-installer/debian/postinst \
 
90
                debian/espresso/usr/lib/espresso/yaboot-installer/yaboot-installer
 
91
endif
 
92
 
69
93
        for locale in $$(find $(BUILDDIR)/ubuntu/ -name \*.mo -exec basename {} .mo \;); do mkdir -p $(CURDIR)/debian/espresso-ubuntu-doc/usr/share/locale/$$locale/LC_MESSAGES/; mv $(BUILDDIR)/ubuntu/$$locale.mo $(CURDIR)/debian/espresso-ubuntu-doc/usr/share/locale/$$locale/LC_MESSAGES/ubuntu-installer.mo; done
70
94
        for locale in $$(find $(BUILDDIR)/guadalinex/ -name \*.mo -exec basename {} .mo \;); do mkdir -p $(CURDIR)/debian/espresso-guadalinex-doc/usr/share/locale/$$locale/LC_MESSAGES/; mv $(BUILDDIR)/guadalinex/$$locale.mo $(CURDIR)/debian/espresso-guadalinex-doc/usr/share/locale/$$locale/LC_MESSAGES/guadalinex-installer.mo; done
71
95
 
96
120
        dh_installdocs -a
97
121
#       dh_installexamples -a
98
122
        dh_installdebconf -a
 
123
        echo >> debian/espresso/DEBIAN/templates
 
124
        cat d-i/templates >> debian/espresso/DEBIAN/templates
99
125
#       dh_installman -a
100
126
        dh_strip -a
101
127
        dh_compress -a
103
129
        dh_python -a
104
130
        dh_installdeb -a
105
131
        dh_shlibdeps -a
106
 
ifdef BOOTLOADER
107
 
        dh_gencontrol -a -- -V'bootloader=$(BOOTLOADER)'
 
132
ifdef bootloader-depends
 
133
        dh_gencontrol -a -- -V'bootloader-depends=$(bootloader-depends)'
108
134
else
109
135
        dh_gencontrol -a
110
136
endif