summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorgy Yakovlev <ya@sysdump.net>2017-02-23 22:34:59 -0800
committerLars Wendler <polynomial-c@gentoo.org>2017-03-03 14:12:22 +0100
commit0ab0eccf1cba817194be494894987b02337eef3f (patch)
treec02d279aa43d1eb9bf316ff35abbe57c937639b0 /app-shells/fish/files/fish-2.5.0-honor-linguas.patch
parentapp-shells/fish: remove profile.env parser (diff)
downloadgentoo-0ab0eccf1cba817194be494894987b02337eef3f.tar.gz
gentoo-0ab0eccf1cba817194be494894987b02337eef3f.tar.bz2
gentoo-0ab0eccf1cba817194be494894987b02337eef3f.zip
app-shells/fish: add nls support
This adds nls useflag and includes backported upstream patch to honor LINGUAS. Fixes bug 409969. Closes: https://github.com/gentoo/gentoo/pull/4072
Diffstat (limited to 'app-shells/fish/files/fish-2.5.0-honor-linguas.patch')
-rw-r--r--app-shells/fish/files/fish-2.5.0-honor-linguas.patch32
1 files changed, 32 insertions, 0 deletions
diff --git a/app-shells/fish/files/fish-2.5.0-honor-linguas.patch b/app-shells/fish/files/fish-2.5.0-honor-linguas.patch
new file mode 100644
index 000000000000..843036d6e5d3
--- /dev/null
+++ b/app-shells/fish/files/fish-2.5.0-honor-linguas.patch
@@ -0,0 +1,32 @@
+diff --git a/Makefile.in b/Makefile.in
+index 35e63ae..b73c612 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -195,11 +195,16 @@ ifeq ($(shell uname), Darwin)
+ endif
+
+ #
+-# All translation message catalogs
++# All translation message catalogs, filter files based on LINGUAS.
+ #
+ TRANSLATIONS_SRC := $(wildcard po/*.po)
+-ifdef HAVE_GETTEXT
++ifeq ($(HAVE_GETTEXT), 1)
+ TRANSLATIONS := $(TRANSLATIONS_SRC:.po=.gmo)
++ifdef LINGUAS
++ TRANSLATIONS_ALL := $(TRANSLATIONS)
++ TRANSLATIONS_WANTED = $(patsubst %,po/%.gmo,$(LINGUAS))
++ TRANSLATIONS = $(filter $(TRANSLATIONS_WANTED),$(TRANSLATIONS_ALL))
++endif
+ else
+ TRANSLATIONS :=
+ endif
+@@ -764,7 +769,7 @@ uninstall: uninstall-translations | show-prefix show-bindir show-sysconfdir show
+ .PHONY: uninstall
+
+ install-translations: $(TRANSLATIONS) | show-HAVE_GETTEXT
+-ifdef HAVE_GETTEXT
++ifeq ($(HAVE_GETTEXT), 1)
+ @echo "Installing translations..."
+ $v for i in $(TRANSLATIONS); do \
+ $(INSTALL) -m 755 -d $(DESTDIR)$(localedir)/`basename $$i .gmo`/LC_MESSAGES; \