[pkg-horde] [SCM] Debian Horde Packages repository: kronolith2 package branch, debian-sid, updated. fecf4aef8727aebe30f923bfd9c1e4efe4d91c50

Mathieu Parent math.parent at gmail.com
Sun Dec 20 18:54:22 UTC 2009


The following commit has been merged in the debian-sid branch:
commit fecf4aef8727aebe30f923bfd9c1e4efe4d91c50
Author: Mathieu Parent <math.parent at gmail.com>
Date:   Sun Dec 20 19:53:49 2009 +0100

    Replace config symlink by update-alternatives
    
    to allow configuration packages

diff --git a/debian/changelog b/debian/changelog
index c0e4518..13313e5 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,6 +3,8 @@ kronolith2 (2.3.3+debian0-1) UNRELEASED; urgency=low
   * New upstream release. 
   * Added a check in debian/rules to make sure that external libs are not
     in the orig.tar.gz
+  * Replace config symlink by update-alternatives to allow configuration
+    packages
 
  -- Mathieu Parent <sathieu at debian.org>  Sun, 20 Dec 2009 19:23:06 +0100
 
diff --git a/debian/kronolith2.postinst b/debian/kronolith2.postinst
new file mode 100644
index 0000000..6a65b97
--- /dev/null
+++ b/debian/kronolith2.postinst
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+set -e
+
+case "$1" in
+    configure)
+        update-alternatives --install /usr/share/horde3/kronolith/config kronolith2-config /etc/horde/kronolith2 1
+    ;;
+
+    abort-upgrade|abort-remove|abort-deconfigure)
+    ;;
+
+    *)
+        echo "postinst called with unknown argument \`$1'" >&2
+        exit 1
+    ;;
+esac
+
+#DEBHELPER#
+
+exit 0
+
diff --git a/debian/kronolith2.prerm b/debian/kronolith2.prerm
new file mode 100644
index 0000000..2f8ec7b
--- /dev/null
+++ b/debian/kronolith2.prerm
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+set -e
+
+case "$1" in
+    remove)
+        update-alternatives --remove kronolith2-config /etc/horde/kronolith2
+    ;;
+
+    upgrade|deconfigure|failed-upgrade)
+    ;;
+
+    *)
+        echo "prerm called with unknown argument \`$1'" >&2
+        exit 1
+    ;;
+esac
+
+#DEBHELPER#
+
+exit 0
+
diff --git a/debian/rules b/debian/rules
index cdd2522..51ddb23 100755
--- a/debian/rules
+++ b/debian/rules
@@ -49,7 +49,8 @@ install: build
 	cp config/conf.xml debian/kronolith2/etc/horde/kronolith2/
 	touch debian/kronolith2/etc/horde/kronolith2/conf.php
 	#chown www-data:root debian/kronolith2/etc/horde/kronolith2/conf.php
-	dh_link etc/horde/kronolith2 usr/share/horde3/kronolith/config
+	#### kronolith expects configuration in config subdir, an update-alternatives
+	#### symlink is created in maintainer's scripts to comply with FHS
 
 	#### copy script to run by cron ####
 	mkdir debian/kronolith2/usr/share/horde3/kronolith/scripts

-- 
Debian Horde Packages repository: kronolith2 package



More information about the pkg-horde-hackers mailing list