From 420df2a7a7b7938d96c6c238b5655acb52ce4a3c Mon Sep 17 00:00:00 2001 From: Your Name Date: Tue, 4 Oct 2016 21:28:25 +0200 Subject: [PATCH] Add hook for locales update after glibc update --- hooks/ebuild_postinst_post/glibc-update-locales.bash | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 hooks/ebuild_postinst_post/glibc-update-locales.bash diff --git a/hooks/ebuild_postinst_post/glibc-update-locales.bash b/hooks/ebuild_postinst_post/glibc-update-locales.bash new file mode 100644 index 0000000..686d8ed --- /dev/null +++ b/hooks/ebuild_postinst_post/glibc-update-locales.bash @@ -0,0 +1,11 @@ +#!/bin/bash + +if [[ ${CATEGORY}/${PN} == "sys-libs/glibc" ]] ; then + einfo "Updating locales" + for _mylang in $(locale -a) ; do + if [[ ${_mylang} =~ "utf8" ]] ; then + edo localedef -i ${_mylang%.*} -f UTF-8 ${_mylang%.*}.UTF-8 + fi + done +fi +