Bug#681289: debian-policy: Changelog and copyright should be package metadata
On Thu, 12 Jul 2012, Russ Allbery wrote:
> HOWEVER, I think putting those files in a clear place on the file system
> so that they can be easily read via a pager by the end user without using
> dpkg-query commands is not only mandatory for the transition period but
> mandatory permanently. I would expect dpkg to do this. That location
> could be in /var/lib/dpkg/copyright and /var/lib/dpkg/changelogs or some
> similar place, however. (And arch-qualified when needed, of course.)
The current version of dpkg would put them in
/var/lib/dpkg/info/<pkg>.{changelog,copyright} but we certainly don't want
end-users to rely on this.
Guillem introduced the --control-list and --control-show interfaces
precisely because we want a path and storage-agnostic way to access those
files. This enables us to change the way we store files in a more
efficient manner:
- we could compress the files with whatever compression method we want
- we could deduplicate identical files between multiple packages
(copyright and changelog files within a source package tend to be identical)
If we want to keep the copyright/changelog files at their current location
(or in another official place), we should IMO create a new package that
will hook into dpkg --post-invoke and that would use dpkg-query
--control-show to retrieve those files and store them again where the user
wants (and conversely delete them during package removal).
BTW, dpkg-query --control-show already runs a pager if the output is a
terminal. In any case, I believe we should create dpkg --changelog
and dpkg --copyright as the canonical end-user interface.
Cheers,
--
Raphaël Hertzog ◈ Debian Developer
Get the Debian Administrator's Handbook:
→ http://debian-handbook.info/get/
Reply to: