From: Fathi Boudra Date: Thu, 4 Jan 2007 20:25:35 +0000 (+0000) Subject: * some cleanup and debian code beautification (tab/space/indentation) X-Git-Tag: v7.86~3703 X-Git-Url: https://code.citadel.org/?p=citadel.git;a=commitdiff_plain;h=736a9a525613ad7849515c5b5e03b4c1cc3cac0e * some cleanup and debian code beautification (tab/space/indentation) --- diff --git a/citadel/debian/changelog b/citadel/debian/changelog index 58abc2154..94c20288e 100644 --- a/citadel/debian/changelog +++ b/citadel/debian/changelog @@ -13,7 +13,7 @@ citadel (7.02-2) unstable; urgency=low * citadel-client.install: merged with citadel-client.examples * citadel-client.postinst: * clean up - * removed ucf mechanisms + * remove ucf mechanisms * add debhelper token * citadel-doc.install : merged with citadel-doc.docs * citadel-mta.postinst: @@ -22,22 +22,22 @@ citadel (7.02-2) unstable; urgency=low * citadel-server.dirs: * clean up * add var/lib/citadel/data and var/run/citadel dir - * moved messages and help to /etc/citadel + * move help and messages to /etc/citadel * citadel-server.install: merged with citadel-server.examples * citadel-server.postinst: * clean up * remove mkdir call as we create them with citadel-server.dirs - * remove loops as we don't use ucf here anymore. + * remove loops as we don't use ucf here anymore * add debhelper token * citadel-server.postrm: - * clean up; remove ucf + * clean up + * remove ucf * add debhelper token * citadel-server.prerm: * clean up * use invoke-rc.d * add debhelper token * citadel-server.templates: add po support - * compat: bumped to 5 * control: * priority set to extra instead optional * add myself in uploaders @@ -55,77 +55,68 @@ citadel (7.02-2) unstable; urgency=low -- Fathi Boudra Fri, 29 Dec 2006 16:24:48 +0100 citadel (7.02-1) unstable; urgency=low - + * update to actual Citadel SVN. many new features. see Packages changelog. -- Wilfried Goesgens Thu, 28 Dec 2006 22:10:00 +0100 - -citadel (7.01-2) stable; urgency=high - +citadel (7.01-1) stable; urgency=low + * we can now configure logintype on installation time. -- Wilfried Goesgens Thu, 21 Dec 2006 22:10:00 +0100 - citadel (7.00-1) unstable; urgency=low - + * update to actual Citadel CVS. many new features. see Packages changelog. -- Wilfried Goesgens Sat, 16 Dec 2006 01:01:00 +0100 - citadel (6.84-1) unstable; urgency=low - + * update to actual Citadel CVS. many new features. see Packages changelog. - -- Wilfried Goesgens Do, 31 Aug 2006 23:11:00 +0200 - + -- Wilfried Goesgens Thu, 31 Aug 2006 23:11:00 +0200 citadel (6.82-1) unstable; urgency=low - + * update to actual Citadel CVS. many new features. see Packages changelog. -- Wilfried Goesgens Thu, 22 Jun 2006 20:08:00 +0200 - citadel (6.71-1) unstable; urgency=low - + * update to actual Citadel CVS. many new features. see Packages changelog. -- Wilfried Goesgens Sat, 21 Jan 2006 19:07:00 +0100 - citadel (6.70-1) unstable; urgency=low - + * update to actual Citadel CVS. many new features. see Packages changelog. -- Wilfried Goesgens Sun, 15 Jan 2006 15:03:00 +0100 - citadel (6.63-1) unstable; urgency=low - + * update to actual Citadel CVS. many new features. see Packages changelog. -- Wilfried Goesgens Mon, 12 Dec 2005 11:11:00 +0100 - citadel (6.62-1) unstable; urgency=low - + * update to actual Citadel CVS. many new features. see Packages changelog. -- Wilfried Goesgens Fri, 18 Nov 2005 16:04:00 +0100 - citadel (6.61-2) unstable; urgency=low - + * update to actual Citadel CVS. many new features. see Packages changelog. -- Wilfried Goesgens Tue, 01 Nov 2005 12:23:15 +0200 - + citadel (6.53-1) unstable; urgency=low - * Initial release Closes: #nnnn (nnnn is the bug number of your ITP) + * Initial release -- Wilfried Goesgens Sat, 23 Jul 2005 12:23:15 +0200 diff --git a/citadel/debian/citadel-client.install b/citadel/debian/citadel-client.install index 5f24fcd0d..71fb3c08b 100644 --- a/citadel/debian/citadel-client.install +++ b/citadel/debian/citadel-client.install @@ -1,4 +1,4 @@ +etc/citadel/citadel.rc usr/bin/citadel -usr/bin/whobbs usr/bin/stress -etc/citadel/citadel.rc +usr/bin/whobbs diff --git a/citadel/debian/citadel-client.postinst b/citadel/debian/citadel-client.postinst index eeee37f7c..44ba62652 100644 --- a/citadel/debian/citadel-client.postinst +++ b/citadel/debian/citadel-client.postinst @@ -1,25 +1,33 @@ -#! /bin/sh -# Abort if any command returns an error value +#!/bin/sh +# postinst script for citadel-client + set -e case "$1" in - configure) - if ! getent group citadel >/dev/null; then - groupadd citadel - fi - if ! getent passwd citadel >/dev/null; then - adduser --system --ingroup citadel --home /var/lib/citadel \ - --gecos "Citadel system user" --shell /bin/sh \ - --disabled-password citadel - fi - mkdir -p /etc/citadel - chown citadel:citadel /etc/citadel/citadel.rc - ;; - abort-upgrade|abort-remove|abort-deconfigure) + configure) + if ! getent group citadel >/dev/null; then + groupadd citadel + fi + + if ! getent passwd citadel >/dev/null; then + adduser --system --ingroup citadel --home /var/lib/citadel \ + --gecos "Citadel system user" --shell /bin/sh \ + --disabled-password citadel + fi + + mkdir -p /etc/citadel + chown citadel:citadel /etc/citadel/citadel.rc + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 ;; - *) echo "$0: didn't understand being called with \`$1'" 1>&2 - exit 1;; esac #DEBHELPER# + exit 0 diff --git a/citadel/debian/citadel-mta.postinst b/citadel/debian/citadel-mta.postinst index 1191b5d56..84353c473 100644 --- a/citadel/debian/citadel-mta.postinst +++ b/citadel/debian/citadel-mta.postinst @@ -1,16 +1,23 @@ -#! /bin/sh +#!/bin/sh +# postinst script for citadel-mta + set -e case "$1" in - configure) - chown root:citadel /usr/sbin/sendmail - chmod 04755 /usr/sbin/sendmail - ;; - abort-upgrade|abort-remove|abort-deconfigure) + configure) + chown root:citadel /usr/sbin/sendmail + chmod 4755 /usr/sbin/sendmail + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 ;; - *) echo "$0: didn't understand being called with \`$1'" 1>&2 - exit 0;; esac #DEBHELPER# + exit 0 diff --git a/citadel/debian/citadel-server.config b/citadel/debian/citadel-server.config index ab1fa6207..15bf6b58b 100755 --- a/citadel/debian/citadel-server.config +++ b/citadel/debian/citadel-server.config @@ -1,18 +1,21 @@ #!/bin/sh + set -e +# source debconf stuff . /usr/share/debconf/confmodule db_version 2.0 if test -n "$2"; then - if test "`echo $2 | sed -e 's/[.-]//g'`" -lt 127 \ - -o $1 = reconfigure - then - db_input high citadel/ServerIPAddress - db_input high citadel/Administrator - db_input high citadel/LoginType - db_input high citadel/Installnote - db_go - fi + if test "`echo $2 | sed -e 's/[.-]//g'`" -lt 127 \ + -o $1 = reconfigure + then + db_input high citadel/ServerIPAddress + db_input high citadel/Administrator + db_input high citadel/LoginType + db_input high citadel/Installnote + db_go + fi fi + exit 0 diff --git a/citadel/debian/citadel-server.dirs b/citadel/debian/citadel-server.dirs index 14eb891f5..9cc6177c0 100644 --- a/citadel/debian/citadel-server.dirs +++ b/citadel/debian/citadel-server.dirs @@ -1,6 +1,5 @@ etc/citadel/help etc/citadel/messages -usr/share/doc/citadel-server var/lib/citadel/bio var/lib/citadel/bitbucket var/lib/citadel/data diff --git a/citadel/debian/citadel-server.install b/citadel/debian/citadel-server.install index de6960898..84438bf23 100644 --- a/citadel/debian/citadel-server.install +++ b/citadel/debian/citadel-server.install @@ -1,15 +1,14 @@ -usr/sbin/citserver +etc/citadel/mail.aliases +etc/citadel/public_clients +etc/citadel/help +etc/citadel/messages +usr/lib/citadel-server/setup usr/sbin/aidepost -usr/sbin/msgform -usr/sbin/citmail -usr/sbin/userlist -usr/sbin/sendcommand usr/sbin/base64 -usr/lib/citadel-server/setup usr/sbin/chkpwd -etc/citadel/mail.aliases -etc/citadel/public_clients -etc/citadel/messages/ -etc/citadel/help/ +usr/sbin/citmail +usr/sbin/citserver +usr/sbin/msgform +usr/sbin/sendcommand +usr/sbin/userlist usr/share/doc/citadel-server/database_cleanup.sh - diff --git a/citadel/debian/citadel-server.postinst b/citadel/debian/citadel-server.postinst index 1948720af..d01f2b88f 100644 --- a/citadel/debian/citadel-server.postinst +++ b/citadel/debian/citadel-server.postinst @@ -1,69 +1,74 @@ -#! /bin/sh -# citadel-server.postinst -# by Wilfried Goesgens & Fathi Boudra +#!/bin/sh +# postinst script for citadel-server set -e -# Use debconf. +# source debconf stuff . /usr/share/debconf/confmodule - db_version 2.0 case "$1" in - configure) - if ! getent group citadel >/dev/null; then - groupadd citadel - fi - if ! getent passwd citadel >/dev/null; then - adduser --system --ingroup citadel --home /var/lib/citadel \ - --gecos "Citadel system user" --shell /bin/sh \ - --disabled-password citadel - fi - chown -R citadel:citadel /etc/citadel - chown -R citadel:citadel /var/lib/citadel /var/spool/citadel - -# we're a bit paranoid here, because of this gave us many errors in the past. - chown root:root /usr/sbin/chkpwd + configure) + if ! getent group citadel >/dev/null; then + groupadd citadel + fi + + if ! getent passwd citadel >/dev/null; then + adduser --system --ingroup citadel --home /var/lib/citadel \ + --gecos "Citadel system user" --shell /bin/sh \ + --disabled-password citadel + fi + + chown -R citadel:citadel /etc/citadel + chown -R citadel:citadel /var/lib/citadel /var/spool/citadel + + # we're a bit paranoid here, + # because of this gave us many errors in the past. + chown root:root /usr/sbin/chkpwd chmod 4755 /usr/sbin/chkpwd - db_get citadel/Administrator && admin="$RET" - db_get citadel/ServerIPAddress && ip_addr="$RET" - db_get citadel/LoginType && enable_unix_auth="$RET" - if test "$enable_unix_auth" = "true"; then - export ENABLE_UNIX_AUTH=yes - else - export ENABLE_UNIX_AUTH=no - fi - export IP_ADDR=$ip_addr - export CITADEL='' - export CITADEL_INSTALLER=yes - export ACT_AS_MTA=no - export SYSADMIN_NAME=$admin - export CREATE_XINETD_ENTRY=no - export CREATE_INITTAB_ENTRY=no - export NO_INIT_SCRIPTS=yes - - echo "applying your settings." - /usr/lib/citadel-server/setup -q - - if test -S /var/run/citadel/citadel.socket; then - /usr/sbin/sendcommand "DOWN" - fi - - while test -S /var/run/citadel/citadel.socket; do - sleep 1 - done - - db_stop - - ;; - abort-upgrade|abort-remove|abort-deconfigure) + db_get citadel/Administrator && admin="$RET" + db_get citadel/ServerIPAddress && ip_addr="$RET" + db_get citadel/LoginType && enable_unix_auth="$RET" + + if test "$enable_unix_auth" = "true"; then + export ENABLE_UNIX_AUTH=yes + else + export ENABLE_UNIX_AUTH=no + fi + + export IP_ADDR=$ip_addr + export CITADEL='' + export CITADEL_INSTALLER=yes + export ACT_AS_MTA=no + export SYSADMIN_NAME=$admin + export CREATE_XINETD_ENTRY=no + export CREATE_INITTAB_ENTRY=no + export NO_INIT_SCRIPTS=yes + + echo "applying your settings." + /usr/lib/citadel-server/setup -q + + if test -S /var/run/citadel/citadel.socket; then + /usr/sbin/sendcommand "DOWN" + fi + + while test -S /var/run/citadel/citadel.socket; do + sleep 1 + done + + db_stop ;; - *) echo "$0: didn't understand being called with \`$1'" 1>&2 - exit 1;; + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; esac - #DEBHELPER# +#DEBHELPER# exit 0 diff --git a/citadel/debian/citadel-server.postrm b/citadel/debian/citadel-server.postrm index 7e196ceff..24663be6f 100644 --- a/citadel/debian/citadel-server.postrm +++ b/citadel/debian/citadel-server.postrm @@ -1,20 +1,29 @@ -#! /bin/sh +#!/bin/sh +# postrm script for citadel-server + set -e + +# source debconf stuff . /usr/share/debconf/confmodule db_version 2.0 case "$1" in - remove) + purge) + echo "/var/lib/citadel/data not removed, as it may contain your personal data." + + db_purge + db_go ;; - purge) - echo "/var/lib/citadel/data not removed, as it may contain your personal data." - db_purge - db_go - ;; - disappear|upgrade|failed-upgrade|abort-install|abort-upgrade) + + remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + ;; + + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 ;; - *) echo "$0: didn't understand being called with \`$1'" 1>&2 - exit 1;; esac +#DEBHELPER# + exit 0 diff --git a/citadel/debian/citadel.init b/citadel/debian/citadel.init index 40610d8f6..08f183a3e 100644 --- a/citadel/debian/citadel.init +++ b/citadel/debian/citadel.init @@ -1,6 +1,6 @@ #!/bin/sh ### BEGIN INIT INFO -# Provides: citadel-server +# Provides: citadel # Required-Start: $local_fs $remote_fs # Required-Stop: $local_fs $remote_fs # Default-Start: 2 3 4 5 @@ -10,6 +10,7 @@ ### END INIT INFO # Author: Wilfried Goesgens + RUNDIR=/var/run/citadel PATH=/sbin:/usr/sbin:/bin:/usr/bin DESC="Citadel Groupware " @@ -20,14 +21,12 @@ PIDFILE=$RUNDIR/$NAME.pid SCRIPTNAME=/etc/init.d/citadel SENDCOMMAND=/usr/sbin/sendcommand - # Exit if the package is not installed [ -x "$DAEMON" ] || exit 0 # Read configuration variable file if it is present [ -r /etc/default/$NAME ] && . /etc/default/$NAME -# check if we 've got a newer system, so we can do fancy colors and so on. MODERN= # Load the VERBOSE setting and other rcS variables @@ -85,7 +84,6 @@ do_stop() rm -f $PIDFILE return 2 fi - } # @@ -156,9 +154,9 @@ case "$1" in fi ;; *) - echo "Usage: $SCRIPTNAME {start|stop|restart}" >&2 + echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2 exit 3 ;; esac -exit 0 \ No newline at end of file +exit 0 diff --git a/citadel/debian/control b/citadel/debian/control index dde77c56c..cbbfaa6d5 100644 --- a/citadel/debian/control +++ b/citadel/debian/control @@ -3,10 +3,10 @@ Section: mail Priority: extra Maintainer: Wilfried Goesgens Uploaders: Fathi Boudra -Build-Depends: debhelper (>= 4.0.0), po-debconf, bison, autotools-dev, - libdb4.4-dev | libdb4.3-dev, libical-dev, libssl-dev, - libncurses5-dev, libldap2-dev, libpam0g-dev, libsieve2-dev -Standards-Version: 3.7.2.2 +Build-Depends: debhelper (>= 4), po-debconf, bison, autotools-dev, + libdb4.4-dev | libdb4.3-dev, libical-dev, libldap2-dev, libncurses5-dev, + libpam0g-dev, libsieve2-dev, libssl-dev +Standards-Version: 3.7.2 Package: citadel-server Architecture: any @@ -100,7 +100,6 @@ Description: complete and feature-rich groupware server (command line client) . Homepage: http://www.citadel.org - Package: citadel-doc Section: doc Architecture: all diff --git a/citadel/debian/rules b/citadel/debian/rules index 9e31aa107..48711d653 100755 --- a/citadel/debian/rules +++ b/citadel/debian/rules @@ -1,11 +1,13 @@ #!/usr/bin/make -f -# -*- makefile -*- + # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 # This has to be exported to make some magic below work. export DH_OPTIONS + DEB_DESTDIR = $(CURDIR)/debian/tmp + CFLAGS = -Wall -g ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) @@ -17,8 +19,8 @@ endif configure: configure-stamp configure-stamp: dh_testdir + CFLAGS="$(CFLAGS)" ./configure \ - --prefix=/usr/sbin \ --with-datadir=/var/lib/citadel \ --with-spooldir=/var/spool/citadel \ --with-sysconfdir=/etc/citadel \ @@ -44,12 +46,14 @@ build-arch-stamp: configure-stamp build-indep: build-indep-stamp build-indep-stamp: configure-stamp + touch $@ clean: dh_testdir dh_testroot rm -f build-arch-stamp build-indep-stamp #CONFIGURE-STAMP# + -$(MAKE) distclean dh_clean @@ -60,7 +64,9 @@ install-indep: dh_testroot dh_clean -k -i dh_installdirs -i + $(MAKE) DESTDIR=$(DEB_DESTDIR) install-doc-new + dh_install -i --sourcedir=debian/tmp install-arch: @@ -68,10 +74,13 @@ install-arch: dh_testroot dh_clean -k -s dh_installdirs -s + $(MAKE) DESTDIR=$(DEB_DESTDIR) install-exec-new install-data-new + mkdir -p $(DEB_DESTDIR)/usr/lib/citadel-server mv $(DEB_DESTDIR)/usr/sbin/setup \ $(DEB_DESTDIR)/usr/lib/citadel-server/ + mkdir -p $(DEB_DESTDIR)/usr/share/doc/citadel-server/ mv $(DEB_DESTDIR)/usr/share/doc/citadel-doc/database_cleanup.sh \ $(DEB_DESTDIR)/usr/share/doc/citadel-server/