Dropping versioned docdir for license files?

  • Open
  • quality assurance status badge
Details
3 participants
  • Ludovic Courtès
  • Maxim Cournoyer
  • Maxime Devos
Owner
unassigned
Submitted by
Maxim Cournoyer
Severity
normal
M
M
Maxim Cournoyer wrote on 3 Mar 2022 14:37
(name . bug-guix)(address . bug-guix@gnu.org)
87pmn3i2cc.fsf@gmail.com
Hello Guix,

Recently while packaging sysbench, I noticed that the gnu-build-system's
docdir expands to 'share/doc/name', while the 'install-license-files'
phase installs the license files to 'share/doc/name-version' instead:

Toggle snippet (27 lines)
$ find /gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/bin
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/bin/sysbench
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/etc
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/etc/ld.so.cache
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/doc
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/doc/sysbench
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/doc/sysbench/manual.html
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/doc/sysbench-1.0.20
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/doc/sysbench-1.0.20/COPYING
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/bulk_insert.lua
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/oltp_delete.lua
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/oltp_insert.lua
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/oltp_read_only.lua
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/oltp_point_select.lua
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/oltp_update_index.lua
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/oltp_read_write.lua
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/oltp_update_non_index.lua
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/select_random_points.lua
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/select_random_ranges.lua
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/oltp_write_only.lua
/gnu/store/97q84ivbx8xa2lm3pn4pyb3i96n58i5g-sysbench-1.0.20/share/sysbench/oltp_common.lua

It seems to me it'd be nicer to have both agree on the same docdir. We
could drop the version and use gnu-build-system's docdir, or alter the
default gnu-build-system docdir to use a versioned output. The later
some more troublesome, as we'd have to do the same adjustment for each
build system, and I'm not convinced of the value added. So I'd suggest
we simply normalize to use the standard docdir.

What do you think?

Thanks,

Maxim
M
M
Maxime Devos wrote on 3 Mar 2022 15:43
7e78d92da1916fc769f4fa9dcf70fabd18e387fa.camel@telenet.be
Maxim Cournoyer schreef op do 03-03-2022 om 08:37 [-0500]:
Toggle quote (9 lines)
> It seems to me it'd be nicer to have both agree on the same docdir.  We
> could drop the version and use gnu-build-system's docdir, or alter the
> default gnu-build-system docdir to use a versioned output.  The later
> some more troublesome, as we'd have to do the same adjustment for each
> build system, and I'm not convinced of the value added.  So I'd suggest
> we simply normalize to use the standard docdir.
>
> What do you think?

This does not really answer your question, but if we do this, we could
combine this with another change:

Some software does not work with a COPYING or LICENSE file, or they do
but also have other relevant licenses. E.g., gnunet-scheme follows
REUSE and puts the license texts in a LICENSES directory and some extra
information in '.reuse/dep5'. It would be nice if those were copied
as well.

Also, to partially answer your question: probably not all
gnu-build-system packages actually implement the 'docdir' option
and might even error out if it is passed. Fixing these build failures
might be tedious.

Greetings,
Maxime.
-----BEGIN PGP SIGNATURE-----

iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYiDUIBccbWF4aW1lZGV2
b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7uLBAQC2rXgNCs+FLb28OFzdS7zCgtCB
cdxTGv7Qhl/pXxi+9AD/eztAoupV0ExPJ5XkseKjrT2TyOVzoNGJE6Mi6/ONjQM=
=POFD
-----END PGP SIGNATURE-----


M
M
Maxim Cournoyer wrote on 3 Mar 2022 16:44
(name . Maxime Devos)(address . maximedevos@telenet.be)(address . 54234@debbugs.gnu.org)
87h78fhwh3.fsf@gmail.com
Hi Maxime,

Maxime Devos <maximedevos@telenet.be> writes:

