updated debian/ to etch policy
This commit is contained in:
parent
3381db5837
commit
11ff5a1836
|
@ -2,12 +2,13 @@ Source: wcs
|
|||
Section: web
|
||||
Priority: optional
|
||||
Maintainer: Frederic Peters <fpeters@debian.org>
|
||||
Build-Depends: debhelper (>> 4.0.0)
|
||||
Standards-Version: 3.6.5.0
|
||||
Build-Depends: python-support (>= 0.4), debhelper (>= 5.0.37.2), gettext
|
||||
Standards-Version: 3.6.7.0
|
||||
|
||||
Package: wcs
|
||||
Architecture: all
|
||||
Depends: python2.3, quixote (>= 2.0), libapache2-mod-scgi | libapache-mod-scgi, python2.3-scgi, python2.3-libxml2
|
||||
Depends: ${python:Depends}, python-quixote, libapache2-mod-scgi | libapache-mod-scgi, python-scgi, python-libxml2
|
||||
Description: w.c.s. (1st draft)
|
||||
.
|
||||
XB-Python-Version: ${python:Versions}
|
||||
|
||||
|
|
|
@ -1,54 +0,0 @@
|
|||
#! /bin/sh
|
||||
# postinst script for wcs
|
||||
#
|
||||
# see: dh_installdeb(1)
|
||||
|
||||
set -e
|
||||
|
||||
# summary of how this script can be called:
|
||||
# * <postinst> `configure' <most-recently-configured-version>
|
||||
# * <old-postinst> `abort-upgrade' <new version>
|
||||
# * <conflictor's-postinst> `abort-remove' `in-favour' <package>
|
||||
# <new-version>
|
||||
# * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
|
||||
# <failed-install-package> <version> `removing'
|
||||
# <conflicting-package> <version>
|
||||
# for details, see http://www.debian.org/doc/debian-policy/ or
|
||||
# the debian-policy package
|
||||
#
|
||||
# quoting from the policy:
|
||||
# Any necessary prompting should almost always be confined to the
|
||||
# post-installation script, and should be protected with a conditional
|
||||
# so that unnecessary prompting doesn't happen if a package's
|
||||
# installation fails and the `postinst' is called with `abort-upgrade',
|
||||
# `abort-remove' or `abort-deconfigure'.
|
||||
|
||||
PACKAGE=wcs
|
||||
VERSION=2.3
|
||||
LIB="/usr/lib/python$VERSION"
|
||||
DIRLIST="$LIB/site-packages/wcs"
|
||||
|
||||
case "$1" in
|
||||
configure|abort-upgrade|abort-remove|abort-deconfigure)
|
||||
for i in $DIRLIST ; do
|
||||
/usr/bin/python$VERSION -O $LIB/compileall.py -q $i
|
||||
/usr/bin/python$VERSION $LIB/compileall.py -q $i
|
||||
done
|
||||
;;
|
||||
|
||||
*)
|
||||
echo "postinst called with unknown argument \`$1'" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
|
||||
|
||||
# dh_installdeb will replace this with shell code automatically
|
||||
# generated by other debhelper scripts.
|
||||
|
||||
#DEBHELPER#
|
||||
|
||||
exit 0
|
||||
|
||||
|
|
@ -1,43 +0,0 @@
|
|||
#! /bin/sh
|
||||
# prerm script for wcs
|
||||
#
|
||||
# see: dh_installdeb(1)
|
||||
|
||||
set -e
|
||||
|
||||
# summary of how this script can be called:
|
||||
# * <prerm> `remove'
|
||||
# * <old-prerm> `upgrade' <new-version>
|
||||
# * <new-prerm> `failed-upgrade' <old-version>
|
||||
# * <conflictor's-prerm> `remove' `in-favour' <package> <new-version>
|
||||
# * <deconfigured's-prerm> `deconfigure' `in-favour'
|
||||
# <package-being-installed> <version> `removing'
|
||||
# <conflicting-package> <version>
|
||||
# for details, see http://www.debian.org/doc/debian-policy/ or
|
||||
# the debian-policy package
|
||||
|
||||
|
||||
PACKAGE=wcs
|
||||
|
||||
case "$1" in
|
||||
remove|upgrade|deconfigure)
|
||||
dpkg --listfiles $PACKAGE |
|
||||
awk '$0~/\.py$/ {print $0"c\n" $0"o"}' |
|
||||
xargs rm -f >&2
|
||||
;;
|
||||
failed-upgrade)
|
||||
;;
|
||||
*)
|
||||
echo "prerm called with unknown argument \`$1'" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
# dh_installdeb will replace this with shell code automatically
|
||||
# generated by other debhelper scripts.
|
||||
|
||||
#DEBHELPER#
|
||||
|
||||
exit 0
|
||||
|
||||
|
|
@ -4,18 +4,7 @@
|
|||
# Uncomment this to turn on verbose mode.
|
||||
#export DH_VERBOSE=1
|
||||
|
||||
# This is the debhelper compatibility version to use.
|
||||
export DH_COMPAT=3
|
||||
|
||||
|
||||
PYTHON=/usr/bin/python2.3
|
||||
|
||||
ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
|
||||
CFLAGS += -g
|
||||
endif
|
||||
ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
|
||||
INSTALL_PROGRAM += -s
|
||||
endif
|
||||
PYTHON=/usr/bin/python
|
||||
|
||||
build: build-stamp
|
||||
|
||||
|
@ -28,6 +17,11 @@ clean:
|
|||
dh_testroot
|
||||
rm -f build-stamp
|
||||
|
||||
cd doc && make clean
|
||||
cd po && rm -f *.mo
|
||||
python setup.py clean
|
||||
rm -rf build
|
||||
|
||||
dh_clean
|
||||
|
||||
install: build
|
||||
|
@ -37,8 +31,9 @@ install: build
|
|||
dh_installdirs
|
||||
|
||||
$(PYTHON) setup.py install --prefix=$(CURDIR)/debian/wcs/usr --no-compile
|
||||
mv $(CURDIR)/debian/wcs/usr/bin/* $(CURDIR)/debian/wcs/usr/sbin/
|
||||
rmdir $(CURDIR)/debian/wcs/usr/bin
|
||||
mv $(CURDIR)/debian/wcs/usr/bin/wcsctl.py \
|
||||
$(CURDIR)/debian/wcs/usr/sbin/wcsctl
|
||||
rmdir $(CURDIR)/debian/wcs/usr/bin/
|
||||
cd po && make install prefix=$(CURDIR)/debian/wcs/
|
||||
cp debian/vhost-apache-wcs $(CURDIR)/debian/wcs/etc/apache2/sites-available
|
||||
chown www-data.www-data $(CURDIR)/debian/wcs/var/lib/wcs/
|
||||
|
@ -52,12 +47,14 @@ binary-indep: build install
|
|||
binary-arch: build install
|
||||
dh_testdir
|
||||
dh_testroot
|
||||
dh_installdocs
|
||||
dh_installinit
|
||||
dh_installcron
|
||||
dh_installdocs
|
||||
dh_installchangelogs
|
||||
dh_installinit
|
||||
dh_link
|
||||
dh_strip
|
||||
dh_fixperms -X /var/lib/wcs
|
||||
dh_pysupport
|
||||
dh_installdeb
|
||||
dh_gencontrol
|
||||
dh_md5sums
|
||||
|
|
|
@ -6,5 +6,5 @@ then
|
|||
. /etc/default/$NAME
|
||||
fi
|
||||
|
||||
/usr/sbin/wcsctl.py clean_sessions
|
||||
/usr/sbin/wcsctl clean_sessions
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
|
||||
DESC="wcs"
|
||||
NAME=wcs
|
||||
DAEMON=/usr/sbin/wcsctl.py
|
||||
DAEMON=/usr/sbin/wcsctl
|
||||
PIDFILE=/var/run/$NAME.pid
|
||||
SCRIPTNAME=/etc/init.d/$NAME
|
||||
|
||||
|
|
Loading…
Reference in New Issue