--- eaccelerator-0.9.2a.ebuild 2005-03-20 16:36:42.000000000 +0300 +++ eaccelerator-0.9.2a-r1.ebuild 2005-03-20 16:36:28.000000000 +0300 @@ -15,8 +15,10 @@ LICENSE="GPL-2" SLOT="0" KEYWORDS="~x86 ~amd64 sparc" +IUSE="apache2" DEPEND="$DEPEND + apache2? >=net-www/apache-2* !dev-php/ioncube_loaders !dev-php/php-accelerator !dev-php/PECL-apc @@ -26,12 +28,14 @@ # eAccelerator does not work with Zend Thread Safety (ZTS) # so about if we are using Apache 2 with an MPM that would # require ZTS. - if has_version '>=net-www/apache-2*'; then - APACHE2_MPM="`/usr/sbin/apache2 -l | egrep 'worker|perchild|leader|threadpool|prefork'|cut -d. -f1|sed -e 's/^[[:space:]]*//g;s/[[:space:]]+/ /g;'`" - case "${APACHE2_MPM}" in - *prefork*) ;; - *) eerror "eAccelerator does not yet work with the Apache 2 MPM in use." ; die ;; - esac; + if use apache2; then + if has_version '>=net-www/apache-2*'; then + APACHE2_MPM="`/usr/sbin/apache2 -l | egrep 'worker|perchild|leader|threadpool|prefork'|cut -d. -f1|sed -e 's/^[[:space:]]*//g;s/[[:space:]]+/ /g;'`" + case "${APACHE2_MPM}" in + *prefork*) ;; + *) eerror "eAccelerator does not yet work with the Apache 2 MPM in use." ; die ;; + esac; + fi fi myconf="--enable-eaccelerator=shared"