On 28/09/12 23:46, Guillem Jover wrote: > On Fri, 2012-09-28 at 22:50:10 +0100, Nicholas Bamber wrote: >> On 28/09/12 21:55, Guillem Jover wrote: >>> As such, I'm going to be closing this request if there's no additional >>> feedback proposing a workable and elegant solution to this. > >> Thanks for responing. I think I can come up with a proposed mechanism. >> I'd be grateful if you'd allow me some time as it does not need to be in >> Debian before Wheezy is released. > > Sure thing, no hurry, it was more to do to with keeping the bts under > control and clean than anything related to the wheezy release. > > regards, > guillem
Problem ======= Debian Policy 3.9.4 (section 7.8) mandates the use of a "Built-Using" field listing source packages and their versions. Typically this will be needed where packages are statically linked against libraries, in which case the source package containing the library must be indicated. There may be other cases where source code is incorporated into a binary package. Techincally the shell script fragments incorporated into Debian maintance scripts by debhelper may fall into this category, although this may not be needed to solve the original issue. What this is like ================= This problem is a bit like that solved by dh_shlibdeps and dpkg-shlibdeps. The dependency can only actually be calcuated at build time. So without support from the build system the Debian Policy is not implementable. Proposed solution ================= We need a tool, dh_builtusing, which is driven by files of the form "debian/*.builtusing". These files are simply lists of files or directories that the build process depends on which trigger the requirements for filling the Built-Using clause. dh_builtusing would resolve these files into the appropriate dependency using PACKAGE=`dpkg-query -S ${FILE} | cut -d':' -f1` dpkg-query -f'${Source}\n${Version}\n' -W ${PACKAGE} and create substvars variables which would complete the information retrieval. It looks increasingly likely to me that this is purely a debhelper issue and dpkg already provides all that is required. Further automation ================== The typical use case my be expected to be a package using autoconf, libtools, pkg-config or something similar. I speculate that hooks could be added to those tools to create builtusing files. -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org