diff options
author | Conrad Kostecki <conikost@gentoo.org> | 2021-03-13 19:46:34 +0100 |
---|---|---|
committer | Conrad Kostecki <conikost@gentoo.org> | 2021-03-13 21:02:19 +0100 |
commit | 4bd838280b7d4be0f84e0ea6a523a6f14c556136 (patch) | |
tree | cfb1c954d63389351a8df7020362d93832beaba0 /eclass/myspell-r2.eclass | |
parent | eclass/myspell-r2.eclass: update blurb and add description (diff) | |
download | gentoo-4bd838280b7d4be0f84e0ea6a523a6f14c556136.tar.gz gentoo-4bd838280b7d4be0f84e0ea6a523a6f14c556136.tar.bz2 gentoo-4bd838280b7d4be0f84e0ea6a523a6f14c556136.zip |
eclass/myspell-r2.eclass: add EAPI support
As this eclass has no EAPI checks, so adding them.
Currently EAPI 5,6 and 7 will be supported, as all existing ebuilds are
currently in EAPI 5 and 6.
This eclass also adds app-arch/unzip to DEPEND.
In order to support EAPI=7, we need to add app-arch/unzip
to BDEPEND instead.
Signed-off-by: Conrad Kostecki <conikost@gentoo.org>
Diffstat (limited to 'eclass/myspell-r2.eclass')
-rw-r--r-- | eclass/myspell-r2.eclass | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/eclass/myspell-r2.eclass b/eclass/myspell-r2.eclass index b75044a383fa..8abbed097980 100644 --- a/eclass/myspell-r2.eclass +++ b/eclass/myspell-r2.eclass @@ -6,13 +6,12 @@ # maintainer-needed@gentoo.org # @AUTHOR: # Tomáš Chvátal <scarabeus@gentoo.org> +# @SUPPORTED_EAPIS: 5 6 7 # @BLURB: An eclass to streamline the construction of ebuilds for new Myspell dictionaries. # @DESCRIPTION: # The myspell-r2 eclass is designed to streamline the construction of ebuilds for # the new Myspell dictionaries which support hunspell. -EXPORT_FUNCTIONS src_unpack src_install - # @ECLASS-VARIABLE: MYSPELL_DICT # @DEFAULT_UNSET # @DESCRIPTION: @@ -31,11 +30,28 @@ EXPORT_FUNCTIONS src_unpack src_install # Array variable containing list of all thesarus files. # MYSPELL_THES=( "file.dat" "dir/file2.idx" ) +case ${EAPI:-0} in + [0-4]) + die "${ECLASS} is banned in EAPI ${EAPI:-0}" + ;; + [5-7]) + ;; + *) + die "Unknown EAPI ${EAPI:-0}" + ;; +esac + +EXPORT_FUNCTIONS src_unpack src_install + # Basically no extra deps needed. # Unzip is required for .oxt libreoffice extensions # which are just fancy zip files. -DEPEND="app-arch/unzip" -RDEPEND="" +if [[ ${EAPI:-0} == 7 ]]; then + BDEPEND="app-arch/unzip" +else + DEPEND="app-arch/unzip" + RDEPEND="" +fi # by default this stuff does not have any folder in the pack S="${WORKDIR}" |