[Pkg-zsh-devel] Refreshing patches for z-sy-h 0.7.0

Daniel Shahaf danielsh at apache.org
Mon Jul 22 03:27:53 BST 2019


Daniel Shahaf wrote on Sun, Jul 21, 2019 at 03:08:16 +0000:
> [ tl;dr: Building z-sy-h for current sid fails to apply debian/patches/set-version.patch. ]

⋮

> And then I tried to build the resulting tree in a fresh sid chroot.  It
> failed because not all patches had been refreshed, so I logged into the
> chroot and refreshed the patches using sid's quilt(1):
> 
> 	$ quilt() { QUILT_PATCHES=debian/patches quilt "$@"; }
> 	$ quilt push && quilt refresh
> 	$ quilt push && quilt refresh
> 	$ quilt push && quilt refresh
> 	$ dpkg-buildpackage -uc -us -ui
>> 	dpkg-source: info: using patch list from debian/patches/series
> 	can't find file to patch at input line 22
> 	Perhaps you used the wrong -p or --strip option?
> 	The text leading up to this was:
> 	--------------------------
>> 	|--- zsh-syntax-highlighting.orig/Makefile
> 	|+++ zsh-syntax-highlighting/Makefile
> 	--------------------------
> 	No file to patch.  Skipping patch.
> 	2 out of 2 hunks ignored
> 	dpkg-source: info: the patch has fuzz which is not allowed, or is malformed
> 	dpkg-source: info: if patch 'set-version.patch' is correctly applied by quilt, use 'quilt refresh' to update it
> 	dpkg-source: error: LC_ALL=C patch -t -F 0 -N -p1 -u -V never -E -b -B .pc/set-version.patch/ --reject-file=- < zsh-syntax-highlighting.orig.iOgnHm/debian/patches/set-version.patch subprocess returned exit status 1
> 	dpkg-buildpackage: error: dpkg-source -b . subprocess returned exit status 2

This looks odd: patch(1) is invoked with the -p1 option, implying it
expects its cwd to be the root of the source tree, but its stdin is
«zsh-syntax-highlighting.orig.iOgnHm/debian/patches/set-version.patch»,
which seems to imply that the patch(1)'s actual cwd is the parent
directory of the source tree.  Might that be the problem?

My pbuilder configuration has a hook that does «cd "$BUILDDIR"/*/debian/..»,
but that shouldn't be related, for two reasons:

1. The hook's letter is "C", so it's only executed after a build
failure.

2. According to both the pbuilder(1) man page and pbuilder's source³,
hooks are not _sourced_ but _executed_, so chdir(2) calls in the hook
shouldn't affect anything outside of it.

> I've also tried changing deleting the "---\n" line from the preamble of
> the patch, but that didn't help either.  I haven't tried rebuilding the
> latest version of the package against current sid (ENOTIME).

0.6.0-3 was built in sid on tests.reproducible-builds.org a few minutes
ago.  Both builds were successful.  Thus, either something in sid
changed between my build yesterday and the build on r-b today, or the
merge from upstream broke something, or the r-b build setup is different
to mine.

Cheers,

Daniel

³ The function 'executehooks' in the source of pbuilder=0.230.4, the
current sid version.



More information about the Pkg-zsh-devel mailing list