rev |
line source |
pascal@20051
|
1 # SliTaz package receipt v2.
|
pankso@18
|
2
|
pankso@18
|
3 PACKAGE="php"
|
Hans-G?nter@21402
|
4 VERSION="7.4.5"
|
pankso@204
|
5 CATEGORY="development"
|
al@20534
|
6 SHORT_DESC="PHP web programming language"
|
Hans-G?nter@21348
|
7 MAINTAINER="maintainer@slitaz.org"
|
pascal@15198
|
8 LICENSE="BSD"
|
Hans-G?nter@21348
|
9 WEB_SITE="https://www.php.net/"
|
al@20534
|
10
|
Hans-G?nter@21348
|
11 TARBALL="$PACKAGE-$VERSION.tar.xz"
|
Hans-G?nter@21348
|
12 WGET_URL="https://www.php.net/distributions/$TARBALL"
|
pankso@18
|
13
|
Hans-G?nter@21348
|
14 BUILD_DEPENDS="apache apache-dev apr-dev apr-util-dev c-client
|
Hans-G?nter@21403
|
15 coreutils-conditions curl-dev cyrus-sasl-dev gettext
|
Hans-G?nter@21348
|
16 jpeg-dev libldap libmcrypt-dev libmysqlclient libpng-dev
|
Hans-G?nter@21348
|
17 libunixODBC libvpx-dev libxml2-dev mhash-dev mysql-dev
|
Hans-G?nter@21348
|
18 net-snmp-dev openldap-dev openssl-dev perl postgresql-dev
|
Hans-G?nter@21348
|
19 re2c sed sqlite3-dev unixODBC-dev zlib-dev"
|
al@21020
|
20 SPLIT="\
|
al@21020
|
21 $PACKAGE-apache $PACKAGE-cherokee $PACKAGE-cli $PACKAGE-common \
|
al@21020
|
22 $PACKAGE-curl $PACKAGE-dba $PACKAGE-dev $PACKAGE-gd \
|
Hans-G?nter@21402
|
23 $PACKAGE-imap $PACKAGE-ldap $PACKAGE-mcrypt $PACKAGE-mysql \
|
Hans-G?nter@21402
|
24 $PACKAGE-mysqli $PACKAGE-odbc $PACKAGE-openssl $PACKAGE-pdo-mysql \
|
al@21020
|
25 $PACKAGE-pdo-pgsql $PACKAGE-pear $PACKAGE-pgsql $PACKAGE-snmp \
|
al@21020
|
26 $PACKAGE-soap $PACKAGE-sqlite"
|
al@20534
|
27
|
Hans-G?nter@21348
|
28 compile_rules()
|
Hans-G?nter@21348
|
29 {
|
Hans-G?nter@21403
|
30 # 7.4.4 unrecognised:
|
Hans-G?nter@21403
|
31 # --enable-zip
|
Hans-G?nter@21403
|
32 # --with-jpeg-dir=/usr
|
Hans-G?nter@21403
|
33 # --with-png-dir=/usr
|
Hans-G?nter@21404
|
34 # --with-mcrypt=shared,/usr
|
Hans-G?nter@21404
|
35 # --with-mysql=shared,/usr
|
Hans-G?nter@21404
|
36 # --with-vpx-dir=/usr
|
Hans-G?nter@21403
|
37
|
al@21020
|
38 ARCH_ARGS="\
|
Hans-G?nter@21403
|
39 --config-cache \
|
Hans-G?nter@21403
|
40 --enable-calendar \
|
Hans-G?nter@21403
|
41 --enable-dba=shared \
|
Hans-G?nter@21403
|
42 --enable-exif \
|
Hans-G?nter@21403
|
43 --enable-ftp \
|
Hans-G?nter@21403
|
44 --enable-maintainer-zts \
|
Hans-G?nter@21348
|
45 --enable-mbstring \
|
Hans-G?nter@21403
|
46 --enable-soap=shared,/usr \
|
Hans-G?nter@21348
|
47 --enable-sockets \
|
Hans-G?nter@21348
|
48 --with-config-file-path=/etc \
|
Hans-G?nter@21403
|
49 --with-curl=shared \
|
Hans-G?nter@21404
|
50 --enable-gd=shared \
|
Hans-G?nter@21348
|
51 --with-gettext \
|
Hans-G?nter@21403
|
52 --with-imap=shared \
|
Hans-G?nter@21403
|
53 --with-imap-ssl \
|
Hans-G?nter@21403
|
54 --with-ldap=shared \
|
Hans-G?nter@21403
|
55 --with-mhash \
|
Hans-G?nter@21403
|
56 --with-mysql-sock=/var/run/mysqld/mysql.sock \
|
Hans-G?nter@21348
|
57 --with-mysqli=shared \
|
Hans-G?nter@21403
|
58 --with-openssl=shared \
|
Hans-G?nter@21403
|
59 --with-pdo-mysql=shared \
|
Hans-G?nter@21403
|
60 --with-pdo-pgsql=shared \
|
Hans-G?nter@21348
|
61 --with-pdo-sqlite=shared,/usr \
|
Hans-G?nter@21403
|
62 --with-pear=/usr/share/php \
|
Hans-G?nter@21348
|
63 --with-pgsql=shared,/usr \
|
Hans-G?nter@21348
|
64 --with-snmp=shared,/usr \
|
Hans-G?nter@21403
|
65 --with-sqlite3=shared,/usr \
|
Hans-G?nter@21403
|
66 --with-unixODBC=shared,/usr \
|
Hans-G?nter@21403
|
67 --with-zlib"
|
pankso@16079
|
68
|
Hans-G?nter@21403
|
69 # 7.4.5 no such file
|
Hans-G?nter@21403
|
70 # sed -i 's|PLANE_[UVY]\]|VPX_&|;s|IMG_FMT_I420|VPX_&|' \
|
Hans-G?nter@21404
|
71 # ext/gd/libgd/webpimg.c
|
Hans-G?nter@21403
|
72
|
Hans-G?nter@21348
|
73 sed -i 's/pam_start/pam_nostart/' \
|
Hans-G?nter@21348
|
74 configure
|
al@20534
|
75
|
Hans-G?nter@21405
|
76 ln -s /usr/lib/c-client.a /usr/lib/libc-client.a
|
Hans-G?nter@21405
|
77
|
Hans-G?nter@21348
|
78 ./configure \
|
Hans-G?nter@21348
|
79 $ARCH_ARGS \
|
al@20534
|
80 $CONFIGURE_ARGS &&
|
al@20534
|
81 make $MAKEFLAGS &&
|
al@21020
|
82 make -j1 INSTALL_ROOT=$install install
|
al@20534
|
83
|
Hans-G?nter@21348
|
84 ./configure \
|
Hans-G?nter@21348
|
85 $ARCH_ARGS \
|
al@20534
|
86 $CONFIGURE_ARGS \
|
al@20534
|
87 --with-apxs2=/usr/bin/apxs &&
|
al@20534
|
88 make $MAKEFLAGS &&
|
al@21020
|
89 mkdir -p $install/etc/apache &&
|
Hans-G?nter@21348
|
90 cp /etc/apache/httpd.conf $install/etc/apache/httpd.conf &&
|
al@21020
|
91 make -j1 INSTALL_ROOT=$install install || return 1
|
al@20534
|
92
|
Hans-G?nter@21348
|
93 # Production configuration file.
|
al@21020
|
94 mkdir -p $install/etc
|
Hans-G?nter@21348
|
95
|
Hans-G?nter@21348
|
96 cp $src/php.ini-production $install/etc/php.ini || return 1
|
slaxemulator@10549
|
97 sed -e 's|extension_dir = "./"|extension_dir = "/usr/share/php/"|' \
|
al@21020
|
98 -i $install/etc/php.ini
|
al@20534
|
99
|
al@20534
|
100 install -Dm755 $src/sapi/cgi/php-cgi $install/usr/bin/php-cgi
|
al@20534
|
101
|
al@20534
|
102 install -Dm644 $stuff/phpinfo/index.php $install/usr/share/phpinfo/index.php
|
al@20534
|
103 install -Dm644 $stuff/php.desktop $install/usr/share/applications/php.desktop
|
al@20534
|
104 install -Dm644 $stuff/php.png $install/usr/share/pixmaps/php.png
|
pankso@18
|
105 }
|
pankso@18
|
106
|
Hans-G?nter@21348
|
107 genpkg_rules()
|
Hans-G?nter@21348
|
108 {
|
pascal@20051
|
109 case $PACKAGE in
|
al@20534
|
110 php)
|
al@20534
|
111 copy usr/bin/php-cgi
|
Hans-G?nter@21402
|
112 DEPENDS="libxml2 lighttpd openssl php-common sqlite3 zlib"
|
al@20534
|
113 PROVIDE="php:lighttpd"
|
al@20534
|
114 ;;
|
al@20534
|
115 php-apache)
|
al@20534
|
116 copy usr/share/apache/
|
al@20534
|
117 CAT="development|module for apache"
|
Hans-G?nter@21402
|
118 DEPENDS="apache libxml2 php-common zlib"
|
al@20534
|
119 PROVIDE="php:apache"
|
al@20534
|
120 ;;
|
al@20534
|
121 php-cherokee)
|
al@20534
|
122 copy usr/bin/php-cgi # FIXME! the same file in "php" package
|
al@20534
|
123 CAT="development|module for cherokee"
|
Hans-G?nter@21402
|
124 DEPENDS="cherokee libxml2 php-common zlib"
|
al@20534
|
125 PROVIDE="php:cherokee"
|
al@20534
|
126 ;;
|
al@20534
|
127 php-cli)
|
al@20534
|
128 copy usr/bin/php
|
al@20534
|
129 CAT="development|command line interpreter"
|
al@20534
|
130 DEPENDS="php-common"
|
al@20534
|
131 ;;
|
al@20534
|
132 php-common)
|
al@20534
|
133 copy phpinfo/ php.desktop php.png php.ini
|
al@20534
|
134 CAT="development|common files for PHP modules"
|
al@20534
|
135 DEPENDS=" "
|
al@20534
|
136 CONFIG_FILES="/etc/php.ini"
|
al@20534
|
137 ;;
|
al@20534
|
138 php-curl)
|
al@20534
|
139 copy curl.so
|
al@20534
|
140 CAT="development|curl module"
|
al@20534
|
141 DEPENDS="curl php"
|
al@20534
|
142 ;;
|
al@20534
|
143 php-dba)
|
al@20534
|
144 copy dba.so
|
al@20534
|
145 CAT="development|dba module"
|
al@20534
|
146 DEPENDS=" "
|
al@20534
|
147 ;;
|
al@20534
|
148 php-dev)
|
al@20534
|
149 copy @dev
|
Hans-G?nter@21402
|
150 DEPENDS="cyrus-sasl jpeg libcomerr3 libkrb5 libldap
|
Hans-G?nter@21402
|
151 libmcrypt libmysqlclient libpng libpostgresqlclient
|
Hans-G?nter@21402
|
152 libtool libunixODBC mhash net-snmp openssl php"
|
al@20534
|
153 ;;
|
al@20534
|
154 php-gd)
|
al@20534
|
155 copy gd.so
|
al@20534
|
156 CAT="development|gd module"
|
Hans-G?nter@21402
|
157 DEPENDS="jpeg libpng libvpx php"
|
al@20534
|
158 ;;
|
al@20534
|
159 php-imap)
|
al@20534
|
160 copy imap.so
|
al@20534
|
161 CAT="development|imap module"
|
Hans-G?nter@21402
|
162 DEPENDS="openssl php"
|
al@20534
|
163 ;;
|
al@20534
|
164 php-ldap)
|
al@20534
|
165 copy ldap.so
|
al@20534
|
166 CAT="development|ldap module"
|
Hans-G?nter@21402
|
167 DEPENDS="cyrus-sasl libcomerr3 libkrb5 libldap openssl php"
|
al@20534
|
168 ;;
|
al@20534
|
169 php-mcrypt)
|
al@20534
|
170 copy mcrypt.so
|
al@20534
|
171 CAT="development|mcrypt module"
|
Hans-G?nter@21402
|
172 DEPENDS="libmcrypt libtool php"
|
al@20534
|
173 ;;
|
al@20534
|
174 php-mysqli)
|
al@20534
|
175 copy mysqli.so
|
al@20534
|
176 CAT="development|mysqli module"
|
al@20534
|
177 DEPENDS="libmysqlclient php"
|
al@20534
|
178 ;;
|
al@20534
|
179 php-mysql)
|
al@20534
|
180 copy mysql.so
|
al@20534
|
181 CAT="development|mysql module"
|
al@20534
|
182 DEPENDS="libmysqlclient php"
|
al@20534
|
183 ;;
|
al@20534
|
184 php-odbc)
|
al@20534
|
185 copy odbc.so
|
al@20534
|
186 CAT="development|ODBC module"
|
Hans-G?nter@21402
|
187 DEPENDS="php unixODBC"
|
al@20534
|
188 ;;
|
al@20534
|
189 php-openssl)
|
al@20534
|
190 copy openssl.so
|
al@20534
|
191 CAT="development|OpenSSL module"
|
Hans-G?nter@21402
|
192 DEPENDS="openssl php"
|
al@20534
|
193 ;;
|
al@20534
|
194 php-pdo-mysql)
|
al@20534
|
195 copy pdo_mysql.so
|
al@20534
|
196 CAT="development|PDO MySQL module"
|
al@20534
|
197 DEPENDS="php php-mysql"
|
al@20534
|
198 ;;
|
al@20534
|
199 php-pdo-pgsql)
|
al@20534
|
200 copy pdo_pgsql.so
|
al@20534
|
201 CAT="development|PDO PgSQL module"
|
Hans-G?nter@21402
|
202 DEPENDS="libpostgresqlclient php php-mysql"
|
al@20534
|
203 ;;
|
al@20534
|
204 php-pear)
|
al@20534
|
205 copy etc/pear.conf usr/bin/pe* usr/share/php/
|
al@20534
|
206 CAT="development|PEAR libs"
|
al@20534
|
207 DEPENDS="php-cli"
|
al@20534
|
208 ;;
|
al@20534
|
209 php-pgsql)
|
al@20534
|
210 copy pgsql.so
|
al@20534
|
211 CAT="development|postgresql module"
|
Hans-G?nter@21402
|
212 DEPENDS="php postgresql"
|
al@20534
|
213 ;;
|
al@20534
|
214 php-snmp)
|
al@20534
|
215 copy snmp.so
|
al@20534
|
216 CAT="development|snmp module"
|
Hans-G?nter@21402
|
217 DEPENDS="net-snmp openssl php"
|
al@20534
|
218 ;;
|
al@20534
|
219 php-soap)
|
al@20534
|
220 copy soap.so
|
al@20534
|
221 CAT="development|soap module"
|
Hans-G?nter@21402
|
222 DEPENDS="libxml2 php"
|
al@20534
|
223 ;;
|
al@20534
|
224 php-sqlite)
|
al@20534
|
225 copy sqlite.so sqlite3.so pdo_sqlite.so
|
al@20534
|
226 CAT="development|sqlite module"
|
al@20534
|
227 DEPENDS="php sqlite3"
|
al@20534
|
228 ;;
|
pascal@20051
|
229 esac
|
pankso@18
|
230 }
|
pankso@18
|
231
|
al@20534
|
232 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
233 pre_install_php()
|
Hans-G?nter@21348
|
234 {
|
Hans-G?nter@21348
|
235 if [ -z "$1" -a ! -f "/var/run/lighttpd.pid" ]
|
Hans-G?nter@21348
|
236 then
|
pankso@18
|
237 /etc/init.d/lighttpd stop
|
pankso@18
|
238 fi
|
pankso@18
|
239 }
|
pankso@9861
|
240
|
Hans-G?nter@21348
|
241 post_install_php()
|
Hans-G?nter@21348
|
242 {
|
pascal@1143
|
243 # Enable php
|
Hans-G?nter@21348
|
244 if [ -f "$1/etc/lighttpd/lighttpd.conf" ]
|
Hans-G?nter@21348
|
245 then
|
al@20534
|
246 [ -f "$1/usr/lib/lighttpd/mod_fastcgi.so" ] ||
|
al@20534
|
247 tazpkg get-install lighttpd-modules --root="$1/"
|
al@20534
|
248
|
al@20534
|
249 sed \
|
al@20534
|
250 -e 's|#fastcgi.server = ( ".php"|fastcgi.server = ( ".php"|' \
|
al@20534
|
251 -e 's|#"bin-path" => "/usr/bin/php-cgi"|"bin-path" => "/usr/bin/php-cgi"|' \
|
al@20534
|
252 -e 's|#"socket" => "/tmp/php.socket"|"socket" => "/tmp/php.socket"\n )))|' \
|
al@20534
|
253 -i "$1/etc/lighttpd/lighttpd.conf"
|
al@20534
|
254
|
al@20534
|
255 grep -q mod_fastcgi "$1/etc/lighttpd/lighttpd.conf" ||
|
al@20534
|
256 sed \
|
al@20534
|
257 -e 's|server.modules = (|server.modules = (\n "mod_fastcgi",|' \
|
al@20534
|
258 -i "$1/etc/lighttpd/lighttpd.conf"
|
al@20534
|
259
|
al@20534
|
260 grep -q php3 "$1/etc/lighttpd/lighttpd.conf" ||
|
al@20534
|
261 sed \
|
al@20534
|
262 -e 's|for PHP.*|for PHP.\nfastcgi.map-extensions = ( ".php3" => ".php", ".php4" => ".php", ".php5" => ".php" )|' \
|
al@20534
|
263 -i "$1/etc/lighttpd/lighttpd.conf"
|
al@20534
|
264
|
pascal@1143
|
265 fi
|
al@20534
|
266
|
pankso@18
|
267 # Start Web server.
|
Hans-G?nter@21348
|
268 if [ -z "$1" -a ! -f /var/run/lighttpd.pid -a -f /etc/init.d/lighttpd ]
|
Hans-G?nter@21348
|
269 then
|
pankso@18
|
270 /etc/init.d/lighttpd start
|
pankso@18
|
271 fi
|
pankso@18
|
272 }
|
pascal@20051
|
273
|
al@20534
|
274 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
275 pre_installi_php_apache()
|
Hans-G?nter@21348
|
276 {
|
Hans-G?nter@21348
|
277 if [ -z "$1" -a -f "/var/run/apache/httpd.pid" ]
|
Hans-G?nter@21348
|
278 then
|
pascal@20051
|
279 /etc/init.d/apache stop
|
pascal@20051
|
280 fi
|
pascal@20051
|
281 }
|
pascal@20051
|
282
|
Hans-G?nter@21348
|
283 post_install_php_apache()
|
Hans-G?nter@21348
|
284 {
|
al@20534
|
285 grep -q php5_module "$1/etc/apache/httpd.conf" ||
|
al@20534
|
286 {
|
al@20534
|
287 sed \
|
al@20534
|
288 -e 's|mod_rewrite.so|mod_rewrite.so\nLoadModule php5_module share/apache/modules/libphp5.so|' \
|
al@20534
|
289 -e 's|DirectoryIndex index.html|DirectoryIndex index.html index.php|' \
|
al@20534
|
290 -e 's|mime.types|mime.types\n AddType application/x-httpd-php .php .php3 .php4 .php5\n AddType application/x-httpd-php-source .phps|' \
|
al@20534
|
291 -i "$1/etc/apache/httpd.conf"
|
pascal@20051
|
292 }
|
al@20534
|
293
|
al@20534
|
294 [ -f "$1/etc/apache/conf.d/phpinfo" ] ||
|
pascal@20051
|
295 cat > "$1/etc/apache/conf.d/phpinfo" <<EOT
|
pascal@20051
|
296 <IfModule mod_alias.c>
|
pascal@20051
|
297 Alias /phpinfo /usr/share/phpinfo
|
pascal@20051
|
298 </IfModule>
|
pascal@20051
|
299 <DirectoryMatch /usr/share/phpinfo/>
|
pascal@20051
|
300 DirectoryIndex index.php
|
pascal@20051
|
301 Options +FollowSymLinks
|
pascal@20051
|
302 AllowOverride None
|
pascal@20051
|
303 Order allow,deny
|
pascal@20051
|
304 Allow from all
|
pascal@20051
|
305 </DirectoryMatch>
|
pascal@20051
|
306 EOT
|
al@20534
|
307
|
pascal@20051
|
308 # Restart Web server.
|
Hans-G?nter@21348
|
309 if [ -z "$1" -a -f "/var/run/apache/httpd.pid" ]
|
Hans-G?nter@21348
|
310 then
|
pascal@20051
|
311 /etc/init.d/apache stop
|
pascal@20051
|
312 sleep 2
|
pascal@20051
|
313 fi
|
pascal@20051
|
314 if [ -z "$1" ]; then
|
pascal@20051
|
315 /etc/init.d/apache start
|
pascal@20051
|
316 fi
|
pascal@20051
|
317 }
|
pascal@20051
|
318
|
al@20534
|
319 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
320 pre_install_php_cherokee()
|
Hans-G?nter@21348
|
321 {
|
Hans-G?nter@21348
|
322 if [ -z "$1" -a ! -f "/var/run/cherokee.pid" ]
|
Hans-G?nter@21348
|
323 then
|
pascal@20051
|
324 /etc/init.d/cherokee stop
|
pascal@20051
|
325 fi
|
pascal@20051
|
326 }
|
pascal@20051
|
327
|
Hans-G?nter@21348
|
328 post_install_php_cherokee()
|
Hans-G?nter@21348
|
329 {
|
pascal@20051
|
330 # Enable php
|
pascal@20051
|
331 # if [ -f "$1/etc/lighttpd/lighttpd.conf" ]; then
|
pascal@20051
|
332 # [ -f "$1/usr/lib/lighttpd/mod_fastcgi.so" ] || \
|
pascal@20051
|
333 # tazpkg get-install lighttpd-modules --root="$1/"
|
pascal@20051
|
334 # sed -e 's|#fastcgi.server = ( ".php"|fastcgi.server = ( ".php"|' \
|
pascal@20051
|
335 # -e 's|#"bin-path" => "/usr/bin/php-cgi"|"bin-path" => "/usr/bin/php-cgi"|' \
|
pascal@20051
|
336 # -e 's|#"socket" => "/tmp/php.socket"|"socket" => "/tmp/php.socket"\n )))|' \
|
pascal@20051
|
337 # -i "$1/etc/lighttpd/lighttpd.conf"
|
pascal@20051
|
338 # grep -q mod_fastcgi "$1/etc/lighttpd/lighttpd.conf" || \
|
pascal@20051
|
339 # sed -e 's|server.modules = (|server.modules = (\n "mod_fastcgi",|' \
|
pascal@20051
|
340 # -i "$1/etc/lighttpd/lighttpd.conf"
|
pascal@20051
|
341 # grep -q php3 "$1/etc/lighttpd/lighttpd.conf" || \
|
pascal@20051
|
342 # sed -e 's|for PHP.*|for PHP.\nfastcgi.map-extensions = ( ".php3" => ".php", ".php4" => ".php", ".php5" => ".php" )|' \
|
pascal@20051
|
343 # -i "$1/etc/lighttpd/lighttpd.conf"
|
pascal@20051
|
344 # fi
|
pascal@20051
|
345
|
pascal@20051
|
346 # Start Web server.
|
Hans-G?nter@21348
|
347 if [ -z "$1" -a ! -f /var/run/cherokee.pid -a -f /etc/init.d/cherokee ]
|
Hans-G?nter@21348
|
348 then
|
pascal@20051
|
349 /etc/init.d/cherokee start
|
pascal@20051
|
350 fi
|
pascal@20051
|
351 }
|
pascal@20051
|
352
|
al@20534
|
353 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
354 pre_install_php_common()
|
Hans-G?nter@21348
|
355 {
|
pascal@20051
|
356 # Backup existing php.ini
|
Hans-G?nter@21348
|
357 if [ -f "$1/etc/php.ini" ]
|
Hans-G?nter@21348
|
358 then
|
pascal@20051
|
359 cp "$1/etc/php.ini" "$1/etc/php.ini.bak"
|
pascal@20051
|
360 fi
|
pascal@20051
|
361 }
|
pascal@20051
|
362
|
Hans-G?nter@21348
|
363 post_install_php_common()
|
Hans-G?nter@21348
|
364 {
|
al@20534
|
365 # Restore original php.ini
|
Hans-G?nter@21348
|
366 if [ -f "$1/etc/php.ini.bak" ]
|
Hans-G?nter@21348
|
367 then
|
al@20534
|
368 mv -f "$1/etc/php.ini.bak" "$1/etc/php.ini"
|
al@20534
|
369 fi
|
al@20534
|
370 }
|
al@20534
|
371
|
al@20534
|
372 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
373 pre_install_php_curl()
|
Hans-G?nter@21348
|
374 {
|
Hans-G?nter@21348
|
375 while read daemon file
|
Hans-G?nter@21348
|
376 do
|
Hans-G?nter@21348
|
377 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21348
|
378 then
|
Hans-G?nter@21348
|
379 /etc/init.d/$daemon stop
|
Hans-G?nter@21348
|
380 fi
|
Hans-G?nter@21348
|
381 done <<EOT
|
Hans-G?nter@21348
|
382 apache apache/httpd.pid
|
Hans-G?nter@21348
|
383 lighttpd lighttpd.pid
|
Hans-G?nter@21348
|
384 EOT
|
Hans-G?nter@21348
|
385 }
|
Hans-G?nter@21348
|
386
|
Hans-G?nter@21348
|
387 post_install_php_curl()
|
Hans-G?nter@21348
|
388 {
|
Hans-G?nter@21348
|
389 grep -q ^extension=curl.so "$1/etc/php.ini" ||
|
Hans-G?nter@21348
|
390 sed -e 's|extension=msql.so|extension=msql.so\nextension=curl.so|' \
|
Hans-G?nter@21348
|
391 -i "$1/etc/php.ini"
|
Hans-G?nter@21348
|
392
|
Hans-G?nter@21348
|
393 # Start Web server.
|
Hans-G?nter@21348
|
394 while read daemon file
|
Hans-G?nter@21348
|
395 do
|
Hans-G?nter@21348
|
396 [ -z "$1" ] || continue
|
Hans-G?nter@21348
|
397 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21348
|
398 then
|
Hans-G?nter@21348
|
399 /etc/init.d/$daemon stop
|
Hans-G?nter@21348
|
400 sleep 2
|
Hans-G?nter@21348
|
401 fi
|
Hans-G?nter@21348
|
402 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21348
|
403 then
|
Hans-G?nter@21348
|
404 /etc/init.d/$daemon start
|
Hans-G?nter@21348
|
405 fi
|
Hans-G?nter@21348
|
406 done <<EOT
|
Hans-G?nter@21348
|
407 apache apache/httpd.pid
|
Hans-G?nter@21348
|
408 lighttpd lighttpd.pid
|
Hans-G?nter@21348
|
409 EOT
|
Hans-G?nter@21348
|
410 }
|
Hans-G?nter@21348
|
411
|
Hans-G?nter@21348
|
412 pre_remove_php_curl()
|
Hans-G?nter@21348
|
413 {
|
Hans-G?nter@21348
|
414 sed -i '/.*=curl.so.*/d' /etc/php.ini
|
Hans-G?nter@21348
|
415
|
Hans-G?nter@21348
|
416 # Start Web server.
|
Hans-G?nter@21348
|
417 while read daemon file
|
Hans-G?nter@21348
|
418 do
|
Hans-G?nter@21348
|
419 [ -z "$1" ] || continue
|
Hans-G?nter@21348
|
420 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21348
|
421 then
|
Hans-G?nter@21348
|
422 /etc/init.d/$daemon stop
|
Hans-G?nter@21348
|
423 sleep 2
|
Hans-G?nter@21348
|
424 fi
|
Hans-G?nter@21348
|
425 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21348
|
426 then
|
Hans-G?nter@21348
|
427 /etc/init.d/$daemon start
|
Hans-G?nter@21348
|
428 fi
|
Hans-G?nter@21348
|
429 done <<EOT
|
Hans-G?nter@21348
|
430 apache apache/httpd.pid
|
Hans-G?nter@21348
|
431 lighttpd lighttpd.pid
|
Hans-G?nter@21348
|
432 EOT
|
Hans-G?nter@21348
|
433 }
|
Hans-G?nter@21348
|
434
|
Hans-G?nter@21348
|
435 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
436 pre_install_php_dba()
|
Hans-G?nter@21348
|
437 {
|
Hans-G?nter@21348
|
438 while read daemon file
|
Hans-G?nter@21348
|
439 do
|
Hans-G?nter@21348
|
440 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21348
|
441 then
|
Hans-G?nter@21348
|
442 /etc/init.d/$daemon stop
|
Hans-G?nter@21348
|
443 fi
|
Hans-G?nter@21348
|
444 done <<EOT
|
Hans-G?nter@21348
|
445 apache apache/httpd.pid
|
Hans-G?nter@21348
|
446 lighttpd lighttpd.pid
|
Hans-G?nter@21348
|
447 EOT
|
Hans-G?nter@21348
|
448 }
|
Hans-G?nter@21348
|
449
|
Hans-G?nter@21348
|
450 post_install_php_dba()
|
Hans-G?nter@21348
|
451 {
|
Hans-G?nter@21348
|
452 grep -q ^extension=dba.so "$1/etc/php.ini" ||
|
Hans-G?nter@21348
|
453 sed -e 's|extension=msql.so|extension=msql.so\nextension=dba.so|' \
|
Hans-G?nter@21348
|
454 -i "$1/etc/php.ini"
|
Hans-G?nter@21348
|
455
|
Hans-G?nter@21348
|
456 # Start Web server.
|
Hans-G?nter@21348
|
457 while read daemon file
|
Hans-G?nter@21348
|
458 do
|
Hans-G?nter@21348
|
459 [ -z "$1" ] || continue
|
Hans-G?nter@21348
|
460 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21348
|
461 then
|
Hans-G?nter@21348
|
462 /etc/init.d/$daemon stop
|
Hans-G?nter@21348
|
463 sleep 2
|
Hans-G?nter@21348
|
464 fi
|
Hans-G?nter@21348
|
465 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21348
|
466 then
|
Hans-G?nter@21348
|
467 /etc/init.d/$daemon start
|
Hans-G?nter@21348
|
468 fi
|
Hans-G?nter@21348
|
469 done <<EOT
|
Hans-G?nter@21348
|
470 apache apache/httpd.pid
|
Hans-G?nter@21348
|
471 lighttpd lighttpd.pid
|
Hans-G?nter@21348
|
472 EOT
|
Hans-G?nter@21348
|
473 }
|
Hans-G?nter@21348
|
474
|
Hans-G?nter@21348
|
475 pre_remove_php_dba()
|
Hans-G?nter@21348
|
476 {
|
Hans-G?nter@21348
|
477 sed -i '/.*=dba.so.*/d' /etc/php.ini
|
Hans-G?nter@21348
|
478
|
Hans-G?nter@21348
|
479 # Start Web server.
|
Hans-G?nter@21348
|
480 while read daemon file
|
Hans-G?nter@21348
|
481 do
|
Hans-G?nter@21348
|
482 [ -z "$1" ] || continue
|
Hans-G?nter@21348
|
483 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21348
|
484 then
|
Hans-G?nter@21348
|
485 /etc/init.d/$daemon stop
|
Hans-G?nter@21348
|
486 sleep 2
|
Hans-G?nter@21348
|
487 fi
|
Hans-G?nter@21348
|
488 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21348
|
489 then
|
Hans-G?nter@21348
|
490 /etc/init.d/$daemon start
|
Hans-G?nter@21348
|
491 fi
|
Hans-G?nter@21348
|
492 done <<EOT
|
Hans-G?nter@21348
|
493 apache apache/httpd.pid
|
Hans-G?nter@21348
|
494 lighttpd lighttpd.pid
|
Hans-G?nter@21348
|
495 EOT
|
Hans-G?nter@21348
|
496 }
|
Hans-G?nter@21348
|
497
|
Hans-G?nter@21348
|
498 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
499 pre_install_php_gd()
|
Hans-G?nter@21348
|
500 {
|
Hans-G?nter@21348
|
501 while read daemon file
|
Hans-G?nter@21348
|
502 do
|
Hans-G?nter@21348
|
503 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21348
|
504 then
|
Hans-G?nter@21348
|
505 /etc/init.d/$daemon stop
|
Hans-G?nter@21348
|
506 fi
|
Hans-G?nter@21348
|
507 done <<EOT
|
Hans-G?nter@21348
|
508 apache apache/httpd.pid
|
Hans-G?nter@21348
|
509 lighttpd lighttpd.pid
|
Hans-G?nter@21348
|
510 EOT
|
Hans-G?nter@21348
|
511 }
|
Hans-G?nter@21348
|
512
|
Hans-G?nter@21348
|
513 post_install_php_gd()
|
Hans-G?nter@21348
|
514 {
|
Hans-G?nter@21348
|
515 grep -q ^extension=gd.so "$1/etc/php.ini" ||
|
Hans-G?nter@21348
|
516 sed -e 's|extension=msql.so|extension=msql.so\nextension=gd.so|' \
|
Hans-G?nter@21348
|
517 -i "$1/etc/php.ini"
|
Hans-G?nter@21348
|
518
|
Hans-G?nter@21348
|
519 # Start Web server.
|
Hans-G?nter@21348
|
520 while read daemon file
|
Hans-G?nter@21348
|
521 do
|
Hans-G?nter@21348
|
522 [ -z "$1" ] || continue
|
Hans-G?nter@21348
|
523 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21348
|
524 then
|
Hans-G?nter@21348
|
525 /etc/init.d/$daemon stop
|
Hans-G?nter@21348
|
526 sleep 2
|
Hans-G?nter@21348
|
527 fi
|
Hans-G?nter@21348
|
528 if [ -z "$1" -a -f /etc/init.d/$daemon ]
|
Hans-G?nter@21348
|
529 then
|
Hans-G?nter@21348
|
530 /etc/init.d/$daemon start
|
Hans-G?nter@21348
|
531 fi
|
Hans-G?nter@21348
|
532 done <<EOT
|
Hans-G?nter@21348
|
533 apache apache/httpd.pid
|
Hans-G?nter@21348
|
534 lighttpd lighttpd.pid
|
Hans-G?nter@21348
|
535 EOT
|
Hans-G?nter@21348
|
536 }
|
Hans-G?nter@21348
|
537
|
Hans-G?nter@21348
|
538 pre_remove_php_gd()
|
Hans-G?nter@21348
|
539 {
|
Hans-G?nter@21348
|
540 sed -i '/.*=gd.so.*/d' "$1/etc/php.ini"
|
Hans-G?nter@21348
|
541
|
Hans-G?nter@21348
|
542 # Start Web server.
|
Hans-G?nter@21348
|
543 while read daemon file
|
Hans-G?nter@21348
|
544 do
|
Hans-G?nter@21348
|
545 if [ -f /etc/init.d/$daemon -a -f "/var/run/$file" ]
|
Hans-G?nter@21348
|
546 then
|
Hans-G?nter@21348
|
547 [ -z "$1" ] || continue
|
Hans-G?nter@21348
|
548 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21348
|
549 then
|
Hans-G?nter@21348
|
550 /etc/init.d/$daemon stop
|
Hans-G?nter@21348
|
551 sleep 2
|
Hans-G?nter@21348
|
552 fi
|
Hans-G?nter@21348
|
553 if [ -z "$1" -a -f /etc/init.d/$daemon ]
|
Hans-G?nter@21348
|
554 then
|
Hans-G?nter@21348
|
555 /etc/init.d/$daemon start
|
Hans-G?nter@21348
|
556 fi
|
Hans-G?nter@21348
|
557 fi
|
Hans-G?nter@21348
|
558 done <<EOT
|
Hans-G?nter@21348
|
559 apache apache/httpd.pid
|
Hans-G?nter@21348
|
560 lighttpd lighttpd.pid
|
Hans-G?nter@21348
|
561 EOT
|
Hans-G?nter@21348
|
562 }
|
Hans-G?nter@21348
|
563
|
Hans-G?nter@21348
|
564 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
565 pre_install_php_imap()
|
Hans-G?nter@21348
|
566 {
|
pascal@20051
|
567 while read daemon file; do
|
Hans-G?nter@21402
|
568 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
569 then
|
pascal@20051
|
570 /etc/init.d/$daemon stop
|
pascal@20051
|
571 fi
|
pascal@20051
|
572 done <<EOT
|
al@20534
|
573 apache apache/httpd.pid
|
pascal@20051
|
574 lighttpd lighttpd.pid
|
pascal@20051
|
575 EOT
|
pascal@20051
|
576 }
|
pascal@20051
|
577
|
Hans-G?nter@21348
|
578 post_install_php_imap()
|
Hans-G?nter@21348
|
579 {
|
al@20534
|
580 grep -q ^extension=imap.so "$1/etc/php.ini" ||
|
al@20534
|
581 sed -e 's|extension=msql.so|extension=msql.so\nextension=imap.so|' -i "$1/etc/php.ini"
|
al@20534
|
582
|
pascal@20051
|
583 # Start Web server.
|
Hans-G?nter@21402
|
584 while read daemon file
|
Hans-G?nter@21402
|
585 do
|
pascal@20051
|
586 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
587 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
588 then
|
pascal@20051
|
589 /etc/init.d/$daemon stop
|
pascal@20051
|
590 sleep 2
|
pascal@20051
|
591 fi
|
Hans-G?nter@21402
|
592 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
593 then
|
pascal@20051
|
594 /etc/init.d/$daemon start
|
pascal@20051
|
595 fi
|
Hans-G?nter@21402
|
596 done <<EOT
|
al@20534
|
597 apache apache/httpd.pid
|
pascal@20051
|
598 lighttpd lighttpd.pid
|
pascal@20051
|
599 EOT
|
pascal@20051
|
600 }
|
pascal@20051
|
601
|
Hans-G?nter@21348
|
602 pre_remove_php_imap()
|
Hans-G?nter@21348
|
603 {
|
pascal@20051
|
604 sed -i '/.*=imap.so.*/d' /etc/php.ini
|
pascal@20051
|
605
|
pascal@20051
|
606 # Start Web server.
|
Hans-G?nter@21402
|
607 while read daemon file
|
Hans-G?nter@21402
|
608 do
|
pascal@20051
|
609 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
610 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
611 then
|
pascal@20051
|
612 /etc/init.d/$daemon stop
|
pascal@20051
|
613 sleep 2
|
pascal@20051
|
614 fi
|
Hans-G?nter@21402
|
615 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
616 then
|
pascal@20051
|
617 /etc/init.d/$daemon start
|
pascal@20051
|
618 fi
|
Hans-G?nter@21402
|
619 done <<EOT
|
al@20534
|
620 apache apache/httpd.pid
|
pascal@20051
|
621 lighttpd lighttpd.pid
|
pascal@20051
|
622 EOT
|
pascal@20051
|
623 }
|
pascal@20051
|
624
|
al@20534
|
625 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
626 pre_install_php_ldap()
|
Hans-G?nter@21348
|
627 {
|
Hans-G?nter@21402
|
628 while read daemon file
|
Hans-G?nter@21402
|
629 do
|
Hans-G?nter@21402
|
630 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
631 then
|
pascal@20051
|
632 /etc/init.d/$daemon stop
|
pascal@20051
|
633 fi
|
Hans-G?nter@21402
|
634 done <<EOT
|
al@20534
|
635 apache apache/httpd.pid
|
pascal@20051
|
636 lighttpd lighttpd.pid
|
pascal@20051
|
637 EOT
|
pascal@20051
|
638 }
|
pascal@20051
|
639
|
Hans-G?nter@21348
|
640 post_install_php_ldap()
|
Hans-G?nter@21348
|
641 {
|
al@20534
|
642 grep -q ^extension=ldap.so "$1/etc/php.ini" ||
|
al@20534
|
643 sed -e 's|extension=msql.so|extension=msql.so\nextension=ldap.so|' -i "$1/etc/php.ini"
|
al@20534
|
644
|
pascal@20051
|
645 # Start Web server.
|
Hans-G?nter@21402
|
646 while read daemon file
|
Hans-G?nter@21402
|
647 do
|
pascal@20051
|
648 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
649 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
650 then
|
pascal@20051
|
651 /etc/init.d/$daemon stop
|
pascal@20051
|
652 sleep 2
|
pascal@20051
|
653 fi
|
Hans-G?nter@21402
|
654 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
655 then
|
pascal@20051
|
656 /etc/init.d/$daemon start
|
pascal@20051
|
657 fi
|
Hans-G?nter@21402
|
658 done <<EOT
|
al@20534
|
659 apache apache/httpd.pid
|
pascal@20051
|
660 lighttpd lighttpd.pid
|
pascal@20051
|
661 EOT
|
pascal@20051
|
662 }
|
pascal@20051
|
663
|
Hans-G?nter@21348
|
664 pre_remove_php_ldap()
|
Hans-G?nter@21348
|
665 {
|
pascal@20051
|
666 sed -i '/.*=ldap.so.*/d' /etc/php.ini
|
pascal@20051
|
667
|
pascal@20051
|
668 # Start Web server.
|
Hans-G?nter@21402
|
669 while read daemon file
|
Hans-G?nter@21402
|
670 do
|
pascal@20051
|
671 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
672 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
673 then
|
pascal@20051
|
674 /etc/init.d/$daemon stop
|
pascal@20051
|
675 sleep 2
|
pascal@20051
|
676 fi
|
Hans-G?nter@21402
|
677 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
678 then
|
pascal@20051
|
679 /etc/init.d/$daemon start
|
pascal@20051
|
680 fi
|
Hans-G?nter@21402
|
681 done <<EOT
|
al@20534
|
682 apache apache/httpd.pid
|
pascal@20051
|
683 lighttpd lighttpd.pid
|
pascal@20051
|
684 EOT
|
pascal@20051
|
685 }
|
pascal@20051
|
686
|
al@20534
|
687 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
688 pre_install_php_mcrypt()
|
Hans-G?nter@21348
|
689 {
|
Hans-G?nter@21402
|
690 while read daemon file
|
Hans-G?nter@21402
|
691 do
|
Hans-G?nter@21402
|
692 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
693 then
|
pascal@20051
|
694 /etc/init.d/$daemon stop
|
pascal@20051
|
695 fi
|
Hans-G?nter@21402
|
696 done <<EOT
|
al@20534
|
697 apache apache/httpd.pid
|
pascal@20051
|
698 lighttpd lighttpd.pid
|
pascal@20051
|
699 EOT
|
pascal@20051
|
700 }
|
pascal@20051
|
701
|
Hans-G?nter@21348
|
702 post_install_php_mcrypt()
|
Hans-G?nter@21348
|
703 {
|
al@20534
|
704 grep -q ^extension=mcrypt.so "$1/etc/php.ini" ||
|
Hans-G?nter@21402
|
705 sed -e 's|extension=msql.so|extension=msql.so\nextension=mcrypt.so|' \
|
Hans-G?nter@21402
|
706 -i "$1/etc/php.ini"
|
al@20534
|
707
|
pascal@20051
|
708 # Start Web server.
|
Hans-G?nter@21402
|
709 while read daemon file
|
Hans-G?nter@21402
|
710 do
|
pascal@20051
|
711 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
712 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
713 then
|
pascal@20051
|
714 /etc/init.d/$daemon stop
|
pascal@20051
|
715 sleep 2
|
pascal@20051
|
716 fi
|
Hans-G?nter@21402
|
717 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
718 then
|
pascal@20051
|
719 /etc/init.d/$daemon start
|
pascal@20051
|
720 fi
|
Hans-G?nter@21402
|
721 done <<EOT
|
al@20534
|
722 apache apache/httpd.pid
|
pascal@20051
|
723 lighttpd lighttpd.pid
|
pascal@20051
|
724 EOT
|
pascal@20051
|
725 }
|
pascal@20051
|
726
|
Hans-G?nter@21348
|
727 pre_remove_php_mcrypt()
|
Hans-G?nter@21348
|
728 {
|
pascal@20051
|
729 sed -i '/.*=mcrypt.so.*/d' /etc/php.ini
|
pascal@20051
|
730
|
pascal@20051
|
731 # Start Web server.
|
Hans-G?nter@21402
|
732 while read daemon file
|
Hans-G?nter@21402
|
733 do
|
pascal@20051
|
734 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
735 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
736 then
|
pascal@20051
|
737 /etc/init.d/$daemon stop
|
pascal@20051
|
738 sleep 2
|
pascal@20051
|
739 fi
|
Hans-G?nter@21402
|
740 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
741 then
|
pascal@20051
|
742 /etc/init.d/$daemon start
|
pascal@20051
|
743 fi
|
Hans-G?nter@21402
|
744 done <<EOT
|
al@20534
|
745 apache apache/httpd.pid
|
pascal@20051
|
746 lighttpd lighttpd.pid
|
pascal@20051
|
747 EOT
|
pascal@20051
|
748 }
|
pascal@20051
|
749
|
al@20534
|
750 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
751 pre_install_php_mysqli()
|
Hans-G?nter@21348
|
752 {
|
Hans-G?nter@21402
|
753 while read daemon file
|
Hans-G?nter@21402
|
754 do
|
Hans-G?nter@21402
|
755 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
756 then
|
pascal@20051
|
757 /etc/init.d/$daemon stop
|
pascal@20051
|
758 fi
|
Hans-G?nter@21402
|
759 done <<EOT
|
al@20534
|
760 apache apache/httpd.pid
|
pascal@20051
|
761 lighttpd lighttpd.pid
|
pascal@20051
|
762 EOT
|
pascal@20051
|
763 }
|
pascal@20051
|
764
|
Hans-G?nter@21348
|
765 post_install_php_mysqli()
|
Hans-G?nter@21348
|
766 {
|
al@20534
|
767 grep -q ^extension=mysqli.so "$1/etc/php.ini" ||
|
Hans-G?nter@21402
|
768 sed -e 's|extension=msql.so|extension=msql.so\nextension=mysqli.so|' \
|
Hans-G?nter@21402
|
769 -i "$1/etc/php.ini"
|
al@20534
|
770
|
pascal@20051
|
771 # Start Web server.
|
Hans-G?nter@21402
|
772 while read daemon file
|
Hans-G?nter@21402
|
773 do
|
pascal@20051
|
774 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
775 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
776 then
|
pascal@20051
|
777 /etc/init.d/$daemon stop
|
pascal@20051
|
778 sleep 2
|
pascal@20051
|
779 fi
|
Hans-G?nter@21402
|
780 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
781 then
|
pascal@20051
|
782 /etc/init.d/$daemon start
|
pascal@20051
|
783 fi
|
Hans-G?nter@21402
|
784 done <<EOT
|
al@20534
|
785 apache apache/httpd.pid
|
pascal@20051
|
786 lighttpd lighttpd.pid
|
pascal@20051
|
787 EOT
|
pascal@20051
|
788 }
|
pascal@20051
|
789
|
Hans-G?nter@21348
|
790 pre_remove_php_mysqli()
|
Hans-G?nter@21348
|
791 {
|
pascal@20051
|
792 sed -i '/.*=mysqli.so.*/d' /etc/php.ini
|
pascal@20051
|
793
|
pascal@20051
|
794 # Start Web server.
|
Hans-G?nter@21402
|
795 while read daemon file
|
Hans-G?nter@21402
|
796 do
|
pascal@20051
|
797 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
798 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
799 then
|
pascal@20051
|
800 /etc/init.d/$daemon stop
|
pascal@20051
|
801 sleep 2
|
pascal@20051
|
802 fi
|
Hans-G?nter@21402
|
803 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
804 then
|
pascal@20051
|
805 /etc/init.d/$daemon start
|
pascal@20051
|
806 fi
|
Hans-G?nter@21402
|
807 done <<EOT
|
al@20534
|
808 apache apache/httpd.pid
|
pascal@20051
|
809 lighttpd lighttpd.pid
|
pascal@20051
|
810 EOT
|
pascal@20051
|
811 }
|
pascal@20051
|
812
|
al@20534
|
813 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
814 pre_install_php_mysql()
|
Hans-G?nter@21348
|
815 {
|
Hans-G?nter@21402
|
816 while read daemon file
|
Hans-G?nter@21402
|
817 do
|
Hans-G?nter@21402
|
818 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
819 then
|
pascal@20051
|
820 /etc/init.d/$daemon stop
|
pascal@20051
|
821 fi
|
Hans-G?nter@21402
|
822 done <<EOT
|
al@20534
|
823 apache apache/httpd.pid
|
pascal@20051
|
824 lighttpd lighttpd.pid
|
pascal@20051
|
825 EOT
|
pascal@20051
|
826 }
|
pascal@20051
|
827
|
Hans-G?nter@21348
|
828 post_install_php_mysql()
|
Hans-G?nter@21348
|
829 {
|
al@20534
|
830 grep -q ^extension=mysql.so "$1/etc/php.ini" ||
|
Hans-G?nter@21402
|
831 sed -e 's|extension=msql.so|extension=msql.so\nextension=mysql.so|' \
|
Hans-G?nter@21402
|
832 -i "$1/etc/php.ini"
|
al@20534
|
833
|
pascal@20051
|
834 # Start Web server.
|
Hans-G?nter@21402
|
835 while read daemon file
|
Hans-G?nter@21402
|
836 do
|
pascal@20051
|
837 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
838 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
839 then
|
pascal@20051
|
840 /etc/init.d/$daemon stop
|
pascal@20051
|
841 sleep 2
|
pascal@20051
|
842 fi
|
Hans-G?nter@21402
|
843 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
844 then
|
pascal@20051
|
845 /etc/init.d/$daemon start
|
pascal@20051
|
846 fi
|
Hans-G?nter@21402
|
847 done <<EOT
|
al@20534
|
848 apache apache/httpd.pid
|
pascal@20051
|
849 lighttpd lighttpd.pid
|
pascal@20051
|
850 EOT
|
pascal@20051
|
851 }
|
pascal@20051
|
852
|
Hans-G?nter@21348
|
853 pre_remove_php_mysql()
|
Hans-G?nter@21348
|
854 {
|
pascal@20051
|
855 sed -i '/.*=mysql.so.*/d' /etc/php.ini
|
pascal@20051
|
856
|
pascal@20051
|
857 # Start Web server.
|
Hans-G?nter@21402
|
858 while read daemon file
|
Hans-G?nter@21402
|
859 do
|
pascal@20051
|
860 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
861 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
862 then
|
pascal@20051
|
863 /etc/init.d/$daemon stop
|
pascal@20051
|
864 sleep 2
|
pascal@20051
|
865 fi
|
Hans-G?nter@21402
|
866 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
867 then
|
pascal@20051
|
868 /etc/init.d/$daemon start
|
pascal@20051
|
869 fi
|
Hans-G?nter@21402
|
870 done <<EOT
|
al@20534
|
871 apache apache/httpd.pid
|
pascal@20051
|
872 lighttpd lighttpd.pid
|
pascal@20051
|
873 EOT
|
pascal@20051
|
874 }
|
pascal@20051
|
875
|
al@20534
|
876 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
877 pre_install_php_odbc()
|
Hans-G?nter@21348
|
878 {
|
Hans-G?nter@21402
|
879 while read daemon file
|
Hans-G?nter@21402
|
880 do
|
Hans-G?nter@21402
|
881 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
882 then
|
pascal@20051
|
883 /etc/init.d/$daemon stop
|
pascal@20051
|
884 fi
|
Hans-G?nter@21402
|
885 done <<EOT
|
al@20534
|
886 apache apache/httpd.pid
|
pascal@20051
|
887 lighttpd lighttpd.pid
|
pascal@20051
|
888 EOT
|
pascal@20051
|
889 }
|
pascal@20051
|
890
|
Hans-G?nter@21348
|
891 post_install_php_odbc()
|
Hans-G?nter@21348
|
892 {
|
al@20534
|
893 grep -q ^extension=odbc.so "$1/etc/php.ini" ||
|
Hans-G?nter@21402
|
894 sed -e 's|extension=msql.so|extension=msql.so\nextension=odbc.so|' \
|
Hans-G?nter@21402
|
895 -i "$1/etc/php.ini"
|
al@20534
|
896
|
pascal@20051
|
897 # Start Web server.
|
Hans-G?nter@21402
|
898 while read daemon file
|
Hans-G?nter@21402
|
899 do
|
pascal@20051
|
900 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
901 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
902 then
|
pascal@20051
|
903 /etc/init.d/$daemon stop
|
pascal@20051
|
904 sleep 2
|
pascal@20051
|
905 fi
|
Hans-G?nter@21402
|
906 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
907 then
|
pascal@20051
|
908 /etc/init.d/$daemon start
|
pascal@20051
|
909 fi
|
Hans-G?nter@21402
|
910 done <<EOT
|
al@20534
|
911 apache apache/httpd.pid
|
pascal@20051
|
912 lighttpd lighttpd.pid
|
pascal@20051
|
913 EOT
|
pascal@20051
|
914 }
|
pascal@20051
|
915
|
Hans-G?nter@21348
|
916 pre_remove_php_odbc()
|
Hans-G?nter@21348
|
917 {
|
pascal@20051
|
918 sed -i '/.*=odbc.so.*/d' /etc/php.ini
|
pascal@20051
|
919
|
pascal@20051
|
920 # Start Web server.
|
Hans-G?nter@21402
|
921 while read daemon file
|
Hans-G?nter@21402
|
922 do
|
pascal@20051
|
923 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
924 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
925 then
|
pascal@20051
|
926 /etc/init.d/$daemon stop
|
pascal@20051
|
927 sleep 2
|
pascal@20051
|
928 fi
|
Hans-G?nter@21402
|
929 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
930 then
|
pascal@20051
|
931 /etc/init.d/$daemon start
|
pascal@20051
|
932 fi
|
Hans-G?nter@21402
|
933 done <<EOT
|
al@20534
|
934 apache apache/httpd.pid
|
pascal@20051
|
935 lighttpd lighttpd.pid
|
pascal@20051
|
936 EOT
|
pascal@20051
|
937 }
|
pascal@20051
|
938
|
al@20534
|
939 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
940 pre_install_php_openssl()
|
Hans-G?nter@21348
|
941 {
|
Hans-G?nter@21402
|
942 while read daemon file
|
Hans-G?nter@21402
|
943 do
|
Hans-G?nter@21402
|
944 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
945 then
|
pascal@20051
|
946 /etc/init.d/$daemon stop
|
pascal@20051
|
947 fi
|
Hans-G?nter@21402
|
948 done <<EOT
|
al@20534
|
949 apache apache/httpd.pid
|
pascal@20051
|
950 lighttpd lighttpd.pid
|
pascal@20051
|
951 EOT
|
pascal@20051
|
952 }
|
pascal@20051
|
953
|
Hans-G?nter@21348
|
954 post_install_php_openssl()
|
Hans-G?nter@21348
|
955 {
|
al@20534
|
956 grep -q ^extension=openssl.so "$1/etc/php.ini" ||
|
Hans-G?nter@21402
|
957 sed -e 's|extension=msql.so|extension=msql.so\nextension=openssl.so|' \
|
Hans-G?nter@21402
|
958 -i "$1/etc/php.ini"
|
al@20534
|
959
|
pascal@20051
|
960 # Start Web server.
|
Hans-G?nter@21402
|
961 while read daemon file
|
Hans-G?nter@21402
|
962 do
|
pascal@20051
|
963 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
964 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
965 then
|
pascal@20051
|
966 /etc/init.d/$daemon stop
|
pascal@20051
|
967 sleep 2
|
pascal@20051
|
968 fi
|
Hans-G?nter@21402
|
969 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
970 then
|
pascal@20051
|
971 /etc/init.d/$daemon start
|
pascal@20051
|
972 fi
|
Hans-G?nter@21402
|
973 done <<EOT
|
al@20534
|
974 apache apache/httpd.pid
|
pascal@20051
|
975 lighttpd lighttpd.pid
|
pascal@20051
|
976 EOT
|
pascal@20051
|
977 }
|
pascal@20051
|
978
|
Hans-G?nter@21348
|
979 pre_remove_php_openssl()
|
Hans-G?nter@21348
|
980 {
|
pascal@20051
|
981 sed -i '/.*=openssl.so.*/d' /etc/php.ini
|
pascal@20051
|
982
|
pascal@20051
|
983 # Start Web server.
|
Hans-G?nter@21402
|
984 while read daemon file
|
Hans-G?nter@21402
|
985 do
|
pascal@20051
|
986 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
987 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
988 then
|
pascal@20051
|
989 /etc/init.d/$daemon stop
|
pascal@20051
|
990 sleep 2
|
pascal@20051
|
991 fi
|
Hans-G?nter@21402
|
992 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
993 then
|
pascal@20051
|
994 /etc/init.d/$daemon start
|
pascal@20051
|
995 fi
|
Hans-G?nter@21402
|
996 done <<EOT
|
al@20534
|
997 apache apache/httpd.pid
|
pascal@20051
|
998 lighttpd lighttpd.pid
|
pascal@20051
|
999 EOT
|
pascal@20051
|
1000 }
|
pascal@20051
|
1001
|
al@20534
|
1002 # -----------------------------------------------------------------------------
|
Hans-G?nter@21402
|
1003 pre_install_pdo_mysql()
|
Hans-G?nter@21402
|
1004 {
|
Hans-G?nter@21402
|
1005 while read daemon file
|
Hans-G?nter@21402
|
1006 do
|
Hans-G?nter@21402
|
1007 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1008 then
|
pascal@20051
|
1009 /etc/init.d/$daemon stop
|
pascal@20051
|
1010 fi
|
Hans-G?nter@21402
|
1011 done <<EOT
|
al@20534
|
1012 apache apache/httpd.pid
|
pascal@20051
|
1013 lighttpd lighttpd.pid
|
pascal@20051
|
1014 EOT
|
pascal@20051
|
1015 }
|
pascal@20051
|
1016
|
Hans-G?nter@21348
|
1017 post_install_pdo_mysql()
|
Hans-G?nter@21348
|
1018 {
|
al@20534
|
1019 grep -q ^extension=pdo_mysql.so "$1/etc/php.ini" ||
|
Hans-G?nter@21402
|
1020 sed -e 's|extension=msql.so|extension=msql.so\nextension=pdo_mysql.so|' \
|
Hans-G?nter@21402
|
1021 -i "$1/etc/php.ini"
|
al@20534
|
1022
|
pascal@20051
|
1023 # Start Web server.
|
Hans-G?nter@21402
|
1024 while read daemon file
|
Hans-G?nter@21402
|
1025 do
|
pascal@20051
|
1026 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1027 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1028 then
|
pascal@20051
|
1029 /etc/init.d/$daemon stop
|
pascal@20051
|
1030 sleep 2
|
pascal@20051
|
1031 fi
|
Hans-G?nter@21402
|
1032 if [ -z "$1" -a -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1033 then
|
pascal@20051
|
1034 /etc/init.d/$daemon start
|
pascal@20051
|
1035 fi
|
Hans-G?nter@21402
|
1036 done <<EOT
|
al@20534
|
1037 apache apache/httpd.pid
|
pascal@20051
|
1038 lighttpd lighttpd.pid
|
pascal@20051
|
1039 EOT
|
pascal@20051
|
1040 }
|
pascal@20051
|
1041
|
Hans-G?nter@21348
|
1042 pre_remove_pdo_mysql()
|
Hans-G?nter@21348
|
1043 {
|
pascal@20051
|
1044 sed -i '/.*=pdo_mysql.so.*/d' /etc/php.ini
|
pascal@20051
|
1045
|
pascal@20051
|
1046 # Start Web server.
|
Hans-G?nter@21402
|
1047 while read daemon file
|
Hans-G?nter@21402
|
1048 do
|
pascal@20051
|
1049 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1050 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1051 then
|
pascal@20051
|
1052 /etc/init.d/$daemon stop
|
pascal@20051
|
1053 sleep 2
|
pascal@20051
|
1054 fi
|
Hans-G?nter@21402
|
1055 if [ -z "$1" -a -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1056 then
|
pascal@20051
|
1057 /etc/init.d/$daemon start
|
pascal@20051
|
1058 fi
|
Hans-G?nter@21402
|
1059 done <<EOT
|
al@20534
|
1060 apache apache/httpd.pid
|
pascal@20051
|
1061 lighttpd lighttpd.pid
|
pascal@20051
|
1062 EOT
|
pascal@20051
|
1063 }
|
pascal@20051
|
1064
|
al@20534
|
1065 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
1066 pre_install_pdo_pgsql()
|
Hans-G?nter@21348
|
1067 {
|
Hans-G?nter@21402
|
1068 while read daemon file
|
Hans-G?nter@21402
|
1069 do
|
Hans-G?nter@21402
|
1070 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1071 then
|
pascal@20051
|
1072 /etc/init.d/$daemon stop
|
pascal@20051
|
1073 fi
|
Hans-G?nter@21402
|
1074 done <<EOT
|
al@20534
|
1075 apache apache/httpd.pid
|
pascal@20051
|
1076 lighttpd lighttpd.pid
|
pascal@20051
|
1077 EOT
|
pascal@20051
|
1078 }
|
pascal@20051
|
1079
|
Hans-G?nter@21348
|
1080 post_install_pdo_pgsql()
|
Hans-G?nter@21348
|
1081 {
|
al@20534
|
1082 grep -q ^extension=pdo_pgsql.so "$1/etc/php.ini" ||
|
Hans-G?nter@21402
|
1083 sed -e 's|extension=msql.so|extension=msql.so\nextension=pdo_pgsql.so|' \
|
Hans-G?nter@21402
|
1084 -i "$1/etc/php.ini"
|
al@20534
|
1085
|
pascal@20051
|
1086 # Start Web server.
|
Hans-G?nter@21402
|
1087 while read daemon file
|
Hans-G?nter@21402
|
1088 do
|
pascal@20051
|
1089 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1090 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1091 then
|
pascal@20051
|
1092 /etc/init.d/$daemon stop
|
pascal@20051
|
1093 sleep 2
|
pascal@20051
|
1094 fi
|
Hans-G?nter@21402
|
1095 if [ -z "$1" -a -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1096 then
|
pascal@20051
|
1097 /etc/init.d/$daemon start
|
pascal@20051
|
1098 fi
|
Hans-G?nter@21402
|
1099 done <<EOT
|
al@20534
|
1100 apache apache/httpd.pid
|
pascal@20051
|
1101 lighttpd lighttpd.pid
|
pascal@20051
|
1102 EOT
|
pascal@20051
|
1103 }
|
pascal@20051
|
1104
|
Hans-G?nter@21348
|
1105 pre_remove_pdo_pgsql()
|
Hans-G?nter@21348
|
1106 {
|
pascal@20051
|
1107 sed -i '/.*=pdo_pgsql.so.*/d' /etc/php.ini
|
pascal@20051
|
1108
|
pascal@20051
|
1109 # Start Web server.
|
Hans-G?nter@21402
|
1110 while read daemon file
|
Hans-G?nter@21402
|
1111 do
|
pascal@20051
|
1112 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1113 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1114 then
|
pascal@20051
|
1115 /etc/init.d/$daemon stop
|
pascal@20051
|
1116 sleep 2
|
pascal@20051
|
1117 fi
|
Hans-G?nter@21402
|
1118 if [ -z "$1" -a -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1119 then
|
pascal@20051
|
1120 /etc/init.d/$daemon start
|
pascal@20051
|
1121 fi
|
Hans-G?nter@21402
|
1122 done <<EOT
|
al@20534
|
1123 apache apache/httpd.pid
|
pascal@20051
|
1124 lighttpd lighttpd.pid
|
pascal@20051
|
1125 EOT
|
pascal@20051
|
1126 }
|
pascal@20051
|
1127
|
al@20534
|
1128 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
1129 pre_install_php_pear()
|
Hans-G?nter@21348
|
1130 {
|
Hans-G?nter@21402
|
1131 while read daemon file
|
Hans-G?nter@21402
|
1132 do
|
Hans-G?nter@21402
|
1133 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1134 then
|
pascal@20051
|
1135 /etc/init.d/$daemon stop
|
pascal@20051
|
1136 fi
|
Hans-G?nter@21402
|
1137 done <<EOT
|
al@20534
|
1138 apache apache/httpd.pid
|
pascal@20051
|
1139 lighttpd lighttpd.pid
|
pascal@20051
|
1140 EOT
|
pascal@20051
|
1141 }
|
pascal@20051
|
1142
|
Hans-G?nter@21348
|
1143 post_install_php_pear()
|
Hans-G?nter@21348
|
1144 {
|
pascal@20051
|
1145 grep ^include_path "$1/etc/php.ini"
|
Hans-G?nter@21402
|
1146 sed -i 's|/php/includes"|/php/includes"\ninclude_path = ".:/usr/share/php"|' \
|
Hans-G?nter@21402
|
1147 "$1/etc/php.ini"
|
pascal@20051
|
1148 # Restart Web server.
|
Hans-G?nter@21402
|
1149 while read daemon file
|
Hans-G?nter@21402
|
1150 do
|
pascal@20051
|
1151 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1152 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1153 then
|
pascal@20051
|
1154 /etc/init.d/$daemon stop
|
pascal@20051
|
1155 sleep 2
|
pascal@20051
|
1156 fi
|
Hans-G?nter@21402
|
1157 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1158 then
|
pascal@20051
|
1159 /etc/init.d/$daemon start
|
pascal@20051
|
1160 fi
|
Hans-G?nter@21402
|
1161 done <<EOT
|
al@20534
|
1162 apache apache/httpd.pid
|
pascal@20051
|
1163 lighttpd lighttpd.pid
|
pascal@20051
|
1164 EOT
|
pascal@20051
|
1165 }
|
pascal@20051
|
1166
|
al@20534
|
1167 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
1168 pre_install_php_pgsql()
|
Hans-G?nter@21348
|
1169 {
|
Hans-G?nter@21402
|
1170 while read daemon file
|
Hans-G?nter@21402
|
1171 do
|
Hans-G?nter@21402
|
1172 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1173 then
|
pascal@20051
|
1174 /etc/init.d/$daemon stop
|
pascal@20051
|
1175 fi
|
Hans-G?nter@21402
|
1176 done <<EOT
|
al@20534
|
1177 apache apache/httpd.pid
|
pascal@20051
|
1178 lighttpd lighttpd.pid
|
pascal@20051
|
1179 EOT
|
pascal@20051
|
1180 }
|
pascal@20051
|
1181
|
Hans-G?nter@21348
|
1182 post_install_php_pgsql()
|
Hans-G?nter@21348
|
1183 {
|
al@20534
|
1184 grep -q ^extension=pgsql.so "$1/etc/php.ini" ||
|
Hans-G?nter@21402
|
1185 sed -e 's|extension=msql.so|extension=msql.so\nextension=pgsql.so|' \
|
Hans-G?nter@21402
|
1186 -i "$1/etc/php.ini"
|
al@20534
|
1187
|
pascal@20051
|
1188 # Start Web server.
|
Hans-G?nter@21402
|
1189 while read daemon file
|
Hans-G?nter@21402
|
1190 do
|
pascal@20051
|
1191 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1192 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1193 then
|
pascal@20051
|
1194 /etc/init.d/$daemon stop
|
pascal@20051
|
1195 sleep 2
|
pascal@20051
|
1196 fi
|
Hans-G?nter@21402
|
1197 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1198 then
|
pascal@20051
|
1199 /etc/init.d/$daemon start
|
pascal@20051
|
1200 fi
|
Hans-G?nter@21402
|
1201 done <<EOT
|
al@20534
|
1202 apache apache/httpd.pid
|
pascal@20051
|
1203 lighttpd lighttpd.pid
|
pascal@20051
|
1204 EOT
|
pascal@20051
|
1205 }
|
pascal@20051
|
1206
|
Hans-G?nter@21348
|
1207 pre_remove_php_pgsql()
|
Hans-G?nter@21348
|
1208 {
|
pascal@20051
|
1209 sed -i '/.*=pgsql.so.*/d' /etc/php.ini
|
pascal@20051
|
1210
|
pascal@20051
|
1211 # Start Web server.
|
Hans-G?nter@21402
|
1212 while read daemon file
|
Hans-G?nter@21402
|
1213 do
|
pascal@20051
|
1214 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1215 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1216 then
|
pascal@20051
|
1217 /etc/init.d/$daemon stop
|
pascal@20051
|
1218 sleep 2
|
pascal@20051
|
1219 fi
|
Hans-G?nter@21402
|
1220 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1221 then
|
pascal@20051
|
1222 /etc/init.d/$daemon start
|
pascal@20051
|
1223 fi
|
Hans-G?nter@21402
|
1224 done <<EOT
|
al@20534
|
1225 apache apache/httpd.pid
|
pascal@20051
|
1226 lighttpd lighttpd.pid
|
pascal@20051
|
1227 EOT
|
pascal@20051
|
1228 }
|
pascal@20051
|
1229
|
al@20534
|
1230 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
1231 pre_install_php_snmp()
|
Hans-G?nter@21348
|
1232 {
|
Hans-G?nter@21402
|
1233 while read daemon file
|
Hans-G?nter@21402
|
1234 do
|
Hans-G?nter@21402
|
1235 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1236 then
|
pascal@20051
|
1237 /etc/init.d/$daemon stop
|
pascal@20051
|
1238 fi
|
Hans-G?nter@21402
|
1239 done <<EOT
|
al@20534
|
1240 apache apache/httpd.pid
|
pascal@20051
|
1241 lighttpd lighttpd.pid
|
pascal@20051
|
1242 EOT
|
pascal@20051
|
1243 }
|
pascal@20051
|
1244
|
Hans-G?nter@21348
|
1245 post_install_php_snmp()
|
Hans-G?nter@21348
|
1246 {
|
al@20534
|
1247 grep -q ^extension=snmp.so "$1/etc/php.ini" ||
|
Hans-G?nter@21402
|
1248 sed -e 's|extension=msql.so|extension=msql.so\nextension=snmp.so|' \
|
Hans-G?nter@21402
|
1249 -i "$1/etc/php.ini"
|
al@20534
|
1250
|
pascal@20051
|
1251 # Start Web server.
|
Hans-G?nter@21402
|
1252 while read daemon file
|
Hans-G?nter@21402
|
1253 do
|
pascal@20051
|
1254 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1255 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1256 then
|
pascal@20051
|
1257 /etc/init.d/$daemon stop
|
pascal@20051
|
1258 sleep 2
|
pascal@20051
|
1259 fi
|
Hans-G?nter@21402
|
1260 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1261 then
|
pascal@20051
|
1262 /etc/init.d/$daemon start
|
pascal@20051
|
1263 fi
|
Hans-G?nter@21402
|
1264 done <<EOT
|
al@20534
|
1265 apache apache/httpd.pid
|
pascal@20051
|
1266 lighttpd lighttpd.pid
|
pascal@20051
|
1267 EOT
|
pascal@20051
|
1268 }
|
pascal@20051
|
1269
|
Hans-G?nter@21348
|
1270 pre_remove_php_snmp()
|
Hans-G?nter@21348
|
1271 {
|
pascal@20051
|
1272 sed -i '/.*=snmp.so.*/d' /etc/php.ini
|
pascal@20051
|
1273
|
pascal@20051
|
1274 # Start Web server.
|
Hans-G?nter@21402
|
1275 while read daemon file
|
Hans-G?nter@21402
|
1276 do
|
pascal@20051
|
1277 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1278 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1279 then
|
pascal@20051
|
1280 /etc/init.d/$daemon stop
|
pascal@20051
|
1281 sleep 2
|
pascal@20051
|
1282 fi
|
Hans-G?nter@21402
|
1283 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1284 then
|
pascal@20051
|
1285 /etc/init.d/$daemon start
|
pascal@20051
|
1286 fi
|
Hans-G?nter@21402
|
1287 done <<EOT
|
al@20534
|
1288 apache apache/httpd.pid
|
pascal@20051
|
1289 lighttpd lighttpd.pid
|
pascal@20051
|
1290 EOT
|
pascal@20051
|
1291 }
|
pascal@20051
|
1292
|
al@20534
|
1293 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
1294 pre_install_php_soap()
|
Hans-G?nter@21348
|
1295 {
|
Hans-G?nter@21402
|
1296 while read daemon file
|
Hans-G?nter@21402
|
1297 do
|
Hans-G?nter@21402
|
1298 if [ -z "$1" -a -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1299 then
|
pascal@20051
|
1300 /etc/init.d/$daemon stop
|
pascal@20051
|
1301 fi
|
Hans-G?nter@21402
|
1302 done <<EOT
|
al@20534
|
1303 apache apache/httpd.pid
|
pascal@20051
|
1304 lighttpd lighttpd.pid
|
pascal@20051
|
1305 EOT
|
pascal@20051
|
1306 }
|
pascal@20051
|
1307
|
Hans-G?nter@21348
|
1308 post_install_php_soap()
|
Hans-G?nter@21348
|
1309 {
|
al@20534
|
1310 grep -q ^extension=soap.so "$1/etc/php.ini" ||
|
Hans-G?nter@21402
|
1311 sed -e 's|extension=msql.so|extension=msql.so\nextension=soap.so|' \
|
Hans-G?nter@21402
|
1312 -i "$1/etc/php.ini"
|
al@20534
|
1313
|
pascal@20051
|
1314 # Start Web server.
|
Hans-G?nter@21402
|
1315 while read daemon file
|
Hans-G?nter@21402
|
1316 do
|
pascal@20051
|
1317 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1318 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1319 then
|
pascal@20051
|
1320 /etc/init.d/$daemon stop
|
pascal@20051
|
1321 sleep 2
|
pascal@20051
|
1322 fi
|
Hans-G?nter@21402
|
1323 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1324 then
|
pascal@20051
|
1325 /etc/init.d/$daemon start
|
pascal@20051
|
1326 fi
|
Hans-G?nter@21402
|
1327 done <<EOT
|
al@20534
|
1328 apache apache/httpd.pid
|
pascal@20051
|
1329 lighttpd lighttpd.pid
|
pascal@20051
|
1330 EOT
|
pascal@20051
|
1331 }
|
pascal@20051
|
1332
|
Hans-G?nter@21348
|
1333 pre_remove_php_soap()
|
Hans-G?nter@21348
|
1334 {
|
pascal@20051
|
1335 sed -i '/.*=soap.so.*/d' /etc/php.ini
|
pascal@20051
|
1336
|
pascal@20051
|
1337 # Start Web server.
|
Hans-G?nter@21402
|
1338 while read daemon file
|
Hans-G?nter@21402
|
1339 do
|
pascal@20051
|
1340 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1341 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1342 then
|
pascal@20051
|
1343 /etc/init.d/$daemon stop
|
pascal@20051
|
1344 sleep 2
|
pascal@20051
|
1345 fi
|
Hans-G?nter@21402
|
1346 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1347 then
|
pascal@20051
|
1348 /etc/init.d/$daemon start
|
pascal@20051
|
1349 fi
|
Hans-G?nter@21402
|
1350 done <<EOT
|
al@20534
|
1351 apache apache/httpd.pid
|
pascal@20051
|
1352 lighttpd lighttpd.pid
|
pascal@20051
|
1353 EOT
|
pascal@20051
|
1354 }
|
pascal@20051
|
1355
|
al@20534
|
1356 # -----------------------------------------------------------------------------
|
Hans-G?nter@21348
|
1357 post_install_php_sqlite()
|
Hans-G?nter@21348
|
1358 {
|
al@20534
|
1359 grep -q ^extension=sqlite3.so "$1/etc/php.ini" ||
|
Hans-G?nter@21402
|
1360 sed -e 's|extension=msql.so|extension=msql.so\nextension=sqlite3.so|' \
|
Hans-G?nter@21402
|
1361 -i "$1/etc/php.ini"
|
al@20534
|
1362
|
pascal@20051
|
1363 # Start Web server.
|
Hans-G?nter@21402
|
1364 while read daemon file
|
Hans-G?nter@21402
|
1365 do
|
pascal@20051
|
1366 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1367 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1368 then
|
pascal@20051
|
1369 /etc/init.d/$daemon stop
|
pascal@20051
|
1370 sleep 2
|
pascal@20051
|
1371 fi
|
Hans-G?nter@21402
|
1372 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1373 then
|
pascal@20051
|
1374 /etc/init.d/$daemon start
|
pascal@20051
|
1375 fi
|
Hans-G?nter@21402
|
1376 done <<EOT
|
al@20534
|
1377 apache apache/httpd.pid
|
pascal@20051
|
1378 lighttpd lighttpd.pid
|
pascal@20051
|
1379 EOT
|
pascal@20051
|
1380 }
|
pascal@20051
|
1381
|
Hans-G?nter@21348
|
1382 pre_remove_php_sqlite()
|
Hans-G?nter@21348
|
1383 {
|
pascal@20051
|
1384 sed -i '/.*=sqlite3.so.*/d' /etc/php.ini
|
pascal@20051
|
1385
|
pascal@20051
|
1386 # Start Web server.
|
Hans-G?nter@21402
|
1387 while read daemon file
|
Hans-G?nter@21402
|
1388 do
|
pascal@20051
|
1389 [ -z "$1" ] || continue
|
Hans-G?nter@21402
|
1390 if [ -f "/var/run/$file" ]
|
Hans-G?nter@21402
|
1391 then
|
pascal@20051
|
1392 /etc/init.d/$daemon stop
|
pascal@20051
|
1393 sleep 2
|
pascal@20051
|
1394 fi
|
Hans-G?nter@21402
|
1395 if [ -f /etc/init.d/$daemon ]
|
Hans-G?nter@21402
|
1396 then
|
pascal@20051
|
1397 /etc/init.d/$daemon start
|
pascal@20051
|
1398 fi
|
Hans-G?nter@21402
|
1399 done <<EOT
|
al@20534
|
1400 apache apache/httpd.pid
|
pascal@20051
|
1401 lighttpd lighttpd.pid
|
pascal@20051
|
1402 EOT
|
pascal@20051
|
1403 }
|