summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'eclass/webapp.eclass')
-rw-r--r--eclass/webapp.eclass15
1 files changed, 13 insertions, 2 deletions
diff --git a/eclass/webapp.eclass b/eclass/webapp.eclass
index 6907ef1c321d..5ef7dbce03cf 100644
--- a/eclass/webapp.eclass
+++ b/eclass/webapp.eclass
@@ -4,11 +4,22 @@
# @ECLASS: webapp.eclass
# @MAINTAINER:
# web-apps@gentoo.org
+# @SUPPORTED_EAPIS: 5 6 7
# @BLURB: functions for installing applications to run under a web server
# @DESCRIPTION:
# The webapp eclass contains functions to handle web applications with
# webapp-config. Part of the implementation of GLEP #11
+case ${EAPI:-0} in
+ [567]) ;;
+ *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;;
+esac
+
+EXPORT_FUNCTIONS pkg_postinst pkg_setup src_install pkg_prerm
+
+if [[ -z ${_WEBAPP_ECLASS} ]]; then
+_WEBAPP_ECLASS=1
+
# @ECLASS-VARIABLE: WEBAPP_DEPEND
# @DESCRIPTION:
# An ebuild should use WEBAPP_DEPEND if a custom DEPEND needs to be built, most
@@ -35,8 +46,6 @@ if [[ "${WEBAPP_OPTIONAL}" != "yes" ]]; then
RDEPEND="${DEPEND}"
fi
-EXPORT_FUNCTIONS pkg_postinst pkg_setup src_install pkg_prerm
-
INSTALL_DIR="/${PN}"
IS_UPGRADE=0
IS_REPLACE=0
@@ -577,3 +586,5 @@ webapp_pkg_prerm() {
echo
fi
}
+
+fi