From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marius Bakke Subject: bug#30785: Man pages truncated, repeated Date: Sat, 05 May 2018 23:40:51 +0200 Message-ID: <878t8xhjbw.fsf@fastmail.com> References: <4a0d5e493db8af05dd2292b854ad7d3d@tobias.gr> <87zi3advd9.fsf@fastmail.com> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:35015) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fF4vS-0000B4-N9 for bug-guix@gnu.org; Sat, 05 May 2018 17:41:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fF4vO-0006lh-Np for bug-guix@gnu.org; Sat, 05 May 2018 17:41:06 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:42990) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fF4vO-0006lX-EH for bug-guix@gnu.org; Sat, 05 May 2018 17:41:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fF4vO-0004DE-84 for bug-guix@gnu.org; Sat, 05 May 2018 17:41:02 -0400 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <87zi3advd9.fsf@fastmail.com> List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: "bug-Guix" To: Tobias Geerinckx-Rice , 30785@debbugs.gnu.org --==-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Marius Bakke writes: > Tobias Geerinckx-Rice writes: > >> Guix, >> >> Perhaps he's just getting old, but our man has a tendency to forget=20 >> where he was, start over from the beginning, and repeat himself several= =20 >> times: >> >> $ guix package -i knot rofi >> $ man 5 knot.conf | grep -E '^(NAME|DESCRIPTION)' >> NAME >> DESCRIPTION >> NAME >> DESCRIPTION >> NAME >> DESCRIPTION >> NAME >> DESCRIPTION >> NAME >> $ > > One thing rofi.1 and knot.conf.5 have in common is that they are both > unicode. Whereas working pages are ASCII. This ultimately turned out to be due to man-db not finding "preconv". The attached patches fixes it. Adding preconv adds ~0.1 MiB to the groff-minimal closure size. WDYT? --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=bug-30785.patch Content-Transfer-Encoding: quoted-printable From=2042b43fca11ab1f9417499aea252ae7a871a53b1b Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Sat, 5 May 2018 23:13:16 +0200 Subject: [PATCH 1/2] gnu: groff-minimal: Preserve 'preconv' executable. * gnu/packages/groff.scm (groff-minimal)[arguments]: Add 'preconv' to the l= ist of kept programs. =2D-- gnu/packages/groff.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/groff.scm b/gnu/packages/groff.scm index 5f1b8d0ed..77728a5d7 100644 =2D-- a/gnu/packages/groff.scm +++ b/gnu/packages/groff.scm @@ -101,7 +101,7 @@ is usually the formatter of \"man\" documentation pages= .") ;; Keep only the programs that man-db needs at run time, ;; and make sure we don't pull in Perl. (let ((out (assoc-ref outputs "out")) =2D (kept '("eqn" "neqn" "pic" "tbl" "refer" + (kept '("eqn" "neqn" "pic" "tbl" "refer" "preconv" "nroff" "groff" "troff" "grotty"))) (for-each (lambda (file) (unless (member (basename file) kept) =2D-=20 2.17.0 From=20095d0db7db77261f59e6582af3a9b18b61dcb630 Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Sat, 5 May 2018 23:30:04 +0200 Subject: [PATCH 2/2] gnu: man-db: Embed absolute reference to 'preconv'. Fixes . Reported by Tobias Geerinckx-Rice . * gnu/packages/man.scm (man-db)[arguments]: Rename 'patch-iconv-path' to 'patch-absolute-paths'. Add substitution for "preconv". =2D-- gnu/packages/man.scm | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/gnu/packages/man.scm b/gnu/packages/man.scm index ca6fd351d..f0bb2b66e 100644 =2D-- a/gnu/packages/man.scm +++ b/gnu/packages/man.scm @@ -80,11 +80,19 @@ a flexible and convenient way.") (string-append "#!" (which "sh"))))) (remove file-is-directory? (find-files "src/tests" ".*")))))) =2D (add-after 'unpack 'patch-iconv-path + (add-after 'unpack 'patch-absolute-paths (lambda* (#:key inputs #:allow-other-keys) (substitute* "src/man.c" (("\"iconv\"") (string-append "\"" (which "iconv") "\""))) + ;; Embed an absolute reference to "preconv", otherwise it + ;; falls back to searching in PATH and ultimately fails + ;; to render unicode data (see ). + (substitute* "lib/encodings.c" + (("groff_preconv =3D NULL") + (string-append "groff_preconv =3D \"" + (assoc-ref inputs "groff-minimal") + "/bin/preconv\""))) #t))) #:configure-flags (let ((groff (assoc-ref %build-inputs "groff")) =2D-=20 2.17.0 --=-=-=-- --==-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAlruJOMACgkQoqBt8qM6 VPomNwf/aPyVJbCl09RlxyEDuBUck6w8jtd/7QtsGaFKS2urESn9AmMYFuIQkOcq 1Zwdf25tPsARdyCvDV8vU6xgACMkttIsnIxowBI5ZSZZ/cl3xkrKhyMReWTWyfU6 fbH1l+SLtQ9BXBrZxbQ+cbHZcfQc/8tvzLNyC6A3jKcnWNlFmG/3anWOKBwzNTTl 8yfZHm1tN9cxo5cZ6dJvIkRo6EChuRN1WuMr0aqabRmx5CWy4la5VP4key9l4eaH xr9zhfGLeFqmqGoDlL2obXZmxPhBdFFriIDEJ0EcW0hXZ/efo+UPaEju26WlxhH5 o52SY3Z0+cK3IL5R+uln/cdFaqPnJQ== =RWfx -----END PGP SIGNATURE----- --==-=-=--