wok-next view c_icap/receipt @ rev 20342
gkII: tiny png patch
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Fri Nov 17 15:57:17 2017 +0100 (2017-11-17) |
parents | 8f50006d2661 |
children | 4c1ed6983d05 |
line source
1 # SliTaz package receipt v2.
3 PACKAGE="c_icap"
4 VERSION="0.1.7"
5 CATEGORY="network"
6 SHORT_DESC="Implementation of an ICAP server"
7 MAINTAINER="erjo@slitaz.org"
8 LICENSE="LGPL2.1"
9 WEB_SITE="http://c-icap.sourceforge.net/"
11 TARBALL="$PACKAGE-$VERSION.tar.gz"
12 WGET_URL="$SF_MIRROR/c-icap/$TARBALL"
14 BUILD_DEPENDS="zlib-dev"
15 SPLIT="c_icap-dev"
17 # Rules to configure and make the package.
18 compile_rules()
19 {
20 ./configure \
21 --sysconfdir=/etc/c-icap \
22 --enable-large-files \
23 $CONFIGURE_ARGS &&
24 make && make install &&
26 mkdir -p $install/etc/init.d/ $install/var/log/c-icap/ &&
27 install -m755 $stuff/c-icapd $install/etc/init.d &&
29 # Fix config file
30 sed -i -e "s|YourServerName|localhost|;
31 s|/usr/var/log|/var/log/c-icap/|;
32 s|/usr/var/run/|/var/run/c-icap|;
33 s|/usr/etc|/etc/c-icap|" $install/etc/c-icap/c-icap.conf &&
34 chmod -x $install/etc/c-icap/*
35 }
37 # Rules to gen a SliTaz package suitable for Tazpkg.
38 genpkg_rules()
39 {
40 case $PACKAGE in
41 c_icap)
42 copy @std var/log/c-icap/
43 ;;
44 *-dev)
45 copy @dev
46 ;;
47 esac
48 }
50 post_install_c_icap() {
51 [ -z "$1" -a ! -s /aufs-umount.sh ] && /etc/init.d/c-icapd start
53 [ -n "$quiet" ] || cat <<EOF
55 ----
56 To start $PACKAGE server you can run :
58 /etc/init.d/$PACKAGE start
60 Or add $PACKAGE to RUN_DAEMONS in /etc/rcS.conf
61 ----
62 EOF
63 }
65 pre_remove_c_icap() {
66 echo "Stopping daemon..."
67 if (ps | grep -q c-icap); then
68 chroot "$1/" /etc/init.d/c-icapd stop
69 fi
70 }
71 post_remove_c_icap() {
72 echo "Removing stalled files..."
73 [ -d "$1/var/log/c-icap" ] && rm -rf "$1/var/log/c-icap"
74 [ -d "$1/usr/run/c-icap" ] && rm -rf "$1/usr/run/c-icap"
75 }