eclass/gnome.org: Sync with Gentoo

It's from Gentoo commit 40288765d981ef1a590223a07f92b99f8dbcdcf3.
This commit is contained in:
Flatcar Buildbot 2023-03-27 07:23:00 +00:00
parent 9eeb8779c2
commit df881df39c

View File

@ -1,4 +1,4 @@
# Copyright 1999-2021 Gentoo Authors # Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2 # Distributed under the terms of the GNU General Public License v2
# @ECLASS: gnome.org.eclass # @ECLASS: gnome.org.eclass
@ -29,7 +29,7 @@ _GNOME_ORG_ECLASS=1
# Most projects hosted on gnome.org mirrors provide tarballs as tar.bz2 or # Most projects hosted on gnome.org mirrors provide tarballs as tar.bz2 or
# tar.xz. This eclass defaults to xz. This is because the GNOME mirrors are # tar.xz. This eclass defaults to xz. This is because the GNOME mirrors are
# moving to only have xz tarballs for new releases. # moving to only have xz tarballs for new releases.
: ${GNOME_TARBALL_SUFFIX:="xz"} : "${GNOME_TARBALL_SUFFIX:="xz"}"
# Even though xz-utils are in @system, they must still be added to BDEPEND; see # Even though xz-utils are in @system, they must still be added to BDEPEND; see
# https://archives.gentoo.org/gentoo-dev/msg_a0d4833eb314d1be5d5802a3b710e0a4.xml # https://archives.gentoo.org/gentoo-dev/msg_a0d4833eb314d1be5d5802a3b710e0a4.xml
@ -45,16 +45,16 @@ fi
# @DESCRIPTION: # @DESCRIPTION:
# Name of the module as hosted on gnome.org mirrors. # Name of the module as hosted on gnome.org mirrors.
# Leave unset if package name matches module name. # Leave unset if package name matches module name.
: ${GNOME_ORG_MODULE:=$PN} : "${GNOME_ORG_MODULE:=$PN}"
# @ECLASS_VARIABLE: GNOME_ORG_PVP # @ECLASS_VARIABLE: GNOME_ORG_PVP
# @INTERNAL # @INTERNAL
# @DESCRIPTION: # @DESCRIPTION:
# Components of the version number that correspond to a 6 month release. # Components of the version number that correspond to a 6 month release.
if ver_test -ge 40.0; then if ver_test -ge 40.0; then
: ${GNOME_ORG_PVP:=$(ver_cut 1)} : "${GNOME_ORG_PVP:=$(ver_cut 1)}"
else else
: ${GNOME_ORG_PVP:=$(ver_cut 1-2)} : "${GNOME_ORG_PVP:=$(ver_cut 1-2)}"
fi fi
SRC_URI="mirror://gnome/sources/${GNOME_ORG_MODULE}/${GNOME_ORG_PVP}/${GNOME_ORG_MODULE}-${PV}.tar.${GNOME_TARBALL_SUFFIX}" SRC_URI="mirror://gnome/sources/${GNOME_ORG_MODULE}/${GNOME_ORG_PVP}/${GNOME_ORG_MODULE}-${PV}.tar.${GNOME_TARBALL_SUFFIX}"