diff options
author | Sam James <sam@gentoo.org> | 2021-06-20 23:14:05 +0200 |
---|---|---|
committer | David Seifert <soap@gentoo.org> | 2021-06-20 23:14:05 +0200 |
commit | 391ed9b1b8f2b487dcc53a573d420749b109c0a4 (patch) | |
tree | 850fe8e3e0dd3584c39bad22ceb4146ed6f0a688 /eclass/java-ant-2.eclass | |
parent | gnustep-base.eclass: [QA] add EAPI guard (diff) | |
download | gentoo-391ed9b1b8f2b487dcc53a573d420749b109c0a4.tar.gz gentoo-391ed9b1b8f2b487dcc53a573d420749b109c0a4.tar.bz2 gentoo-391ed9b1b8f2b487dcc53a573d420749b109c0a4.zip |
java-ant-2.eclass: [QA] add EAPI guard
Signed-off-by: Sam James <sam@gentoo.org>
Signed-off-by: David Seifert <soap@gentoo.org>
Diffstat (limited to 'eclass/java-ant-2.eclass')
-rw-r--r-- | eclass/java-ant-2.eclass | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/eclass/java-ant-2.eclass b/eclass/java-ant-2.eclass index 69e3f7d46d8e..9a7e97a97eda 100644 --- a/eclass/java-ant-2.eclass +++ b/eclass/java-ant-2.eclass @@ -8,6 +8,7 @@ # kiorky <kiorky@cryptelium.net> # Petteri Räty <betelgeuse@gentoo.org> # @BLURB: eclass for ant based Java packages +# @SUPPORTED_EAPIS: 5 6 7 # @DESCRIPTION: # Eclass for Ant-based Java packages. Provides support for both automatic and # manual manipulation of build.xml files. Should be inherited after java-pkg-2 @@ -15,6 +16,16 @@ inherit java-utils-2 multilib +case ${EAPI:-0} in + [567]) ;; + *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;; +esac + +EXPORT_FUNCTIONS src_configure + +if [[ -z ${_JAVA_ANT_2_ECLASS} ]] ; then +_JAVA_ANT_2_ECLASS=1 + # This eclass provides functionality for Java packages which use # ant to build. In particular, it will attempt to fix build.xml files, so that # they use the appropriate 'target' and 'source' attributes. @@ -109,11 +120,6 @@ JAVA_ANT_CLASSPATH_TAGS="javac xjavac" # @DESCRIPTION: # When set, <available> Ant tasks are rewritten to ignore Ant's runtime classpath. -case "${EAPI:-0}" in - 0|1) : ;; - *) EXPORT_FUNCTIONS src_configure ;; -esac - # @FUNCTION: java-ant-2_src_configure # @DESCRIPTION: # src_configure rewrites the build.xml files automatically, unless EAPI is undefined, 0 or 1. @@ -430,3 +436,5 @@ java-ant_rewrite-bootclasspath() { java-ant_xml-rewrite -f "${file}" -c -e ${JAVA_PKG_BSFIX_TARGET_TAGS// / -e } \ -a bootclasspath -v "${bcp}" } + +fi |