wok-next view zerobin/receipt @ rev 20555
Fix "DSO missing..." error: loqui, xfprint, notification-daemon-gtk2, xfmedia, evince, celestia(?)
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Fri Apr 06 17:43:57 2018 +0300 (2018-04-06) |
parents | da9e80c5d4bb |
children | d6378d455338 |
line source
1 # SliTaz package receipt v2.
3 PACKAGE="zerobin"
4 GITHASH="8cae64d6eab99fb0d31868df77846285c0958ed0" # 6 feb 2014
5 VERSION="${GITHASH:0:7}"
6 CATEGORY="network"
7 SHORT_DESC="Online pastebin where the server has zero knowledge of pasted data."
8 MAINTAINER="pascal.bellard@slitaz.org"
9 LICENSE="zlib/libpng"
10 WEB_SITE="http://sebsauvage.net/wiki/doku.php?id=php:zerobin"
12 TARBALL="$PACKAGE-$VERSION.tar.gz"
13 WGET_URL="https://github.com/sebsauvage/ZeroBin/archive/$VERSION.tar.gz"
15 compile_rules() {
16 patch -p0 < $stuff/zerobin.u
17 mkdir -p \
18 $install/usr/share/zerobin/ \
19 $install/var/lib/zerobin/data/ \
20 $install/var/lib/zerobin/tmp/
21 cp -a $src/* $install/usr/share/zerobin/
22 cp $stuff/purge.sh $install/var/lib/zerobin/data/
23 ln -s /var/lib/zerobin/data $install/usr/share/zerobin/data
24 ln -s /var/lib/zerobin/tmp $install/usr/share/zerobin/tmp
25 chown -R www.www $install/usr/share/zerobin $install/var/lib/zerobin/*
26 }
28 genpkg_rules() {
29 copy @std
30 DEPENDS="php"
31 SUGGESTED="php-gd"
32 }
34 post_install() {
35 # Configure lighttpd server
36 if [ -f "$1/etc/lighttpd/lighttpd.conf" ]; then
37 if ! grep -q /usr/share/zerobin/ "$1/etc/lighttpd/lighttpd.conf"; then
38 sed -e 's|.*"/examples/" => "/usr/share/examples/",| "/examples/" => "/usr/share/examples/",\n "/paste/" => "/usr/share/zerobin/",|g' -i "$1/etc/lighttpd/lighttpd.conf"
39 if [ -z "$1" ]; then
40 # Start Web server.
41 /etc/init.d/lighttpd stop
42 /etc/init.d/lighttpd start
43 fi
44 fi
45 fi
46 # Configure apache server
47 if [ -f "$1/etc/apache/httpd.conf" ]; then
48 sed -i 's/lighttpd/apache/' "$1/etc/rcS.conf"
49 if [ ! -f "$1/etc/apache/conf.d/zerobin" ]; then
50 cat > "$1/etc/apache/conf.d/zerobin" <<EOT
51 <IfModule mod_alias.c>
52 Alias /paste /usr/share/zerobin/
53 </IfModule>
54 <DirectoryMatch /usr/share/zerobin/>
55 php_value upload_max_filesize 2147483647
56 DirectoryIndex index.php
57 AllowOverride None
58 Order allow,deny
59 Allow from all
60 </DirectoryMatch>
61 EOT
62 if [ -z "$1" ]; then
63 # Start Web server.
64 /etc/init.d/apache restart
65 fi
66 fi
67 fi
68 }