From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18256 invoked by uid 1002); 1 Jun 2003 19:27:57 -0000 Mailing-List: contact gentoo-dev-help@gentoo.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@gentoo.org Received: (qmail 14086 invoked from network); 1 Jun 2003 19:27:57 -0000 From: Peter Ruskin Organization: Retired To: gentoo-dev@gentoo.org Date: Sun, 1 Jun 2003 20:27:54 +0100 User-Agent: KMail/1.5.2 References: <3ED931EC.2060303@cc.wwu.edu> In-Reply-To: <3ED931EC.2060303@cc.wwu.edu> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200306012027.54598.aoyu93@dsl.pipex.com> Subject: Re: [gentoo-dev] using more than one kernel X-Archives-Salt: e3d7ce95-06d9-4766-8ed5-de5892708d45 X-Archives-Hash: 6824fe4c802e3c7a1df025c4ed2cc1ce On Saturday 31 May 2003 23:51, Amiel Martin wrote: > Hi, Ive been playing with my kernel options and trying out a few > different kernels, and Ive got a few small ideas. > > first of all, there are a few packages that need to be re-emerged > when you compile a new kernel (ie nvidia-kernel and emu10k1) > > it would be nice to have a way to be able to run something like > emerge new-kernel > after compiling a new kernel. this could be done with an ebuilkd > variable that registers an ebuild as being dependant on the kernel? I like that idea. I currently use two build-kernel scripts that work around the nvidia-kernel, alsa, emu10k1 and lm_sensors thing: ============================================================ #!/bin/sh # /usr/local/bin/build-kernel # start this script from the kernel source directory, # for example /usr/src/linux-2.4.20-xfs-r2 # ...test for that... grep -q "Linux kernel" ./README if [ "$(echo $?)" != "0" ] ; then echo "ERROR: You don't appear to be in a kernel source directory" echo exit fi # This kernel variable produces something like "-2.4.20-xfs-r2" kernel=$(pwd | cut -dx -f2-9) make xconfig make dep clean [ "$(echo $?)" == "0" ] || echo "make dep clean failed" make bzImage [ "$(echo $?)" == "0" ] || echo "make bzImage failed" make modules [ "$(echo $?)" == "0" ] || echo "make modules failed" make modules_install [ "$(echo $?)" == "0" ] || echo "make modules_install failed" mount /boot [ "$(echo $?)" == "0" ] || echo "problem mounting /boot" cp arch/i386/boot/bzImage /boot/vmlinuz$kernel cp System.map /boot/System.map$kernel cp .config /boot/.config$kernel # if just rebuilding booted kernel... if [[ "-$(uname -r)" == "$kernel" ]] ; then AUTOCLEAN="no" ACCEPT_KEYWORDS="~x86" emerge lm_sensors nvidia-kernel else echo "Run build-kernel-2 after next reboot to" echo "update lm_sensors and nvidia-kernel." fi echo echo " All done. Now edit /boot/grub/grub.conf and reboot" ============================================================ #!/bin/sh # /usr/local/bin/build-kernel-2 # Run this after booting into a new kernel AUTOCLEAN="no" ACCEPT_KEYWORDS="~x86" emerge lm_sensors nvidia-kernel -- gentoo-dev@gentoo.org mailing list