wok-6.x view phpvirtualbox/receipt @ rev 23600

updated firefox-official (72.0.1 -> 75.0)
author Hans-G?nter Theisgen
date Fri Apr 10 16:03:29 2020 +0100 (2020-04-10)
parents 8dd8bab3f0ca
children 5ea0ce1cecc0
line source
1 # SliTaz package receipt.
3 PACKAGE="phpvirtualbox"
4 VERSION="5.2.1"
5 CATEGORY="network"
6 SHORT_DESC="Virtualbox AJAX interface."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 LICENSE="GPL3"
9 WEB_SITE="https://github.com/phpvirtualbox/phpvirtualbox"
11 TARBALL="$PACKAGE-$VERSION.tar.gz"
12 WGET_URL="$WEB_SITE/archive/${VERSION%.*}-${VERSION##*.}.tar.gz"
14 DEPENDS="php-soap virtualbox"
16 # Rules to gen a SliTaz package suitable for Tazpkg.
17 genpkg_rules()
18 {
19 mkdir -p $fs/usr/share
20 mkdir -p $fs/etc
22 cp -a $src $fs/usr/share/phpvirtualbox
23 cp -a $fs/usr/share/phpvirtualbox/config.php-example \
24 $fs/etc/phpvirtualbox.php
25 dos2unix $fs/etc/phpvirtualbox.php
26 ln -s /etc/phpvirtualbox.php $fs/usr/share/phpvirtualbox/config.php
27 cp -a stuff/* $fs
28 }
30 post_install()
31 {
32 # Virtualbox OSE needs to disable authenication for vboxwebsrv
33 [ -d "$1/var/lib/tazpkg/installed/virtualbox" ] ||
34 chroot "$1/" VBoxManage setproperty websrvauthlibrary null
36 # Configure lighttpd server
37 if [ -f "$1/etc/lighttpd/lighttpd.conf" ]
38 then
39 if ! grep -q /usr/share/phpvirtualbox/ "$1/etc/lighttpd/lighttpd.conf"
40 then
41 sed -e 's|.*"/examples/" => "/usr/share/examples/",| "/examples/" => "/usr/share/examples/",\n "/phpvirtualbox/" => "/usr/share/phpvirtualbox/",|g' -i "$1/etc/lighttpd/lighttpd.conf"
42 if [ -z "$1" ]
43 then
44 # Start Web server.
45 /etc/init.d/lighttpd stop
46 /etc/init.d/lighttpd start
47 fi
48 fi
49 fi
51 # Configure apache server
52 if [ -f "$1/etc/apache/httpd.conf" ]
53 then
54 if [ ! -f "$1/etc/apache/conf.d/phpvirtualbox" ]
55 then
56 cat > "$1/etc/apache/conf.d/phpvirtualbox" <<EOT
57 <IfModule mod_alias.c>
58 Alias /phpvirtualbox /usr/share/phpvirtualbox
59 </IfModule>
60 <DirectoryMatch /usr/share/phpvirtualbox/>
61 DirectoryIndex index.php
62 Options +FollowSymLinks
63 AllowOverride None
64 Order allow,deny
65 Allow from all
66 </DirectoryMatch>
67 EOT
68 if [ -z "$1" ]
69 then
70 # Start Web server.
71 /etc/init.d/apache stop
72 /etc/init.d/apache start
73 fi
74 fi
75 fi
76 [ -z "$1" ] && /etc/init.d/vboxwebsrv start
77 cat <<EOT
78 Please configure /etc/phpvirtualbox.php now.
79 EOT
80 }
82 pre_remove()
83 {
84 /etc/init.d/vboxwebsrv stop
85 }