From: "Ludovic Courtès" <ludo@gnu.org>
To: 43737@debbugs.gnu.org
Cc: "Ludovic Courtès" <ludo@gnu.org>
Subject: [bug#43737] [PATCH 2/2] build: Use a 'guile' executable that doesn't warn about locales.
Date: Thu, 1 Oct 2020 10:38:48 +0200 [thread overview]
Message-ID: <20201001083848.27390-2-ludo@gnu.org> (raw)
In-Reply-To: <20201001083848.27390-1-ludo@gnu.org>
This gets rid of:
guile: warning: failed to install locale
when running the 'guix' command on a foreign distro where 'GUIX_LOCPATH'
isn't set.
* Makefile.am (pkglibexec_PROGRAMS, guile_SOURCES, guile_LDADD)
(guile_CFLAGS): New variables.
(install-exec-hook): New target.
(AUX_FILES): Remove 'guile-launcher.c'.
* configure.ac: Use 'GUILE_FLAGS'.
---
Makefile.am | 13 ++++++++++++-
configure.ac | 3 +++
2 files changed, 15 insertions(+), 1 deletion(-)
diff --git a/Makefile.am b/Makefile.am
index bc3efd2b6f..7aaf15cf8a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -47,6 +47,18 @@ scripts/guix: scripts/guix.in Makefile
$(AM_V_GEN)$(do_subst) < "$(srcdir)/$@.in" > "$@-t"
$(AM_V_at)chmod a+x,a-w "$@-t" && mv -f "$@-t" "$@"
+# This is our variant of the 'guile' executable, one that doesn't complain
+# about locales.
+pkglibexec_PROGRAMS = guile
+guile_SOURCES = gnu/packages/aux-files/guile-launcher.c
+guile_LDADD = $(GUILE_LIBS)
+guile_CFLAGS = $(GUILE_CFLAGS)
+
+# Have the 'guix' command refer to our 'guile'.
+install-exec-hook:
+ $(SED) -i "$(DESTDIR)$(bindir)/guix" \
+ -e 's,^#![[:graph:]]\+,#!$(pkglibexecdir)/guile,g'
+
nodist_noinst_SCRIPTS = \
pre-inst-env \
test-env
@@ -330,7 +342,6 @@ dist_noinst_DATA = \
# Auxiliary files for packages.
AUX_FILES = \
- gnu/packages/aux-files/guile-launcher.c \
gnu/packages/aux-files/chromium/master-preferences.json \
gnu/packages/aux-files/emacs/guix-emacs.el \
gnu/packages/aux-files/linux-libre/5.8-arm.conf \
diff --git a/configure.ac b/configure.ac
index adca374619..6861112eaf 100644
--- a/configure.ac
+++ b/configure.ac
@@ -105,6 +105,9 @@ if test "x$GUILE_EFFECTIVE_VERSION" = "x2.2"; then
PKG_CHECK_MODULES([GUILE], [guile-2.2 >= 2.2.3])
fi
+dnl Get CFLAGS and LDFLAGS for libguile.
+GUILE_FLAGS
+
dnl Installation directories for .scm and .go files.
guilemoduledir="${datarootdir}/guile/site/$GUILE_EFFECTIVE_VERSION"
guileobjectdir="${libdir}/guile/$GUILE_EFFECTIVE_VERSION/site-ccache"
--
2.28.0
next prev parent reply other threads:[~2020-10-01 8:40 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-01 8:35 [bug#43737] [PATCH 0/2] Getting rid of Guile's locale warning Ludovic Courtès
2020-10-01 8:38 ` [bug#43737] [PATCH 1/2] self: Use a 'guile' that doesn't complain about locales Ludovic Courtès
2020-10-01 8:38 ` Ludovic Courtès [this message]
2020-10-01 11:31 ` [bug#43737] [PATCH 0/2] Getting rid of Guile's locale warning Lars-Dominik Braun
2020-10-06 12:26 ` bug#43737: " Ludovic Courtès
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
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201001083848.27390-2-ludo@gnu.org \
--to=ludo@gnu.org \
--cc=43737@debbugs.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 public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).