[Pkg-jed-commit] r878 - jed/trunk/debian

Jörg Sommer jo-guest at alioth.debian.org
Sun Sep 9 15:52:03 UTC 2007


Author: jo-guest
Date: 2007-09-09 15:52:03 +0000 (Sun, 09 Sep 2007)
New Revision: 878

Added:
   jed/trunk/debian/jed-common.preinst
Modified:
   jed/trunk/debian/changelog
Log:
• trunk/debian/jed-common.preinst
  · We need a preinst for a proper upgrade with the help files in
    /usr/share/jed/doc.


Modified: jed/trunk/debian/changelog
===================================================================
--- jed/trunk/debian/changelog	2007-09-08 12:12:13 UTC (rev 877)
+++ jed/trunk/debian/changelog	2007-09-09 15:52:03 UTC (rev 878)
@@ -4,10 +4,16 @@
     + Policy 12.3 requires that programs stay working after removing of
       /usr/share/doc/. Due to this we can't move the internal help files
       to /usr/share/doc. Now, they are back in /usr/share/jed/doc and a
-      symlink is placed in /usr/share/doc/jed. [JS]
+      symlink is placed in /usr/share/doc/jed.
 
- -- Jörg Sommer <joerg at alea.gnuu.de>  Fri, 7 Sep 2007 21:25:04 +0200
+  * debian/jed-common.preinst:
+    + Added for a properly upgrade to the help files in /usr/share/jed/doc,
+      because policy 6.6 item 4 states that dpkg does not replace directories
+      by symlinks et vice versa. Due to this we must remove the old
+      directories and the symlink in the preinst script.
 
+ -- Jörg Sommer <joerg at alea.gnuu.de>  Sun, 9 Sep 2007 17:45:31 +0200
+
 jed (1:0.99.18+dfsg.1-8) unstable; urgency=low
 
   * debian/jed.menu, debian/xjed.menu:

Added: jed/trunk/debian/jed-common.preinst
===================================================================
--- jed/trunk/debian/jed-common.preinst	                        (rev 0)
+++ jed/trunk/debian/jed-common.preinst	2007-09-09 15:52:03 UTC (rev 878)
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+set -e
+
+case "$1" in
+  upgrade)
+    # Policy 6.6 item 4 tells that dpkg does not replace a directory in the old
+    # package by a symlink in the new package. We must remove the directory to
+    # make dpkg installs the symlink
+    for i in hlp txt; do
+        if [ -d /usr/share/doc/jed-common/$i ]; then
+            rm -r /usr/share/doc/jed-common/$i
+        fi
+    done
+
+    # The same problem with symlinks replaced by directories.
+    if [ -L /usr/share/jed/doc ]; then
+        rm /usr/share/jed/doc
+    fi
+    ;;
+  install|abort-upgrade) ;;
+esac
+
+#DEBHELPER#




More information about the Pkg-jed-commit mailing list