r2463 - trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian
Sven Luther
luther@costa.debian.org
Tue, 08 Feb 2005 21:08:16 +0100
Author: luther
Date: 2005-02-08 21:08:15 +0100 (Tue, 08 Feb 2005)
New Revision: 2463
Added:
trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/mkvmlinuz.postinst
trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/mkvmlinuz.templates
Modified:
trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/changelog
trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/rules
Log:
Added mkvmlinuz invoking /etc/kernel/postinst.d script to powerpc kernel 2.6.10.
Modified: trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/changelog
===================================================================
--- trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/changelog 2005-02-08 19:35:10 UTC (rev 2462)
+++ trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/changelog 2005-02-08 20:08:15 UTC (rev 2463)
@@ -1,3 +1,10 @@
+kernel-patch-powerpc-2.6.10 (2.6.10-2) UNRELEASED; urgency=high
+
+ * Added kernel postinst magic to be sure we do the right thing in the
+ mkvmlinuz case. (Sven Luther)
+
+ -- Sven Luther <luther@debian.org> Tue, 8 Feb 2005 21:05:01 +0100
+
kernel-patch-powerpc-2.6.10 (2.6.10-1) unstable; urgency=high
* New upstream release. (Sven Luther)
Added: trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/mkvmlinuz.postinst
===================================================================
--- trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/mkvmlinuz.postinst 2005-02-08 19:35:10 UTC (rev 2462)
+++ trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/mkvmlinuz.postinst 2005-02-08 20:08:15 UTC (rev 2463)
@@ -0,0 +1,49 @@
+#!/bin/sh
+
+set -e
+
+. /usr/share/debconf/confmodule
+
+case $(grep ^machine /proc/cpuinfo) in
+ *PReP*Blackhawk*) arch=ppcbug ;;
+ *PReP*) arch=prep ;;
+ "*CHRP Pegasos*") arch=chrp_pegasos ;;
+ *CHRP*) arch=chrp ;;
+ *Amiga*) arch=apus ;;
+ *iSeries*) arch=iseries ;;
+ *)
+ case $(grep ^pmac-generation /proc/cpuinfo) in
+ *NewWorld) arch=pmac_newworld ;;
+ *OldWorld) arch=pmac_oldworld ;;
+ *NuBus) arch=pmac_nubus ;;
+ *) arch=unknown ;;
+ esac
+ ;;
+esac
+
+# arches supported by yaboot :
+case $arch in
+ chrp|pmac_newworld) bootloaders="yaboot mkvmlinuz" ;;
+ pmac_oldworld) bootloaders="quik mkvmlinuz" ;;
+ chrp_pegasos) bootloaders="bogus mkvmlinuz" ;;
+ *) bootloaders="mkvmlinuz" ;;
+esac
+
+# If there is more than one bootloader present, ask the user
+# at medium priority
+
+db_subst kernel-image-powerpc/bootloaders choices "$bootloaders"
+db_subst kernel-image-powerpc/bootloaders default "${bootloaders%% *}"
+db_input medium kernel-image-powerpc/bootloaders || true
+db_go || true
+
+db_get kernel-image-powerpc/bootloaders
+bootloader="$RET"
+
+echo "User choosed $bootloader as bootloader"
+
+# If mkvmlinuz is chosen, we invoke it
+if [ "$bootloader" == "mkvmlinuz" ]; then
+ echo /usr/sbin/mkvmlinux $1 $2
+
+fi
Property changes on: trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/mkvmlinuz.postinst
___________________________________________________________________
Name: svn:executable
+ *
Added: trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/mkvmlinuz.templates
===================================================================
--- trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/mkvmlinuz.templates 2005-02-08 19:35:10 UTC (rev 2462)
+++ trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/mkvmlinuz.templates 2005-02-08 20:08:15 UTC (rev 2463)
@@ -0,0 +1,7 @@
+Template: kernel-image-powerpc/bootloaders
+Type: select
+Choices: ${choices}
+Default: ${default}
+Description: Select your bootloader
+ Your PowerPC arch supports more than one bootloader,
+ please chose the one you want to use.
Modified: trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/rules
===================================================================
--- trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/rules 2005-02-08 19:35:10 UTC (rev 2462)
+++ trunk/kernel/powerpc/kernel-patch-powerpc-2.6.10-2.6.10/debian/rules 2005-02-08 20:08:15 UTC (rev 2463)
@@ -224,6 +224,11 @@
cd $(KFLAVOUR); find scripts -type f ! -name '*.o' | cpio -pd $(KSRC)
cat debian/build-files | ( cd $(KFLAVOUR); cpio -pd $(KSRC) )
+# copy bootloader scripts to /etc/kernel/postinst.d and templates too.
+ $(INSTALL_EXEC) debian/mkvmlinuz.postinst \
+ $(KIMAGE)/etc/kernel/postinst.d/$(kernel)-$(flavour)/mkvmlinuz
+ $(INSTALL_DATA) debian/mkvmlinuz.templates $(KIMAGE)/DEBIAN/templates
+
# add a README file
mkdir -p $(KBUILDDOC)
$(INSTALL_DATA) debian/README.kernel-build $(KBUILDDOC)/README.Debian