Package: apt-howto Version: 2.0.2-2 Severity: minor Tags: patch
Hi. I found the following problems in the ./debian/rules clean target: - There is commands that only work if /bin/sh is bash: pattern substitution and brace expansion. - It reverses the patches and doesn't remove the touched .patched files. - It tries to reverse an inexistent patch a second time. This doesn't ends with error because it does a test before the try. - It patch and reverse the patch in the same order. So two sequential patches generates an error when the reverse occurs. - It reverses the patches before the ``make clean'' command. So there is no way to use the patched files in the clean. - The files texsys.aux head.tmp body.tmp are created during the build but aren't removed by ./Makefile clean target nor by ./debian/rules clean target. The ./Makefile clean target have bashism: brace expansion. This affects indirectly the reported problem. The attached patch corrects these problems and, if used with my patch to bug #431664 (#432349), makes the package build and clear properly (using fakeroot) here. The bug #431664 (#432349) informs that the package is FTBFS. -- System Information: Debian Release: lenny/sid APT prefers unstable APT policy: (500, 'unstable'), (300, 'experimental') Architecture: i386 (i686) Kernel: Linux 2.6.23.1 Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash -- ,-. rollingbits -- [EMAIL PROTECTED], [EMAIL PROTECTED] \`' [EMAIL PROTECTED], [EMAIL PROTECTED], [EMAIL PROTECTED] ` Get my public GPG key in http://rollingbits.tripod.com/mykey.html
diff -urN apt-howto-old/debian/patches/02_fix_clean.diff apt-howto-2.0.2/debian/patches/02_fix_clean.diff --- apt-howto-old/debian/patches/02_fix_clean.diff 1969-12-31 21:00:00.000000000 -0300 +++ apt-howto-2.0.2/debian/patches/02_fix_clean.diff 2007-11-09 20:25:59.000000000 -0200 @@ -0,0 +1,11 @@ +--- Makefile.orig 2007-11-03 23:25:18.000000000 -0200 ++++ Makefile 2007-11-03 23:23:35.000000000 -0200 +@@ -26,6 +26,8 @@ + # called <directoryname>.[<language>.]sgml, which is the top-level file + # for the manual in this directory. + ++SHELL := /bin/bash # There is bashism here ++ + # Basename for language-dependent SGML (DDP default, generated) + #MANUAL := $(notdir $(CURDIR)) + MANUAL := apt-howto diff -urN apt-howto-old/debian/rules apt-howto-2.0.2/debian/rules --- apt-howto-old/debian/rules 2007-11-09 20:31:29.000000000 -0200 +++ apt-howto-2.0.2/debian/rules 2007-11-09 20:30:13.000000000 -0200 @@ -9,6 +9,8 @@ export DH_COMPAT=4 export LC_ALL=C +SHELL := /bin/bash # There is bashism here + MANUAL := apt-howto LANGS := ca de el en es fr it ja ko pt-br pl ru tr uk BUILD_TYPE := package @@ -50,10 +52,6 @@ dh_testdir dh_testroot - for i in $$(ls debian/patches/*.patched); do \ - patch -p0 -R < $${i/.patched/}; \ - done - # code based on gnome-pkg-tools to auto create Uploaders field from # metainfo available on the Debian Brasil's Team SVN repo TEAM_LIST=../../metainfo/debian-br.team; \ @@ -77,9 +75,9 @@ # end of Uploaders generating code - if patch --dry-run -R -p0 < debian/patches/00_special_case_el_in_fixhtml.diff >& /dev/null; then \ - patch -R -p0 < debian/patches/00_special_case_el_in_fixhtml.diff; \ - fi + #if patch --dry-run -R -p0 < debian/patches/00_special_case_el_in_fixhtml.diff >& /dev/null; then \ + # patch -R -p0 < debian/patches/00_special_case_el_in_fixhtml.diff; \ + #fi rm -f build-stamp configure-stamp # Add here commands to clean up after the build process. -$(MAKE) "MANUAL=$(MANUAL)" "LANGS=$(LANGS)" \ @@ -91,7 +89,12 @@ apt-howto-$${xx}.dirs \ apt-howto-$${xx}.doc-base; \ done - -rm *.ent + rm -f *.ent texsys.aux head.tmp body.tmp + + for i in $$(ls -r debian/patches/*.patched); do \ + patch -p0 -R < $${i/.patched/}; \ + rm -f $${i}; \ + done dh_clean