mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-11-09 18:47:16 -08:00
media-gfx/gimp: Generate en_US.UTF-8 instead of requiring it
gen-languages needs en_US.UTF-8 at build time. If it was not installed, pkg_setup fell back to the user's locale or died. Generate it instead. Bug: https://bugs.gentoo.org/969468 Signed-off-by: Matt Turner <mattst88@gentoo.org>
This commit is contained in:
@@ -7,7 +7,7 @@ LUA_COMPAT=( luajit )
|
||||
PYTHON_COMPAT=( python3_{12..15} )
|
||||
VALA_USE_DEPEND=vapigen
|
||||
|
||||
inherit branding flag-o-matic lua-single meson python-single-r1 shell-completion toolchain-funcs vala xdg
|
||||
inherit branding flag-o-matic locale-utils lua-single meson python-single-r1 shell-completion toolchain-funcs vala xdg
|
||||
|
||||
DESCRIPTION="GNU Image Manipulation Program"
|
||||
HOMEPAGE="https://www.gimp.org/"
|
||||
@@ -164,21 +164,6 @@ pkg_pretend() {
|
||||
pkg_setup() {
|
||||
if [[ ${MERGE_TYPE} != binary ]]; then
|
||||
use openmp && tc-check-openmp
|
||||
|
||||
# bug #969468
|
||||
local locales="$(locale -a)"
|
||||
if ! has "en_US.utf8" ${locales} && ! has "en_US.UTF-8" ${locales}; then
|
||||
# portage splits and unset LC_ALL. Cannot rely on that
|
||||
if [[ "${LANG}" != "C" ]] && [[ "${LANG}" != "POSIX" ]] && [[ "${LANG}" == "${LANG#C\.}" ]]; then
|
||||
# Set LC_ALL to avoid locales breaking due to the profile setting LC_MESSAGES=C
|
||||
# and portage itself setting LC_COLLATE=C
|
||||
einfo "Setting LC_ALL=${LANG} based on LANG because en_US.UTF-8 isn't available, bug #968468"
|
||||
export LC_ALL="${LANG}"
|
||||
else
|
||||
eerror "Cannot use LANG=${LANG} as it cannot be C or POSIX"
|
||||
die "en_US.UTF-8 isn't available and cannot fallback to user locale, bug #969468"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
python-single-r1_pkg_setup
|
||||
@@ -266,6 +251,10 @@ src_configure() {
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
# gen-languages needs en_US.UTF-8, bug #969468
|
||||
local -x LOCPATH
|
||||
elocale_gen en_US.UTF-8
|
||||
|
||||
export XDG_DATA_DIRS="${EPREFIX}"/usr/share # bug 587004
|
||||
meson_src_compile
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ LUA_COMPAT=( luajit )
|
||||
PYTHON_COMPAT=( python3_{12..15} )
|
||||
VALA_USE_DEPEND=vapigen
|
||||
|
||||
inherit branding flag-o-matic lua-single meson python-single-r1 shell-completion toolchain-funcs vala xdg
|
||||
inherit branding flag-o-matic locale-utils lua-single meson python-single-r1 shell-completion toolchain-funcs vala xdg
|
||||
|
||||
DESCRIPTION="GNU Image Manipulation Program"
|
||||
HOMEPAGE="https://www.gimp.org/"
|
||||
@@ -164,21 +164,6 @@ pkg_pretend() {
|
||||
pkg_setup() {
|
||||
if [[ ${MERGE_TYPE} != binary ]]; then
|
||||
use openmp && tc-check-openmp
|
||||
|
||||
# bug #969468
|
||||
local locales="$(locale -a)"
|
||||
if ! has "en_US.utf8" ${locales} && ! has "en_US.UTF-8" ${locales}; then
|
||||
# portage splits and unset LC_ALL. Cannot rely on that
|
||||
if [[ "${LANG}" != "C" ]] && [[ "${LANG}" != "POSIX" ]] && [[ "${LANG}" == "${LANG#C\.}" ]]; then
|
||||
# Set LC_ALL to avoid locales breaking due to the profile setting LC_MESSAGES=C
|
||||
# and portage itself setting LC_COLLATE=C
|
||||
einfo "Setting LC_ALL=${LANG} based on LANG because en_US.UTF-8 isn't available, bug #968468"
|
||||
export LC_ALL="${LANG}"
|
||||
else
|
||||
eerror "Cannot use LANG=${LANG} as it cannot be C or POSIX"
|
||||
die "en_US.UTF-8 isn't available and cannot fallback to user locale, bug #969468"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
python-single-r1_pkg_setup
|
||||
@@ -265,6 +250,10 @@ src_configure() {
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
# gen-languages needs en_US.UTF-8, bug #969468
|
||||
local -x LOCPATH
|
||||
elocale_gen en_US.UTF-8
|
||||
|
||||
export XDG_DATA_DIRS="${EPREFIX}"/usr/share # bug 587004
|
||||
meson_src_compile
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ LUA_COMPAT=( luajit )
|
||||
PYTHON_COMPAT=( python3_{12..15} )
|
||||
VALA_USE_DEPEND=vapigen
|
||||
|
||||
inherit branding flag-o-matic lua-single meson python-single-r1 shell-completion toolchain-funcs vala xdg
|
||||
inherit branding flag-o-matic locale-utils lua-single meson python-single-r1 shell-completion toolchain-funcs vala xdg
|
||||
|
||||
DESCRIPTION="GNU Image Manipulation Program"
|
||||
HOMEPAGE="https://www.gimp.org/"
|
||||
@@ -164,21 +164,6 @@ pkg_pretend() {
|
||||
pkg_setup() {
|
||||
if [[ ${MERGE_TYPE} != binary ]]; then
|
||||
use openmp && tc-check-openmp
|
||||
|
||||
# bug #969468
|
||||
local locales="$(locale -a)"
|
||||
if ! has "en_US.utf8" ${locales} && ! has "en_US.UTF-8" ${locales}; then
|
||||
# portage splits and unset LC_ALL. Cannot rely on that
|
||||
if [[ "${LANG}" != "C" ]] && [[ "${LANG}" != "POSIX" ]] && [[ "${LANG}" == "${LANG#C\.}" ]]; then
|
||||
# Set LC_ALL to avoid locales breaking due to the profile setting LC_MESSAGES=C
|
||||
# and portage itself setting LC_COLLATE=C
|
||||
einfo "Setting LC_ALL=${LANG} based on LANG because en_US.UTF-8 isn't available, bug #968468"
|
||||
export LC_ALL="${LANG}"
|
||||
else
|
||||
eerror "Cannot use LANG=${LANG} as it cannot be C or POSIX"
|
||||
die "en_US.UTF-8 isn't available and cannot fallback to user locale, bug #969468"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
python-single-r1_pkg_setup
|
||||
@@ -265,6 +250,10 @@ src_configure() {
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
# gen-languages needs en_US.UTF-8, bug #969468
|
||||
local -x LOCPATH
|
||||
elocale_gen en_US.UTF-8
|
||||
|
||||
export XDG_DATA_DIRS="${EPREFIX}"/usr/share # bug 587004
|
||||
meson_src_compile
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user