sys-apps/musl-locales: Create env file

With vimproved's work to add musl-locale to @system, it also make sense to streamline the install process for users so the env file is created during the install.

I've choosen to -r1 to make it easier to track issues that might occur, even if it likely is overkill for env file.

Signed-off-by: Ian Jordan <immoloism@gmail.com>
Part-of: https://github.com/gentoo/gentoo/pull/42911
Closes: https://github.com/gentoo/gentoo/pull/42911
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Ian Jordan
2025-07-07 06:37:14 +00:00
committed by Sam James
parent 23d431920a
commit a895461d3a

View File

@@ -0,0 +1,32 @@
# Copyright 2023-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit cmake
DESCRIPTION="Locale program for musl libc"
HOMEPAGE="https://git.adelielinux.org/adelie/musl-locales"
SRC_URI="https://git.adelielinux.org/adelie/musl-locales/uploads/7e855b894b18ca4bf4ecb11b5bcbc4c1/${P}.tar.xz"
LICENSE="LGPL-3 MIT"
SLOT="0"
KEYWORDS="~amd64 ~arm ~arm64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~x86"
RDEPEND="!sys-libs/glibc"
src_configure() {
local mycmakeargs=(
-DLOCALE_PROFILE=OFF
)
cmake_src_configure
}
src_install() {
echo "MUSL_LOCPATH=\"/usr/share/i18n/locales/musl\"" | newenvd - 00locale
}
pkg_postinst() {
elog "Run . /etc/profile and then eselect locale list"
elog "to see available locales to use with musl. "
}