vapier      15/08/29 23:05:43

  Modified:             locale-gen
  Log:
  drop support for /etc/locales.build

Revision  Changes    Path
1.39                 src/patchsets/glibc/extra/locale/locale-gen

file : 
http://sources.gentoo.org/viewvc.cgi/gentoo/src/patchsets/glibc/extra/locale/locale-gen?rev=1.39&view=markup
plain: 
http://sources.gentoo.org/viewvc.cgi/gentoo/src/patchsets/glibc/extra/locale/locale-gen?rev=1.39&content-type=text/plain
diff : 
http://sources.gentoo.org/viewvc.cgi/gentoo/src/patchsets/glibc/extra/locale/locale-gen?r1=1.38&r2=1.39

Index: locale-gen
===================================================================
RCS file: /var/cvsroot/gentoo/src/patchsets/glibc/extra/locale/locale-gen,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -r1.38 -r1.39
--- locale-gen  29 Aug 2015 04:44:58 -0000      1.38
+++ locale-gen  29 Aug 2015 23:05:43 -0000      1.39
@@ -52,7 +52,7 @@
 }
 show_version() {
        local b="(" a=")"
-       local cvsver="$Revision: 1.38 $b $Date: 2015/08/29 04:44:58 $a"
+       local cvsver="$Revision: 1.39 $b $Date: 2015/08/29 23:05:43 $a"
        echo "locale-gen-${cvsver//: }"
        exit 0
 }
@@ -168,15 +168,7 @@
        exit 1
 fi
 
-
-
-if [[ ${QUIET} -eq 0 ]] && [[ -z ${JUST_LIST} ]] && \
-   [[ -e ${EROOT}etc/locales.build ]]
-then
-       ewarn "You should upgrade your /etc/locales.build to /etc/locale.gen"
-       ewarn "and then remove /etc/locales.build when you're done.\n"
-fi
-
+# Only generate locales the user specified before falling back to the config.
 locales_to_generate=${GENERATE}
 
 if [[ -z ${locales_to_generate} ]] && [[ -e ${CONFIG} ]] ; then
@@ -197,47 +189,9 @@
 fi
 
 if [[ -z ${locales_to_generate} ]] ; then
-       #
-       # NOTE: begin retarded situation
-       # if user does not have locale.gen setup, but they have a
-       # locales.build, and they have USE=-userlocales, then they
-       # probably have the default locales.build file.  the problem
-       # with this is the default locales.build had a bunch of
-       # uncommented locales, so the resulting system will end up
-       # with only a few locales and the user will be left wondering
-       # wtf just happened.  so our hack logic here is:
-       #  - if we are outside of ebuild (i.e. user ran us) then go for it
-       #  - if we are inside of ebuild and USE=-userlocales, then just bail
-       #
-
-       # if these vars are set we just assume in ebuild
-       if [[ ${PN} == "glibc" && -n ${FILESDIR} && -n ${D} ]] ; then
-               has() { [[ " ${*:2} " == *" $1 "* ]] ; }
-               ! has userlocales ${USE} && CONFIG=""
-       fi
-
-       if [[ ${CONFIG} == */etc/locale.gen ]] ; then
-               CONFIG=${CONFIG/%locale.gen/locales.build}
-               if [[ -e ${CONFIG} ]] ; then
-                       locales_to_generate=$(sed \
-                               -e 's:#.*::' \
-                               -e '/^[[:space:]]*$/d' \
-                               -e 's:/: :g' \
-                               "${CONFIG}")
-               fi
-               if [[ -n ${locales_to_generate} ]] && \
-                  [[ ${QUIET} -eq 0 ]] && [[ -z ${JUST_LIST} ]]
-               then
-                       ewarn "Automatically importing locales from 
/etc/locales.build ..."
-                       ewarn "You really should do this yourself ...\n"
-               fi
-       fi
-
-       if [[ -z ${locales_to_generate} ]] ; then
-               [[ ${QUIET} -eq 0 ]] && [[ -z ${JUST_LIST} ]] && \
-                       ewarn "No locales found"
-               exit 0
-       fi
+       [[ ${QUIET} -eq 0 ]] && [[ -z ${JUST_LIST} ]] && \
+               ewarn "No locales found"
+       exit 0
 fi
 
 mkdir -p "${LOCALEDIR}"




Reply via email to