sys-devel/gnuconfig: Sync with Gentoo

It's from Gentoo commit 9c2ac27166873e185fccb4a15d5a54663e344e8f.
This commit is contained in:
Flatcar Buildbot 2025-08-04 07:19:46 +00:00 committed by Krzesimir Nowak
parent bd9fc58e4e
commit 1d7501eff8
2 changed files with 50 additions and 0 deletions

View File

@ -1 +1,2 @@
DIST gnuconfig-20240728.tar.xz 82360 BLAKE2B 476cabe032305adc916dffa39f30f07ac8249449e79da06763f08af9b642399c5c08bd5cf6b7229d63ba36b55e0ca75692b5db058ae0aa75b6b6370f12209aba SHA512 a43067a6f2a7f8d055122aefef2b0d28314c16871455e9223b8429a428ec6b4383eefe8fb50ff00d7c4c39710c6fb9fa81c3c84f3e6f5f58cbd1cf475896135e
DIST gnuconfig-20250710.tar.xz 83388 BLAKE2B 3ae8bbec15255cfba57fbc1598228f90ff9ad82da6e1e1687c6937e9f1aa6a5ca56becf787308135cbb87eedf3eee51b20a8733c165e06613a0f9acd5fdf9cb9 SHA512 21d370bb917b91c393aebf17ecb446c5b9a93d88b29e021b85d28813de979e86053ef7af770fef0713093461268a439a17b573ce0e507dac04d089c058f7887f

View File

@ -0,0 +1,49 @@
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
if [[ ${PV} == 99999999 ]] ; then
EGIT_REPO_URI="https://git.savannah.gnu.org/r/config.git"
inherit git-r3
else
SRC_URI="https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${P}.tar.xz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
S="${WORKDIR}"
fi
DESCRIPTION="Updated config.sub and config.guess file from GNU"
HOMEPAGE="https://savannah.gnu.org/projects/config"
LICENSE="GPL-3+-with-autoconf-exception"
SLOT="0"
maint_pkg_create() {
cd "${S}" || die
emake ChangeLog
local ver=$(gawk '{ gsub(/-/, "", $1); print $1; exit }' ChangeLog)
[[ ${#ver} != 8 ]] && die "invalid version '${ver}'"
local tar="${T}/gnuconfig-${ver}.tar.xz"
tar -Jcf "${tar}" ./* || die "creating tar failed"
einfo "Packaged tar now available:"
einfo "$(du -b "${tar}")"
}
src_unpack() {
if [[ ${PV} == 99999999 ]] ; then
git-r3_src_unpack
maint_pkg_create
else
unpack ${A}
fi
}
src_install() {
insinto /usr/share/${PN}
doins config.{sub,guess}
fperms +x /usr/share/${PN}/config.{sub,guess}
dodoc ChangeLog
}