Package: src:f2fs-tools Severity: wishlist Tags: patch Hello. Please consider the attached style suggestions for the Debian packaging.
>From 357cc821b7ed2bd1e6616a6b964780aeedfb2b83 Mon Sep 17 00:00:00 2001 From: Nicolas Boulenguez <nico...@debian.org> Date: Thu, 1 Jul 2021 11:09:38 +0200 Subject: [PATCH 1/4] Remove get-orig-source target from debian/rules
uscan is preferred when possible --- debian/rules | 7 ------- 1 file changed, 7 deletions(-) diff --git a/debian/rules b/debian/rules index 298b739..d494e69 100755 --- a/debian/rules +++ b/debian/rules @@ -24,13 +24,6 @@ override_dh_install: override_dh_strip: dh_strip --dbgsym-migration='f2fs-tools-dbg (<< 1.12.0-1~)' -get-orig-source: - wget http://git.kernel.org/cgit/linux/kernel/git/jaegeuk/f2fs-tools.git/snapshot/f2fs-tools-$(DEB_VERSION_UPSTREAM).tar.gz - gunzip < f2fs-tools-$(DEB_VERSION_UPSTREAM).tar.gz | \ - xz > f2fs-tools-$(DEB_VERSION_UPSTREAM).tar.xz - rm f2fs-tools-$(DEB_VERSION_UPSTREAM).tar.gz - mv f2fs-tools-$(DEB_VERSION_UPSTREAM).tar.xz f2fs-tools_$(DEB_VERSION_UPSTREAM).orig.tar.xz - # dh_dwz when run on f2fs-tools-udeb ends up installing the # /usr/lib/debug/.dwz files into the udeb. I think that's a bug, # but for now, override it by just saying... just don't. -- 2.30.2
>From 93b6af0a23efeab80519595f3649d091c1e21947 Mon Sep 17 00:00:00 2001 From: Nicolas Boulenguez <nico...@debian.org> Date: Thu, 1 Jul 2021 11:12:22 +0200 Subject: [PATCH 2/4] Remove redundant libdir option from dh_auto_configure override dh_auto_configure already sets this option explicitly --- debian/rules | 1 - 1 file changed, 1 deletion(-) diff --git a/debian/rules b/debian/rules index d494e69..9dd7659 100755 --- a/debian/rules +++ b/debian/rules @@ -12,7 +12,6 @@ include /usr/share/dpkg/default.mk override_dh_auto_configure: dh_auto_configure -- --sbindir=/sbin --disable-shared \ - --libdir=/usr/lib/$(DEB_HOST_MULTIARCH) \ --with-root-libdir=/lib/$(DEB_HOST_MULTIARCH) override_dh_install: -- 2.30.2
>From 68eb8fa80bfe5409095f6ea04dbd3728027241f6 Mon Sep 17 00:00:00 2001 From: Nicolas Boulenguez <nico...@debian.org> Date: Thu, 1 Jul 2021 11:14:00 +0200 Subject: [PATCH 3/4] Stop exporting build flags from debian/rules dh_auto_* tools already export the build flags, whether debian/rules knowns about them or not. In this case, debian/rules does not need to interfer. The test_printenv target seems to have been introduced in order to check the removed export. --- debian/rules | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/debian/rules b/debian/rules index 9dd7659..9bc4df8 100755 --- a/debian/rules +++ b/debian/rules @@ -4,8 +4,7 @@ export DEB_BUILD_MAINT_OPTIONS ?= hardening=+all -DPKG_EXPORT_BUILDFLAGS = 1 -include /usr/share/dpkg/default.mk +include /usr/share/dpkg/architecture.mk %: dh $@ @@ -28,6 +27,3 @@ override_dh_strip: # but for now, override it by just saying... just don't. override_dh_dwz: dh_dwz -N f2fs-tools-udeb - -test_printenv: - printenv | sort -- 2.30.2
>From 0a83de005e2e72e02d847454b588d0f63bbc033c Mon Sep 17 00:00:00 2001 From: Nicolas Boulenguez <nico...@debian.org> Date: Thu, 1 Jul 2021 11:33:52 +0200 Subject: [PATCH 4/4] Switch to debhelper 13 dh_missing is now enabled by default --- debian/control | 2 +- debian/f2fs-tools-udeb.install | 3 ++- debian/f2fs-tools.install | 4 +++- debian/not-installed | 5 +++++ debian/rules | 6 ------ 5 files changed, 11 insertions(+), 9 deletions(-) create mode 100644 debian/not-installed diff --git a/debian/control b/debian/control index 994b60d..a177742 100644 --- a/debian/control +++ b/debian/control @@ -4,7 +4,7 @@ Priority: optional Maintainer: Filesystems Group <filesystems-de...@lists.alioth.debian.org> Uploaders: Vincent Cheng <vch...@debian.org>, Theodore Y. Ts'o <ty...@mit.edu> Build-Depends: - debhelper-compat (= 12), + debhelper-compat (= 13), libblkid-dev, libselinux1-dev, pkg-config, diff --git a/debian/f2fs-tools-udeb.install b/debian/f2fs-tools-udeb.install index d48cf30..5779210 100644 --- a/debian/f2fs-tools-udeb.install +++ b/debian/f2fs-tools-udeb.install @@ -1 +1,2 @@ -/sbin +# All but sbin/sg_write_buffer +sbin/*f2fs* diff --git a/debian/f2fs-tools.install b/debian/f2fs-tools.install index c5dbdb2..1b7999a 100644 --- a/debian/f2fs-tools.install +++ b/debian/f2fs-tools.install @@ -1,2 +1,4 @@ -sbin/* +# All but sbin/sg_write_buffer +sbin/*f2fs* + usr/share/man/man8/*.8 diff --git a/debian/not-installed b/debian/not-installed new file mode 100644 index 0000000..5cb77ca --- /dev/null +++ b/debian/not-installed @@ -0,0 +1,5 @@ +# Policy recommends not to install libtool .la files +usr/lib/*/libf2fs*.la + +# See f2fs-tools.install and f2fs-tools-udeb.install +sbin/sg_write_buffer diff --git a/debian/rules b/debian/rules index 9bc4df8..67c1e09 100755 --- a/debian/rules +++ b/debian/rules @@ -13,12 +13,6 @@ override_dh_auto_configure: dh_auto_configure -- --sbindir=/sbin --disable-shared \ --with-root-libdir=/lib/$(DEB_HOST_MULTIARCH) -override_dh_install: - find $(CURDIR) -name "*.la" -delete - rm $(CURDIR)/debian/tmp/sbin/sg_write_buffer - dh_install - dh_missing --fail-missing - override_dh_strip: dh_strip --dbgsym-migration='f2fs-tools-dbg (<< 1.12.0-1~)' -- 2.30.2