don't delete debian directory in official debian builds
PATCH 1/1 don't delete debian directory in official debian builds
Hi,
Somewhere along the 2.6 series, there was a change made that causes distclean to automatically delete the debian/ subdirectory from the top of the kernel tree. This causes grief for the official debian kernel packages; the debian directory shouldn't be deleted in the packages. Please apply the attached patch; it causes the debian/ subdirectory to only be deleted if there's no debian/official.
An even better solution would be to mark the debian directory as being created by the kernel (touch debian/linus), and only delete it if the kernel created it.
Signature · 1 line
Andres Salomon <[email protected]>
#! /bin/sh -e
## dont-delete-debian.dpatch by Andres Salomon <[email protected]> ##
## All lines beginning with `## DP:' are a description of the patch. ## DP: Description: don't delete debian directory if debian/official exists ## DP: Patch author: Andres Salomon
## DP: Upstream status: unsubmitted
. $(dirname $0)/DPATCH
@DPATCH@
scripts/package/Makefile +1 -1
@@ -77,7 +77,7 @@ $(MAKE) $(CONFIG_SHELL) $(srctree)/scripts/package/builddeb -clean-rule += && rm -rf $(objtree)/debian/ +clean-rule += && test -f $(objtree)/debian/official || rm -rf $(objtree)/debian/ # Help text displayed when executing 'make help'
Quoted 9 lines · Andres Salomon
Hi,
Somewhere along the 2.6 series, there was a change made that causes distclean to automatically delete the debian/ subdirectory from the top of the kernel tree. This causes grief for the official debian kernel packages; the debian directory shouldn't be deleted in the packages. Please apply the attached patch; it causes the debian/ subdirectory to only be deleted if there's no debian/official.
Quoted 3 lines
An even better solution would be to mark the debian directory as being created by the kernel (touch debian/linus), and only delete it if the kernel created it.
Such special cases are not acceptable.
If this causes a problem then there are the following options:
1) Rename directory in debian or the kernel
2) Debian apply a patch to the kernel
Preference to 1).
Comments?
Sam
Quoted 10 lines · Sam Ravnborg
Quoted 9 lines · Andres Salomon
Hi,
Somewhere along the 2.6 series, there was a change made that causes distclean to automatically delete the debian/ subdirectory from the top of the kernel tree. This causes grief for the official debian kernel packages; the debian directory shouldn't be deleted in the packages. Please apply the attached patch; it causes the debian/ subdirectory to only be deleted if there's no debian/official.
Quoted 6 lines
Quoted 3 lines
An even better solution would be to mark the debian directory as being created by the kernel (touch debian/linus), and only delete it if the kernel created it.
Such special cases are not acceptable.
This isn't a special case; this is debian using a directory for years, and the kernel suddenly deciding to not only use the same directory, but assume ownership of it and delete it when distcleaning. By providing a rule that creates a debian package, you've managed to inconvenience the people who actually create and maintain the main system your debian package would run on. Please take this into consideration.
Quoted 3 lines
If this causes a problem then there are the following options:
1) Rename directory in debian or the kernel
2) Debian apply a patch to the kernel
How about not deleting the directory if you haven't created it? Debian already applies patches to the kernel, but we feed changes/fixes back to linus and co; this is one of those fixes that should be in the main kernel. If you're going to provide a make rule for *Debian*, then make it consistent with Debian packaging standards. Otherwise, why even bother? Debian has its own supported methods for creating kernel packages (named, oddly enough, kernel-package).
Honestly, I'd rather see the deb rule removed completely; Debian and Debian-derived distributions provide their own kernel packages. Users who compile their own kernel have the option of using a Debian supported method for building kernel packages (they can also simply copy images around, without bothering w/ packages). Generating a package without kernel-package is not supported; does it even handle grub and lilo updates in postinst?
Quoted 2 lines
Preference to 1).
I'm not quite sure what you mean w/ #1. You want Debian, which has used the debian/ subdirectory for years, to use something else for its kernel packages?
Quoted 4 lines
Comments?
Sam
Signature · 1 line
Andres Salomon <[email protected]>
Quoted 6 lines · Andres Salomon
Quoted 2 lines
Preference to 1).
I'm not quite sure what you mean w/ #1. You want Debian, which has used the debian/ subdirectory for years, to use something else for its kernel packages?
Let the kernel use a directory named 'deb' to match the deb-pkg target.
Sam
Quoted 9 lines · Sam Ravnborg
Quoted 6 lines · Andres Salomon
Quoted 2 lines
Preference to 1).
I'm not quite sure what you mean w/ #1. You want Debian, which has used the debian/ subdirectory for years, to use something else for its kernel packages?
Let the kernel use a directory named 'deb' to match the deb-pkg target.
That works for me. I assume the idea is to use $(SRCDIR)/deb/debian instead of $(SRCDIR)/debian.
Signature · 1 line
Andres Salomon <[email protected]>