wok-6.x view php-sqlite/receipt @ rev 14788
dialog: fix dialog.desktop
author | Richard Dunbar <mojo@slitaz.org> |
---|---|
date | Mon Jul 08 02:17:10 2013 +0000 (2013-07-08) |
parents | |
children | 78cb1e930abd |
line source
1 # SliTaz package receipt.
3 PACKAGE="php-sqlite"
4 VERSION="5.4.13"
5 CATEGORY="development"
6 SHORT_DESC="sqlite module for PHP web programming language."
7 MAINTAINER="slaxemulator@gmail.com"
8 DEPENDS="php sqlite"
9 WEB_SITE="http://www.php.net/"
10 WANTED="php"
12 # Rules to gen a SliTaz package suitable for Tazpkg.
13 genpkg_rules()
14 {
15 mkdir -p $fs/usr/share/php
16 cp $(find $install | grep sqlite.so) $fs/usr/share/php/
17 cp $(find $install | grep sqlite3.so) $fs/usr/share/php/
18 cp $(find $install | grep pdo_sqlite.so) $fs/usr/share/php/
19 }
21 post_install()
22 {
23 grep -q ^extension=sqlite3.so $1/etc/php.ini || \
24 sed -e 's|extension=msql.so|extension=msql.so\nextension=sqlite3.so|' -i $1/etc/php.ini
25 # Start Web server.
26 while read daemon file; do
27 [ -z "$1" ] || continue
28 if [ -f "/var/run/$file" ]; then
29 /etc/init.d/$daemon stop
30 sleep 2
31 fi
32 if [ -f /etc/init.d/$daemon ]; then
33 /etc/init.d/$daemon start
34 fi
35 done <<EOT
36 apache apache/httpd.pid
37 lighttpd lighttpd.pid
38 EOT
39 }
41 # Pre and post remove commands for Tazpkg.
42 pre_remove()
43 {
44 sed -i '/.*=sqlite3.so.*/d' /etc/php.ini
46 # Start Web server.
47 while read daemon file; do
48 [ -z "$1" ] || continue
49 if [ -f "/var/run/$file" ]; then
50 /etc/init.d/$daemon stop
51 sleep 2
52 fi
53 if [ -f /etc/init.d/$daemon ]; then
54 /etc/init.d/$daemon start
55 fi
56 done <<EOT
57 apache apache/httpd.pid
58 lighttpd lighttpd.pid
59 EOT
60 }