diff options
author | Maciej Barć <xgqt@gentoo.org> | 2023-12-17 21:44:26 +0100 |
---|---|---|
committer | Maciej Barć <xgqt@gentoo.org> | 2023-12-17 22:45:45 +0100 |
commit | 1cfe887e6e91c7602cd79be7bfad0999d64114f4 (patch) | |
tree | c0b90d3734c8c45f583025c1de3508ca124b05e3 /dev-dotnet | |
parent | dev-lang/mond: bump DOTNET_PKG_COMPAT to 8.0 (diff) | |
download | gentoo-1cfe887e6e91c7602cd79be7bfad0999d64114f4.tar.gz gentoo-1cfe887e6e91c7602cd79be7bfad0999d64114f4.tar.bz2 gentoo-1cfe887e6e91c7602cd79be7bfad0999d64114f4.zip |
dev-dotnet/dotnet-sdk: set locale to en_US
Closes: https://bugs.gentoo.org/920202
Signed-off-by: Maciej Barć <xgqt@gentoo.org>
Diffstat (limited to 'dev-dotnet')
-rw-r--r-- | dev-dotnet/dotnet-sdk/dotnet-sdk-8.0.100-r1.ebuild | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/dev-dotnet/dotnet-sdk/dotnet-sdk-8.0.100-r1.ebuild b/dev-dotnet/dotnet-sdk/dotnet-sdk-8.0.100-r1.ebuild index 7f79a934a917..82a0daec3c76 100644 --- a/dev-dotnet/dotnet-sdk/dotnet-sdk-8.0.100-r1.ebuild +++ b/dev-dotnet/dotnet-sdk/dotnet-sdk-8.0.100-r1.ebuild @@ -81,6 +81,24 @@ pkg_setup() { check-reqs_pkg_setup llvm_pkg_setup python-any-r1_pkg_setup + + if [[ "${MERGE_TYPE}" != binary ]] ; then + local locales="$(locale -a)" + + if has en_US.utf8 ${locales} ; then + LC_ALL=en_US.utf8 + elif has en_US.UTF-8 ${locales} ; then + LC_ALL=en_US.UTF-8 + else + eerror "The locale en_US.utf8 or en_US.UTF-8 is not available." + eerror "Please generate en_US.UTF-8 before building ${CATEGORY}/${P}." + + die "Could not switch to the en_US.UTF-8 locale." + fi + + export LC_ALL + einfo "Successfully switched to the ${LC_ALL} locale." + fi } src_prepare() { |