[kernel] r15450 - in dists/sid/linux-2.6/debian: . templates/temp.headers.plain

Ben Hutchings benh at alioth.debian.org
Fri Mar 26 05:11:30 UTC 2010


Author: benh
Date: Fri Mar 26 05:11:27 2010
New Revision: 15450

Log:
linux-headers-*: Support postinst hooks in /etc/kernel/header_postinst.d

Thanks to Michael Gilbert. (Closes: #569724)

Added:
   dists/sid/linux-2.6/debian/templates/temp.headers.plain/
   dists/sid/linux-2.6/debian/templates/temp.headers.plain/postinst
Modified:
   dists/sid/linux-2.6/debian/changelog
   dists/sid/linux-2.6/debian/rules.real

Modified: dists/sid/linux-2.6/debian/changelog
==============================================================================
--- dists/sid/linux-2.6/debian/changelog	Thu Mar 25 09:55:50 2010	(r15449)
+++ dists/sid/linux-2.6/debian/changelog	Fri Mar 26 05:11:27 2010	(r15450)
@@ -11,6 +11,8 @@
     cause the system to hang (Closes: #559578)
   * eeepc-laptop: Disable wireless hotplug on 1005HA, 1201N and 1005PE
     since it disconnects the wrong device (Closes: #573607)
+  * linux-headers-*: Support postinst hooks in /etc/kernel/header_postinst.d,
+    thanks to Michael Gilbert (Closes: #569724)
 
   [ maximilian attems]
   * [alpha, hppa] Disable oprofile as tracing code is unsupported here.

Modified: dists/sid/linux-2.6/debian/rules.real
==============================================================================
--- dists/sid/linux-2.6/debian/rules.real	Thu Mar 25 09:55:50 2010	(r15449)
+++ dists/sid/linux-2.6/debian/rules.real	Fri Mar 26 05:11:27 2010	(r15450)
@@ -264,6 +264,12 @@
 	ln -s /usr/src/$(PACKAGE_NAME) $(PACKAGE_DIR)/lib/modules/$(REAL_VERSION)/build
 	ln -s /usr/src/$(PACKAGE_NAME_COMMON) $(PACKAGE_DIR)/lib/modules/$(REAL_VERSION)/source
 
+	install -d $(PACKAGE_DIR)/DEBIAN
+	sed -e 's/=V/$(REAL_VERSION)/g' \
+	  debian/templates/temp.headers.plain/postinst \
+	  > $(PACKAGE_DIR)/DEBIAN/postinst
+	chmod 755 $(PACKAGE_DIR)/DEBIAN/postinst
+
 	+$(MAKE_SELF) install-base
 
 install-libc-dev_$(ARCH): PACKAGE_NAME = linux-libc-dev

Added: dists/sid/linux-2.6/debian/templates/temp.headers.plain/postinst
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ dists/sid/linux-2.6/debian/templates/temp.headers.plain/postinst	Fri Mar 26 05:11:27 2010	(r15450)
@@ -0,0 +1,26 @@
+#!/usr/bin/perl
+# Author: Michael Gilbert <michael.s.gilbert at gmail.com>
+# Origin: Stripped down version of the linux-headers postinst from Ubuntu's
+#         2.6.32-14-generic kernel, which was itself derived from a
+#         Debian linux-image postinst script.
+
+$|=1;
+my $version  = "=V";
+
+if (-d "/etc/kernel/header_postinst.d") {
+  print STDERR "Examining /etc/kernel/header_postinst.d.\n";
+  system ("run-parts --verbose --exit-on-error --arg=$version " .
+          "/etc/kernel/header_postinst.d") &&
+            die "Failed to process /etc/kernel/header_postinst.d";
+}
+
+if (-d "/etc/kernel/header_postinst.d/$version") {
+  print STDERR "Examining /etc/kernel/header_postinst.d/$version.\n";
+  system ("run-parts --verbose --exit-on-error --arg=$version " .
+          "/etc/kernel/header_postinst.d/$version") &&
+            die "Failed to process /etc/kernel/header_postinst.d/$version";
+}
+
+exit 0;
+
+__END__



More information about the Kernel-svn-changes mailing list