/[pkg-kde]/trunk/packages/kdelibs/debian/rules
ViewVC logotype

Contents of /trunk/packages/kdelibs/debian/rules

Parent Directory Parent Directory | Revision Log Revision Log


Revision 51 - (show annotations) (download)
Sat Feb 21 01:34:15 2004 UTC (9 years, 3 months ago) by ccheney
File size: 5125 byte(s)
kdelibs 3.2.0-0pre1v1 update

KDE_3_2_BRANCH update
Corrected Conflicts/Replaces
Various other minor fixes
1 #!/usr/bin/make -f
2 # -*- makefile -*-
3 # Sample debian/rules that uses debhelper.
4 # GNU copyright 1997 to 1999 by Joey Hess.
5 #
6 # Modified to make a template file for a multi-binary package with separated
7 # build-arch and build-indep targets by Bill Allombert 2001
8
9 # Uncomment this to turn on verbose mode.
10 #export DH_VERBOSE=1
11
12 # This is the debhelper compatibility version to use.
13 export DH_COMPAT=4
14
15 # This has to be exported to make some magic below work.
16 export DH_OPTIONS
17
18 # These are used for cross-compiling and for saving the configure script
19 # from having to guess our platform (since we know it already)
20 DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
21 DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
22
23 CFLAGS = -Wall -g
24
25 ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
26 CFLAGS += -O0
27 else
28 CFLAGS += -O2
29 endif
30 ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
31 INSTALL_PROGRAM += -s
32 endif
33
34 objdir = $(CURDIR)/obj-$(DEB_BUILD_GNU_TYPE)
35
36 version=`head -1 debian/changelog | sed -e "s#.*(\([^)]*\)).*#Debian Package \1#"` ;
37
38 -include debian/debiandirs
39
40 debian/debiandirs: admin/debianrules
41 perl -w admin/debianrules echodirs > debian/debiandirs
42
43 configure: configure-stamp
44 configure-stamp:
45 dh_testdir
46
47 # Apply Debian specific patches
48 if test -d $(CURDIR)/debian/patches ;\
49 then \
50 for i in $(CURDIR)/debian/patches/*.diff.uu ;\
51 do \
52 cd $(CURDIR)/debian/patches ;\
53 uudecode "$$i" ;\
54 cd $(CURDIR) ;\
55 done ;\
56 patches=$$(find $(CURDIR)/debian/patches -name *.diff | sort);\
57 fi ;\
58 if test ! -f patch-stamp; then \
59 for patch in $$patches ;\
60 do \
61 echo APPLYING PATCH\: "$${patch##*/}" ;\
62 patch -p1 < "$$patch" ;\
63 done ;\
64 touch patch-stamp ;\
65 fi
66
67 # KDE CVS does not have aclocal.m4 or configure
68 if test ! -f configure; then \
69 $(MAKE) -f admin/Makefile.common ;\
70 fi
71
72 # ensure configure is executable
73 chmod +x configure
74
75 # make build directory
76 mkdir $(objdir)
77
78 # run configure with build tree $(objdir)
79 cd $(objdir) && \
80 ../configure $(configkde) --enable-final \
81 --with-distribution="$$version (`cat /etc/debian_version`)" \
82 --enable-dnotify --enable-mitshm --with-alsa --with-ipv6-lookup=auto \
83 $(FAST_MALLOC)
84
85 touch configure-stamp
86
87 #Architecture
88 build: build-arch build-indep
89
90 build-arch: build-arch-stamp
91 build-arch-stamp: configure-stamp
92 dh_testdir
93
94 cd $(objdir) && \
95 $(MAKE)
96
97 # generate manpages
98 for i in debian/man/*.sgml; do \
99 docbook-to-man $$i > `dirname $$i`/`basename $$i .sgml`.1 ;\
100 done
101
102 touch build-arch-stamp
103
104 build-indep: build-indep-stamp
105 build-indep-stamp: configure-stamp
106 dh_testdir
107
108 cd $(objdir) && \
109 $(MAKE)
110
111 cd $(objdir) && \
112 $(MAKE) apidox
113
114 touch build-indep-stamp
115
116 debian-clean:
117 dh_testdir
118 dh_testroot
119
120 dh_clean
121
122 clean:
123 dh_testdir
124 dh_testroot
125 rm -f build-arch-stamp build-indep-stamp configure-stamp \
126 debian/debiandirs debian/man/*.1
127
128 # Remove Debian specific patches
129 if test -d $(CURDIR)/debian/patches ;\
130 then \
131 patches=$$(find $(CURDIR)/debian/patches -name *.diff | sort -r);\
132 fi ;\
133 if test -f patch-stamp; then \
134 for patch in $$patches ;\
135 do \
136 echo REMOVING PATCH\: "$${patch##*/}" ;\
137 patch -p1 -R < "$$patch" ;\
138 done ;\
139 for i in $(CURDIR)/debian/patches/*.diff.uu ;\
140 do \
141 rm -f "$${i%%.uu}" ;\
142 done ;\
143 rm -f patch-stamp ;\
144 fi
145
146 # Remove build tree
147 rm -rf $(objdir)
148
149 # if Makefile exists run distclean
150 if test -f Makefile; then \
151 $(MAKE) distclean; \
152 fi
153
154 if test -d CVS; then \
155 $(MAKE) -f admin/Makefile.common cvs-clean ;\
156 fi
157
158 dh_clean
159
160 install: install-arch install-indep
161
162 install-arch:
163 dh_testdir
164 dh_testroot
165 dh_clean -k -s
166 dh_installdirs -s
167
168 cd $(objdir) && \
169 $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
170
171 dh_install -s --list-missing
172
173 install-indep:
174 dh_testdir
175 dh_testroot
176 dh_clean -k -i
177 dh_installdirs -i
178
179 cd $(objdir) && \
180 $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
181
182 cd $(objdir) && \
183 $(MAKE) install-apidox DESTDIR=$(CURDIR)/debian/tmp
184
185 dh_install -i --list-missing
186
187 # Must not depend on anything. This is to be called by
188 # binary-arch/binary-indep
189 # in another 'make' thread.
190 binary-common:
191 dh_testdir
192 dh_testroot
193 dh_installchangelogs
194 dh_installdocs
195 # dh_installexamples
196 # dh_installmenu
197 # dh_installdebconf
198 # dh_installlogrotate
199 # dh_installemacsen
200 # dh_installpam
201 # dh_installmime
202 # dh_installinit
203 # dh_installcron
204 # dh_installinfo
205 dh_installman
206 dh_link
207 dh_strip
208 dh_compress -X.bz2 -X.css -X.dcl -X.docbook -X-license -X.tag
209 dh_fixperms -Xusr/bin/kgrantpty -Xusr/bin/kpac_dhcp_helper
210 dh_perl
211 # dh_python
212 dh_makeshlibs -V
213 dh_installdeb
214 dh_shlibdeps -ldebian/kdelibs-bin/usr/lib:debian/kdelibs4/usr/lib
215 dh_gencontrol
216 dh_md5sums
217 dh_builddeb
218
219 # Build architecture independant packages using the common target.
220 binary-indep: build-indep install-indep
221 $(MAKE) -f debian/rules DH_OPTIONS=-i binary-common
222
223 # Build architecture dependant packages using the common target.
224 binary-arch: build-arch install-arch
225 $(MAKE) -f debian/rules DH_OPTIONS=-s binary-common
226
227 binary: binary-arch binary-indep
228 .PHONY: build clean binary-indep binary-arch binary install install-indep install-arch configure

Properties

Name Value
svn:executable *

  ViewVC Help
Powered by ViewVC 1.1.5