mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-11-23 23:27:12 -08:00
vala.eclass: drop EAPI 6 support
Signed-off-by: David Seifert <soap@gentoo.org>
This commit is contained in:
+7
-11
@@ -1,4 +1,4 @@
|
|||||||
# Copyright 1999-2022 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: vala.eclass
|
# @ECLASS: vala.eclass
|
||||||
@@ -6,7 +6,7 @@
|
|||||||
# gnome@gentoo.org
|
# gnome@gentoo.org
|
||||||
# @AUTHOR:
|
# @AUTHOR:
|
||||||
# Alexandre Rostovtsev <tetromino@gentoo.org>
|
# Alexandre Rostovtsev <tetromino@gentoo.org>
|
||||||
# @SUPPORTED_EAPIS: 6 7 8
|
# @SUPPORTED_EAPIS: 7 8
|
||||||
# @BLURB: Sets up the environment for using a specific version of vala.
|
# @BLURB: Sets up the environment for using a specific version of vala.
|
||||||
# @DESCRIPTION:
|
# @DESCRIPTION:
|
||||||
# This eclass sets up commonly used environment variables for using a specific
|
# This eclass sets up commonly used environment variables for using a specific
|
||||||
@@ -15,7 +15,7 @@
|
|||||||
# executables, pkgconfig files, etc., which Gentoo does not provide.
|
# executables, pkgconfig files, etc., which Gentoo does not provide.
|
||||||
|
|
||||||
case ${EAPI} in
|
case ${EAPI} in
|
||||||
6|7) inherit eutils multilib ;;
|
7) inherit eutils multilib ;;
|
||||||
8) ;;
|
8) ;;
|
||||||
*) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;;
|
*) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;;
|
||||||
esac
|
esac
|
||||||
@@ -99,13 +99,11 @@ vala_depend() {
|
|||||||
# VALA_MAX_API_VERSION, VALA_MIN_API_VERSION, and VALA_USE_DEPEND.
|
# VALA_MAX_API_VERSION, VALA_MIN_API_VERSION, and VALA_USE_DEPEND.
|
||||||
vala_best_api_version() {
|
vala_best_api_version() {
|
||||||
local u v
|
local u v
|
||||||
local hv_opt="-b"
|
|
||||||
[[ ${EAPI} == 6 ]] && hv_opt=""
|
|
||||||
|
|
||||||
u=$(_vala_use_depend)
|
u=$(_vala_use_depend)
|
||||||
|
|
||||||
for v in $(vala_api_versions); do
|
for v in $(vala_api_versions); do
|
||||||
has_version ${hv_opt} "dev-lang/vala:${v}${u}" && echo "${v}" && return
|
has_version -b "dev-lang/vala:${v}${u}" && echo "${v}" && return
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -121,8 +119,6 @@ vala_best_api_version() {
|
|||||||
# version is not available.
|
# version is not available.
|
||||||
vala_setup() {
|
vala_setup() {
|
||||||
local p d valafoo version ignore_use
|
local p d valafoo version ignore_use
|
||||||
local hv_opt="-b"
|
|
||||||
[[ ${EAPI} == 6 ]] && hv_opt=""
|
|
||||||
|
|
||||||
while [[ $1 ]]; do
|
while [[ $1 ]]; do
|
||||||
case $1 in
|
case $1 in
|
||||||
@@ -141,7 +137,7 @@ vala_setup() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ${version} ]]; then
|
if [[ ${version} ]]; then
|
||||||
has_version ${hv_opt} "dev-lang/vala:${version}" || die "No installed vala:${version}"
|
has_version -b "dev-lang/vala:${version}" || die "No installed vala:${version}"
|
||||||
else
|
else
|
||||||
version=$(vala_best_api_version)
|
version=$(vala_best_api_version)
|
||||||
[[ ${version} ]] || die "No installed vala in $(vala_depend)"
|
[[ ${version} ]] || die "No installed vala in $(vala_depend)"
|
||||||
@@ -178,8 +174,8 @@ vala_setup() {
|
|||||||
|
|
||||||
# @FUNCTION: vala_src_prepare
|
# @FUNCTION: vala_src_prepare
|
||||||
# @DESCRIPTION:
|
# @DESCRIPTION:
|
||||||
# For backwards compatibility in EAPIs 6 and 7. Calls vala_setup.
|
# For backwards compatibility in EAPI 7. Calls vala_setup.
|
||||||
if [[ ${EAPI} == [67] ]]; then
|
if [[ ${EAPI} == 7 ]]; then
|
||||||
vala_src_prepare() { vala_setup "$@"; }
|
vala_src_prepare() { vala_setup "$@"; }
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user