man-db-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Man-db-devel] man-db Guix package: preconv segfaults when hard-coded


From: Pierre Neidhardt
Subject: [Man-db-devel] man-db Guix package: preconv segfaults when hard-coded
Date: Mon, 14 Jan 2019 17:04:44 +0100
User-agent: mu4e 1.0; emacs 26.1

Hi,

I'm working on a bug that Guix (https://guix.info) has been experiencing
forever.

https://issues.guix.info/issue/30785

Long story short:  non-ASCII man pages don't display properly because
preconv (from groff) is not found.

Guix is not like most other distributions in that it's purely
functional, dependencies are not found in the PATH but they are
hard-coded.

man-db needs to find preconv.  So what we would typically do is patch
lib/encodings.c to point to preconv in the /gnu/store:


--8<---------------cut here---------------start------------->8---
(substitute* "lib/encodings.c"
               (("const char \\*groff_preconv = NULL;")
                (string-append "const char *groff_preconv = \""
                               (assoc-ref inputs "groff-minimal")
                               "/bin/preconv"
                               "\";")))
--8<---------------cut here---------------end--------------->8---

Surprisingly, man only displays this on every call:

--8<---------------cut here---------------start------------->8---
/gnu/store/6dv1q0s8rlf1ndaqx2qhnkiz9x4840ba-man-db-2.8.3/bin/man: 
/gnu/store/mpjn4jfx5i8jxblfj538n22hv56rdnhw-groff-minimal-1.22.3/bin/preconv: 
Segmentation fault
--8<---------------cut here---------------end--------------->8---

However, calling

--8<---------------cut here---------------start------------->8---
echo "hêlló"  | 
/gnu/store/mpjn4jfx5i8jxblfj538n22hv56rdnhw-groff-minimal-1.22.3/bin/preconv -e 
UTF-8
--8<---------------cut here---------------end--------------->8---

works.

It seems that it has something to do with libpipeline, but I'm not sure
what.

Is it wrong to create a pipeline with the full path to the executable?

--
Pierre Neidhardt
https://ambrevar.xyz/

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]