🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.gentoo.dev
Article #205

Re: [gentoo-dev] [PATCH 2/3] dune.eclass: use --docdir for dune install

#205
From: Sam James
Date: Thu, 19 Nov 2026 14:10
58 lines
3257 bytes
--=-=-=
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable

Thomas Bracht Laumann Jespersen <laumann@gentoo.org> writes:

> Instead of manually moving files from /usr/doc to /usr/share/doc/${PF},
> use the --docdir argument for "dune install". This ensure the generated
> dune-package file will reference the correct location of installed docs.

I wonder if maybe --docdir didn't exist for our minimum version of dune,
or at least a minimum version we specified in the past, then we forgot
to add it in?

>
> Signed-off-by: Thomas Bracht Laumann Jespersen <laumann@gentoo.org>
> ---
>  eclass/dune.eclass | 8 +-------
>  1 file changed, 1 insertion(+), 7 deletions(-)
>
> diff --git a/eclass/dune.eclass b/eclass/dune.eclass
> index 2bb6d4c3d2a3..98c508ee43ff 100644
> --- a/eclass/dune.eclass
> +++ b/eclass/dune.eclass
> @@ -170,18 +170,12 @@ dune-install() {
>  		--prefix=3D"${EPREFIX}/usr"
>  		--libdir=3D"$(ocamlc -where)"
>  		--mandir=3D"${EPREFIX}/usr/share/man"
> +		--docdir=3D"${EPREFIX}/usr/share/doc/${PF}"
>  	)
>=20=20
>  	local pkg
>  	for pkg in "${pkgs[@]}" ; do
>  		edune install ${myduneopts[@]} ${pkg}
> -
> -		# Move docs to the appropriate place.
> -		if [[ -d "${ED}/usr/doc/${pkg}" ]] ; then
> -			mkdir -p "${ED}/usr/share/doc/${PF}/" || die
> -			mv "${ED}/usr/doc/${pkg}" "${ED}/usr/share/doc/${PF}/" || die
> -			rm -rf "${ED}/usr/doc" || die
> -		fi
>  	done
>  }

--=-=-=
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQEBBAEWCgCpFiEEJaa7iN2bdkxrVUHCc4QJ9SDfkZAFAmr/ASEbFIAAAAAABAAO
bWFudTIsMi41KzEuMTIsMiwyXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25z
Lm9wZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQyNUE2QkI4OEREOUI3NjRDNkI1NTQx
QzI3Mzg0MDlGNTIwREY5MTkwDxxzYW1AZ2VudG9vLm9yZwAKCRBzhAn1IN+RkJZq
AP4/yUCjXenjgJQqLxmvSMRStuhELWRXODr4MtwmsjGapAD+M2flQ8cFGw5D/zwX
GNa8KLTMzAcmmBzESiGFsqa17gM=
=PWQY
-----END PGP SIGNATURE-----
--=-=-=--
Technical Details
Message-ID: <O1aZP-cTTA-15@gated-at.bofh.it>
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!news-lon.pugleaf.net!srl.newsdeef.eu!news.corradoroberto.it!diesel.cu.mi.it!bofh.it!news.nic.it!robomod
References: <O19AJ-cT6p-5@gated-at.bofh.it> <O19AJ-cT6p-21@gated-at.bofh.it>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!news-lon.pugleaf.net!srl.newsdeef.eu!news.corradoroberto.it!diesel.cu.mi.it!bofh.it!news.nic.it!robomod
From: Sam James <sam@gentoo.org>
Newsgroups: linux.gentoo.dev
Subject: Re: [gentoo-dev] [PATCH 2/3] dune.eclass: use --docdir for dune  install
Date: Thu, 19 Nov 2026 15:10:01 +0100
Message-ID: <O1aZP-cTTA-15@gated-at.bofh.it>
References: <O19AJ-cT6p-5@gated-at.bofh.it> <O19AJ-cT6p-21@gated-at.bofh.it>
X-Original-To: gentoo-dev@lists.gentoo.org
Organization: Gentoo
User-Agent: mu4e 1.14.4; emacs 32.0.50
List-ID: Gentoo Linux mail <gentoo-dev.gentoo.org>
Reply-To: gentoo-dev@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
MIME-Version: 1.0
Content-Type: multipart/signed; boundary="=-=-=";
	micalg=pgp-sha512; protocol="application/pgp-signature"
Approved: robomod@news.nic.it
Lines: 58
Sender: robomod@news.nic.it
X-Original-Cc: Thomas Bracht Laumann Jespersen <laumann@gentoo.org>
X-Original-Date: Thu, 19 Nov 2026 14:01:05 +0000
X-Original-Message-ID: <87cxs0x6n2.fsf@gentoo.org>
X-Original-References: <20261119-dune-eclass-install-v1-0-0c6b81eca2b1@gentoo.org>
	<20261119-dune-eclass-install-v1-2-0c6b81eca2b1@gentoo.org>