commit:     b971baa7f7d66a6dd5e33b3eeecd92678585fc59
Author:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
AuthorDate: Mon Jan  8 19:57:03 2018 +0000
Commit:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
CommitDate: Mon Jan  8 19:58:21 2018 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b971baa7

www-client/opera: Migrate from LINGUAS to L10N.

Map language codes for Montenegrin and Latin American Spanish from
their IETF language tags to the codes used by upstream.

This change affects only opera-12.16_p1860-r1.ebuild.

Closes: https://bugs.gentoo.org/583762
Package-Manager: Portage-2.3.19, Repoman-2.3.6

 www-client/opera/opera-12.16_p1860-r1.ebuild | 17 +++++++++++------
 1 file changed, 11 insertions(+), 6 deletions(-)

diff --git a/www-client/opera/opera-12.16_p1860-r1.ebuild 
b/www-client/opera/opera-12.16_p1860-r1.ebuild
index c9f7b87fbb7..fdba2080a17 100644
--- a/www-client/opera/opera-12.16_p1860-r1.ebuild
+++ b/www-client/opera/opera-12.16_p1860-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2017 Gentoo Foundation
+# Copyright 1999-2018 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=6
@@ -21,9 +21,9 @@ O_B="$(get_version_component_range 3)"   # Build number, i.e. 
1156
 O_K="noserch" # The key to the snapshot URL
 
 O_LINGUAS="
-       af ar az be bg bn cs da de el en-GB es-ES es-LA et fa fi fr fr-CA fy gd 
he
-       hi hr hu id it ja ka kk ko lt lv me mk ms nb nl nn pa pl pt pt-BR ro ru 
sk
-       sr sv sw ta te th tl tr uk ur uz vi zh-CN zh-TW zu
+       af ar az be bg bn cnr cs da de el en-GB es-419 es-ES et fa fi fr fr-CA 
fy
+       gd he hi hr hu id it ja ka kk ko lt lv mk ms nb nl nn pa pl pt pt-BR ro 
ru
+       sk sr sv sw ta te th tl tr uk ur uz vi zh-CN zh-TW zu
 " # Supported linguas
 
 # == End of variables that often change ==
@@ -55,7 +55,7 @@ else                                                  # 
release: _p
 fi
 
 for O_LINGUA in ${O_LINGUAS}; do
-       IUSE+=" linguas_${O_LINGUA/-/_}"
+       IUSE+=" l10n_${O_LINGUA}"
 done
 
 DEPEND="
@@ -113,7 +113,12 @@ src_prepare() {
 
        # Remove unwanted linguas
        for LINGUA in ${O_LINGUAS}; do
-               if ! use linguas_${LINGUA/-/_}; then
+               if ! use l10n_${LINGUA}; then
+                       # Remap codes for Montenegrin and Spanish (Latin 
America)
+                       case ${LINGUA} in
+                               cnr) LINGUA=me ;;
+                               es-419) LINGUA=es-LA ;;
+                       esac
                        LINGUA=$(find "${LNGDIR}" -maxdepth 1 -type d -iname 
${LINGUA/_/-})
                        rm -r "${LINGUA}" || die "The list of linguas needs to 
be fixed"
                fi

Reply via email to