Bug#295220: asterisk.8.gz: build of asterisk changes binary file

Tzafrir Cohen Tzafrir Cohen <tzafrir.cohen@xorcom.com>, 295220@bugs.debian.org
Mon, 14 Feb 2005 18:28:14 +0200


--SUOF0GtieIMvvwua
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Patch attached

-- 
Tzafrir Cohen   icq#16849755  +972-50-7952406
tzafrir.cohen@xorcom.com    http://xorcom.com

--SUOF0GtieIMvvwua
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="mancompress.diff"

--- debian/rules	2005-02-08 11:08:55.000000000 +0200
+++ ../../asterisk-1.0.5/debian/rules	2005-02-14 16:27:28.000000000 +0200
@@ -65,8 +65,13 @@
 	#/usr/bin/docbook-to-man debian/asterisk.sgml > asterisk.1
 	$(MAKE) progdocs
 
-	gunzip asterisk.8.gz
-	gzip --best asterisk.8
+  # compress man page in a subdir:
+	# - I want to preserve filename, so dh_installman won't have problems
+	# - But changing the original file generates:
+	#   dpkg-source: unrepresentable changes to source
+	mkdir -p mancompress
+	zcat asterisk.8.gz >mancompress/asterisk.8
+	gzip --best mancompress/asterisk.8
 	
 	touch build-indep-stamp
 
@@ -78,6 +83,7 @@
 	dh_testdir
 	dh_testroot
 	-$(RM) -f build-arch-stamp build-indep-stamp configure 
+	rm -rf mancompress
 
 	# Add here commands to clean up after the build process.
 	-$(MAKE) -C channels/h323 clean
@@ -99,8 +105,7 @@
 	$(MAKE) INSTALL_PREFIX=$(CURDIR)/debian/tmp install samples
 	cp debian/asterisk.conf $(CURDIR)/debian/tmp/etc/asterisk/asterisk.conf
 	cp channels/h323/h323.conf.sample $(CURDIR)/debian/tmp/etc/asterisk/h323.conf
-	cp contrib/scripts/addmailbox $(CURDIR)/debian/tmp/usr/sbin/
-	chmod +x $(CURDIR)/debian/tmp/usr/sbin/addmailbox
+	cp -a debian/rapid_conf/*  $(CURDIR)/debian/tmp/etc/asterisk/
 	mkdir -p $(CURDIR)/debian/tmp/etc/default/
 	cp debian/asterisk-config.default $(CURDIR)/debian/tmp/etc/default/asterisk
 	mkdir -p $(CURDIR)/debian/tmp/usr/lib/cgi-bin/asterisk/
@@ -115,7 +120,7 @@
 	dh_testdir -i
 	dh_testroot -i
 	dh_installdocs -i
-	dh_installman asterisk.8.gz
+	dh_installman mancompress/asterisk.8.gz
 	dh_installexamples -i -XCVS
 	dh_installcron -i
 	dh_installchangelogs ChangeLog -i

--SUOF0GtieIMvvwua--