control: tag -1 + patch
Hi,
On 2025-05-30 09:00, Chris Hofstaedtler wrote:
> * Theodore Ts'o <[email protected]> [250530 02:15]:
> > On Thu, May 29, 2025 at 10:53:20PM +0200, Aurelien Jarno wrote:
> > > Package: e2fsck-static
> > > Version: 1.40.4-1
> > > Severity: serious
> > > Justification: Policy 7.8
> > >
> > > Dear maintainer,
> > >
> > > The e2fsck-static package provides /usr/sbin/e2fsck.static which is
> > > statically linked against glibc.
> > >
> > > glibc is mostly is mostly licensed under the LGPL, which requires that
> > > the full source code of the incorporating binary package be made
> > > available. According to Debian Policy ยง7.8 [1] such a binary package
> > > MUST list the glibc source package (and possibly others) in the
> > > Built-Using: field.
> >
> > Is there an idiomatic way to automatically determine in debian/rules
> > what version of glib was used to build the binary package, so the
> > exact version can be specified in Built-Using?
>
> Here's an example I found using codesearch, from the grub package:
>
> https://sources.debian.org/src/grub2/2.12-7/debian/rules/?hl=593#L593
>
> BUILT_USING=$(shell dpkg-query -f '$${source:Package} (= $${source:Version}),
> \n' -W liblzo2-dev)
>
> ...
>
> override_dh_gencontrol:
> dh_gencontrol -- -VBuilt-Using="$(BUILT_USING)"
Yep, that's the way to do it, but you also need to define Built-Using in
debian/control. Please find attached a full patch to do that.
Regards
Aurelien
--
Aurelien Jarno GPG: 4096R/1DDD8C9B
[email protected] http://aurel32.net
--- e2fsprogs-1.47.2/debian/control
+++ e2fsprogs-1.47.2/debian/control
@@ -46,6 +46,7 @@
Package: e2fsck-static
Build-Profiles: <!pkg.e2fsprogs.no-static>
+Built-Using: ${misc:Built-Using}
Priority: optional
Depends: ${misc:Depends}
Recommends: sash | bash-static | zsh-static | busybox-static
--- e2fsprogs-1.47.2/debian/rules
+++ e2fsprogs-1.47.2/debian/rules
@@ -195,7 +195,7 @@
override_dh_gencontrol:
dh_gencontrol -pcomerr-dev -- -v${COMERR_VERSION}-${DEB_VERSION} -VmainBinary=${DEB_VERSION}
dh_gencontrol -pss-dev -- -v${SS_VERSION}-${DEB_VERSION} -VmainBinary=${DEB_VERSION}
- dh_gencontrol --remaining-packages
+ dh_gencontrol --remaining-packages -- -Vmisc:Built-Using="$(shell dpkg-query -f '$${source:Package} (= $${source:Version})' -W libc-dev-bin)"
override_dh_auto_test:
ifeq (,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))