/[gentoo-x86]/eclass/apache-module.eclass
Gentoo

Diff of /eclass/apache-module.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.15 Revision 1.16
1# Copyright 2004 Gentoo Foundation 1# Copyright 2004 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License, v2 or later 2# Distributed under the terms of the GNU General Public License, v2 or later
3# Author Michael Tindal <urilith@gentoo.org> 3# Author Michael Tindal <urilith@gentoo.org>
4# $Header: /var/cvsroot/gentoo-x86/eclass/apache-module.eclass,v 1.15 2006/06/10 16:19:54 swegener Exp $ 4# $Header: /var/cvsroot/gentoo-x86/eclass/apache-module.eclass,v 1.16 2006/10/12 13:41:10 tomk Exp $
5 5
6inherit depend.apache 6inherit depend.apache
7 7
8# This eclass provides a common set of functions for Apache modules. 8# This eclass provides a common set of functions for Apache modules.
9 9
50 50
51#### 51####
52## APACHE1_MOD_DEFINE, APACHE2_MOD_DEFINE 52## APACHE1_MOD_DEFINE, APACHE2_MOD_DEFINE
53## 53##
54## Name of define (eg FOO) to use in conditional loading of the installed 54## Name of define (eg FOO) to use in conditional loading of the installed
55## module/it's config file 55## module/it's config file, multiple defines should be space separated
56#### 56####
57APACHE1_MOD_DEFINE="" 57APACHE1_MOD_DEFINE=""
58APACHE2_MOD_DEFINE="" 58APACHE2_MOD_DEFINE=""
59 59
60#### 60####
206#### 206####
207apache1_pkg_postinst() { 207apache1_pkg_postinst() {
208 debug-print-function apache1_pkg_postinst 208 debug-print-function apache1_pkg_postinst
209 209
210 if [ -n "${APACHE1_MOD_DEFINE}" ]; then 210 if [ -n "${APACHE1_MOD_DEFINE}" ]; then
211 local my_opts="-D ${APACHE1_MOD_DEFINE// / -D }"
212
211 einfo 213 einfo
212 einfo "To enable ${PN}, you need to edit your /etc/conf.d/apache file and" 214 einfo "To enable ${PN}, you need to edit your /etc/conf.d/apache file and"
213 einfo "add '-D ${APACHE1_MOD_DEFINE}' to APACHE_OPTS." 215 einfo "add '${my_opts}' to APACHE_OPTS."
214 einfo 216 einfo
215 fi 217 fi
216 if [ -n "${APACHE1_MOD_CONF}" ] ; then 218 if [ -n "${APACHE1_MOD_CONF}" ] ; then
217 einfo 219 einfo
218 einfo "Configuration file installed as" 220 einfo "Configuration file installed as"
318 320
319apache2_pkg_postinst() { 321apache2_pkg_postinst() {
320 debug-print-function apache2_pkg_postinst 322 debug-print-function apache2_pkg_postinst
321 323
322 if [ -n "${APACHE2_MOD_DEFINE}" ]; then 324 if [ -n "${APACHE2_MOD_DEFINE}" ]; then
325 local my_opts="-D ${APACHE2_MOD_DEFINE// / -D }"
326
323 einfo 327 einfo
324 einfo "To enable ${PN}, you need to edit your /etc/conf.d/apache2 file and" 328 einfo "To enable ${PN}, you need to edit your /etc/conf.d/apache2 file and"
325 einfo "add '-D ${APACHE2_MOD_DEFINE}' to APACHE2_OPTS." 329 einfo "add '${my_opts}' to APACHE2_OPTS."
326 einfo 330 einfo
327 fi 331 fi
328 if [ -n "${APACHE2_MOD_CONF}" ] ; then 332 if [ -n "${APACHE2_MOD_CONF}" ] ; then
329 einfo 333 einfo
330 einfo "Configuration file installed as" 334 einfo "Configuration file installed as"

Legend:
Removed from v.1.15  
changed lines
  Added in v.1.16

  ViewVC Help
Powered by ViewVC 1.1.20