[Glibc-bsd-commits] r4292 - trunk/libbsd/debian

Guillem Jover guillem at alioth.debian.org
Tue May 29 05:56:11 UTC 2012


Author: guillem
Date: 2012-05-29 05:56:11 +0000 (Tue, 29 May 2012)
New Revision: 4292

Added:
   trunk/libbsd/debian/libbsd-dev.postinst
Modified:
   trunk/libbsd/debian/changelog
Log:
Try to give back <nlist.h> to libelf-dev or libelfg0-dev on upgrade

Avoid leaving the system w/o an <nlist.h> previously owned by either
libelfg0-dev or libelf-dev when upgrading from old libsd-dev versions
which used to Replace them, by restoring <nlist.h> from <bsd/nlist.h>.



Modified: trunk/libbsd/debian/changelog
===================================================================
--- trunk/libbsd/debian/changelog	2012-05-29 05:38:19 UTC (rev 4291)
+++ trunk/libbsd/debian/changelog	2012-05-29 05:56:11 UTC (rev 4292)
@@ -10,6 +10,9 @@
     - Fix .so symlinks to be relative even when the .so.N shared library
       is on a different directory. (Closes: #580372)
     - Remove all deprecated headers and inclusions.
+  * Avoid leaving the system w/o an <nlist.h> previously owned by either
+    libelfg0-dev or libelf-dev when upgrading from old libsd-dev versions
+    which used to Replace them, by restoring <nlist.h> from <bsd/nlist.h>.
 
  -- Guillem Jover <guillem at debian.org>  Sun, 01 Apr 2012 18:47:18 +0200
 

Added: trunk/libbsd/debian/libbsd-dev.postinst
===================================================================
--- trunk/libbsd/debian/libbsd-dev.postinst	                        (rev 0)
+++ trunk/libbsd/debian/libbsd-dev.postinst	2012-05-29 05:56:11 UTC (rev 4292)
@@ -0,0 +1,23 @@
+#!/bin/sh -e
+
+pkg_installed()
+{
+  local pkg="$1"
+
+  dpkg-query -f '${Status}' -W $pkg 2>/dev/null | \
+    grep -qE '[^ ]* ok (unpacked|triggers-awaited|triggers-pending|installed)'
+}
+
+case "$1" in
+  configure)
+    # If either libelf-dev or libelfg0-dev is installed, then we took over
+    # nlist.h from them, restore a copy from the functional one.
+    if pkg_installed libelf-dev || pkg_installed libelfg0-dev; then
+      cp /usr/include/bsd/nlist.h /usr/include/nlist.h
+    fi
+    ;;
+esac
+
+#DEBHELPER#
+
+exit 0


Property changes on: trunk/libbsd/debian/libbsd-dev.postinst
___________________________________________________________________
Added: svn:executable
   + *




More information about the Glibc-bsd-commits mailing list