aspell-dict.eclass: Some tweaks so the eclass works with EAPI>0 ebuilds.
authorLars Wendler <polynomial-c@gentoo.org>
Thu, 1 Dec 2016 20:09:34 +0000 (21:09 +0100)
committerLars Wendler <polynomial-c@gentoo.org>
Thu, 1 Dec 2016 20:13:59 +0000 (21:13 +0100)
eclass/aspell-dict.eclass

index 6207f6a15fc9f3e72fbc9be9783fc4d02b4216af..5600d9a6960c8cdfb9954e8bf47165b66c03e308 100644 (file)
 # @DESCRIPTION:
 # What major version of aspell is this dictionary for?
 
-EXPORT_FUNCTIONS src_compile src_install
+case ${EAPI} in
+       0|1) EXPORT_FUNCTIONS src_compile src_install ;;
+       *) EXPORT_FUNCTIONS src_configure src_compile src_install ;;
+esac
 
 #MY_P=${PN}-${PV%.*}-${PV#*.*.}
 MY_P=${P%.*}-${PV##*.}
@@ -46,11 +49,20 @@ else
        DEPEND="${RDEPEND}"
 fi
 
+# @FUNCTION: aspell-dict_src_configure
+# @DESCRIPTION:
+# The aspell-dict src_configure function which is exported.
+aspell-dict_src_configure() {
+       ./configure || die
+}
+
 # @FUNCTION: aspell-dict_src_compile
 # @DESCRIPTION:
 # The aspell-dict src_compile function which is exported.
 aspell-dict_src_compile() {
-       ./configure || die
+       case ${EAPI} in
+               0|1) aspell-dict_src_configure ;;
+       esac
        emake || die
 }