Toggle quote (19 lines)
> Maxim Cournoyer schreef op do 03-03-2022 om 08:37 [-0500]:
>> It seems to me it'd be nicer to have both agree on the same docdir.  We
>> could drop the version and use gnu-build-system's docdir, or alter the
>> default gnu-build-system docdir to use a versioned output.  The later
>> some more troublesome, as we'd have to do the same adjustment for each
>> build system, and I'm not convinced of the value added.  So I'd suggest
>> we simply normalize to use the standard docdir.
>>
>> What do you think?
>
> This does not really answer your question, but if we do this, we could
> combine this with another change:
>
> Some software does not work with a COPYING or LICENSE file, or they do
> but also have other relevant licenses. E.g., gnunet-scheme follows
> REUSE and puts the license texts in a LICENSES directory and some extra
> information in '.reuse/dep5'. It would be nice if those were copied
> as well.

What is REUSE?

Toggle quote (5 lines)
> Also, to partially answer your question: probably not all
> gnu-build-system packages actually implement the 'docdir' option
> and might even error out if it is passed. Fixing these build failures
> might be tedious.

Even the packages using their own configure script probably would
install their doc under /share/doc/$name/ as this is the standard on FHS
distribution. I'm not suggesting to tweak docdir, I'm suggesting to use
the default, non-versioned value.

Thanks,

Maxim
M
M
Maxime Devos wrote on 3 Mar 2022 16:59
(name . Maxim Cournoyer)(address . maxim.cournoyer@gmail.com)(address . 54234@debbugs.gnu.org)
e20f1e1f04cec8c9e026c830d92a4c3149d5f507.camel@telenet.be
Maxim Cournoyer schreef op do 03-03-2022 om 10:44 [-0500]:
Toggle quote (2 lines)
> What is REUSE?

See https://reuse.software/. It's a specification + tool based on
SPDX.

Greetings,
Maxime.
-----BEGIN PGP SIGNATURE-----

iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYiDl3RccbWF4aW1lZGV2
b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7pJCAP9C9QIKaWQoseNzLCgYq6b/8NxU
xs3IXPDxBuVmExvQFAD+KgjPZ14VA1FZk/pDvE2kIFY10eVNFPPV54oirbSXEww=
=Ct1R
-----END PGP SIGNATURE-----


L
L
Ludovic Courtès wrote on 15 Mar 2022 14:55
Different license file name
(name . Maxime Devos)(address . maximedevos@telenet.be)
87sfrjjp61.fsf_-_@gnu.org
Hi,

Maxime Devos <maximedevos@telenet.be> skribis:

Toggle quote (6 lines)
> Some software does not work with a COPYING or LICENSE file, or they do
> but also have other relevant licenses. E.g., gnunet-scheme follows
> REUSE and puts the license texts in a LICENSES directory and some extra
> information in '.reuse/dep5'. It would be nice if those were copied
> as well.

You can use the #:license-file-regexp argument of ‘gnu-build-system’ in
such a case.

If the file name becomes common, we can update the default
‘%license-file-regexp’ in ‘core-updates’.

HTH,
Ludo’.
L
L
Ludovic Courtès wrote on 15 Mar 2022 14:56
Re: bug#54234: Dropping versioned docdir for license files?
(name . Maxim Cournoyer)(address . maxim.cournoyer@gmail.com)(address . 54234@debbugs.gnu.org)
87o827jp4y.fsf@gnu.org
Hi,

Maxim Cournoyer <maxim.cournoyer@gmail.com> skribis:

Toggle quote (4 lines)
> Recently while packaging sysbench, I noticed that the gnu-build-system's
> docdir expands to 'share/doc/name', while the 'install-license-files'
> phase installs the license files to 'share/doc/name-version' instead:

[...]

Toggle quote (7 lines)
> It seems to me it'd be nicer to have both agree on the same docdir. We
> could drop the version and use gnu-build-system's docdir, or alter the
> default gnu-build-system docdir to use a versioned output. The later
> some more troublesome, as we'd have to do the same adjustment for each
> build system, and I'm not convinced of the value added. So I'd suggest
> we simply normalize to use the standard docdir.

Fine with me! We can do that in ‘core-updates’.

Ludo’.
?