From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
To: Guix-devel <guix-devel@gnu.org>
Subject: [PATCH]: fix python-matplotlib install-doc phase
Date: Wed, 18 Feb 2015 11:52:41 +0100 [thread overview]
Message-ID: <idjlhjvjxty.fsf@bimsb-sys02.mdc-berlin.net> (raw)
[-- Attachment #1: Type: text/plain, Size: 491 bytes --]
Hi Guix,
attached is a patch to fix the install-doc phase of python-matplotlib.
Since UTF locales are no longer available by default the install-doc
phase fails as it depends on setting the locale to en_US.UTF-8.
The attached patch installs the locale before it is set, thereby fixing
the phase.
We likely won't be able to see the effect of this fix on hydra because
numpy fails to build, which is an input to matplotlib, but at least
matplotlib can now be compiled locally.
~~ Ricardo
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnu-matplotlib-install-UTF-8-locale.patch --]
[-- Type: text/x-patch, Size: 1309 bytes --]
From 31f9b8800de32cdbd1fd3d2266f5fbb41548dccc Mon Sep 17 00:00:00 2001
From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
Date: Wed, 18 Feb 2015 11:47:40 +0100
Subject: [PATCH] gnu: matplotlib: install UTF-8 locale.
* gnu/packages/python.scm (python-matplotlib): Install en_US.UTF-8 locale in
install-doc phase to avoid encoding error.
---
gnu/packages/python.scm | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 6fe524e..7dc7435 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -2259,7 +2259,11 @@ backend = GTK3Agg~%")))))
(info (string-append data "/info"))
(html (string-append doc "/html")))
(with-directory-excursion "doc"
- ;; Without setting this variable we get an encoding error.
+ ;; Install and set UTF-8 locale to avoid an encoding error.
+ (setenv "LOCPATH" (getcwd))
+ (system* "localedef" "--no-archive"
+ "--prefix" (getcwd) "-i" "en_US"
+ "-f" "UTF-8" "./en_US.UTF-8")
(setenv "LANG" "en_US.UTF-8")
;; Produce pdf in 'A4' format.
(substitute* (find-files "." "conf\\.py")
--
2.1.0
next reply other threads:[~2015-02-18 10:53 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-18 10:52 Ricardo Wurmus [this message]
2015-02-18 18:14 ` [PATCH]: fix python-matplotlib install-doc phase Andreas Enge
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=idjlhjvjxty.fsf@bimsb-sys02.mdc-berlin.net \
--to=ricardo.wurmus@mdc-berlin.de \
--cc=guix-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.