Package: kernel-package
Version: 11.001-0.1
Severity: wishlist
Tags: patch
The attached patch builds the lguest launcher when CONFIG_LGUEST is set
in the target kernel, and installs it to /lib/modules/{kernel-version}
in the linux-image package.This is an appropriate way to do this, as lguest is tied quite strongly to the version of the kernel it was built with (there's no defined ABI or API, so it pretty much has to launch a kernel from the same source as well, unless you're lucky), so there's no point in building a seperate lguest package for the launcher. However, this won't work when cross-building an i386 package (the only one where vanilla kernels can have CONFIG_LGUEST defined right now) because the lguest Makefile assumes that ld and gcc point to i386 versions. I'll be looking at sending a patch upstream to make it pay attention to the ARCH variable or something, details not decided as yet. CONFIG_LGUEST is disabled in default configs. -- System Information: Debian Release: lenny/sid APT prefers unstable APT policy: (500, 'unstable'), (1, 'experimental') Architecture: i386 (i686) Kernel: Linux 2.6.22-3-686 (SMP w/1 CPU core) Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash -- Paul "TBBle" Hampson, [EMAIL PROTECTED] Shorter .sig for a more eco-friendly paperless office.
diff -ru kernel-package-11.001/kernel/ruleset/targets/doc.mk kernel-package-11.001/kernel/ruleset/targets/doc.mk
--- kernel-package-11.001/kernel/ruleset/targets/doc.mk 2007-05-05 15:48:30.000000000 +1000
+++ kernel-package-11.001/kernel/ruleset/targets/doc.mk 2008-02-06 00:09:29.000000000 +1100
@@ -53,6 +53,7 @@
$(MAKE) mandocs htmldocs
endif
-tar cf - Documentation | (cd $(DOCDIR); umask 000; tar xsf -)
+ rm -f $(DOCDIR)/Documentation/lguest/lguest $(DOCDIR)/Documentation/lguest/lguest.lds
test ! -d $(DOCDIR)/Documentation/DocBook || \
rm -f $(DOCDIR)/Documentation/DocBook/Makefile \
$(DOCDIR)/Documentation/DocBook/*.sgml \
diff -ru kernel-package-11.001/kernel/ruleset/targets/image.mk kernel-package-11.001/kernel/ruleset/targets/image.mk
--- kernel-package-11.001/kernel/ruleset/targets/image.mk 2008-01-15 10:40:43.000000000 +1100
+++ kernel-package-11.001/kernel/ruleset/targets/image.mk 2008-02-06 00:08:42.000000000 +1100
@@ -114,6 +114,10 @@
ifneq ($(strip $(KERNEL_CROSS)),)
mv System.precious System.map
endif
+ ifneq ($(strip ($CONFIG_LGUEST)),)
+ $(install_file) Documentation/lguest/lguest $(TMPTOP)/lib/modules/$(version)/lguest
+ chmod 755 $(TMPTOP)/lib/modules/$(version)/lguest
+ endif
else
ifeq ($(DEB_HOST_ARCH_OS), kfreebsd)
mkdir -p $(INSTALL_MOD_PATH)/boot/defaults
@@ -342,6 +346,7 @@
dpkg --build $(TMPTOP) $(DEB_DEST)
ifeq ($(strip $(do_clean)),YES)
$(MAKE) $(EXTRAV_ARG) $(FLAV_ARG) $(CROSS_ARG) ARCH=$(KERNEL_ARCH) clean
+ $(MAKE) $(EXTRAV_ARG) $(FLAV_ARG) $(CROSS_ARG) ARCH=$(KERNEL_ARCH) -C Documentation/lguest clean
rm -f stamp-$(package)
endif
diff -ru kernel-package-11.001/kernel/ruleset/targets/target.mk kernel-package-11.001/kernel/ruleset/targets/target.mk
--- kernel-package-11.001/kernel/ruleset/targets/target.mk 2008-01-15 10:40:43.000000000 +1100
+++ kernel-package-11.001/kernel/ruleset/targets/target.mk 2008-02-06 00:09:14.000000000 +1100
@@ -135,6 +135,8 @@
+$(run_command) debian/dummy_do_dep
$(MAKE) $(EXTRAV_ARG) $(FLAV_ARG) $(CROSS_ARG) \
ARCH=$(KERNEL_ARCH) clean
+ $(MAKE) $(EXTRAV_ARG) $(FLAV_ARG) $(CROSS_ARG) \
+ ARCH=$(KERNEL_ARCH) -C Documentation/lguest clean
else
ifeq ($(strip $(MAKING_VIRTUAL_IMAGE)),)
$(MAKE) $(EXTRAV_ARG) $(FLAV_ARG) $(CROSS_ARG) ARCH=$(KERNEL_ARCH) prepare
@@ -256,6 +258,7 @@
mv -f scripts/package/Makefile.kpkg-dist scripts/package/Makefile
ifeq ($(DEB_HOST_ARCH_OS), linux)
test ! -f .config || cp -pf .config config.precious
+ $(MAKE) $(FLAV_ARG) $(EXTRAV_ARG) $(CROSS_ARG) ARCH=$(KERNEL_ARCH) -C Documentation/lguest clean
test ! -f Makefile || \
$(MAKE) $(FLAV_ARG) $(EXTRAV_ARG) $(CROSS_ARG) ARCH=$(KERNEL_ARCH) distclean
test ! -f config.precious || mv -f config.precious .config
@@ -317,6 +320,10 @@
$(MAKE) $(do_parallel) $(EXTRAV_ARG) $(FLAV_ARG) ARCH=$(KERNEL_ARCH) \
$(CROSS_ARG) modules
endif
+ ifneq ($(strip $(shell grep -E ^[^\#]*CONFIG_LGUEST $(CONFIG_FILE))),)
+ $(MAKE) $(do_parallel) $(EXTRAV_ARG) $(FLAV_ARG) ARCH=$(KERNEL_ARCH) \
+ $(CROSS_ARG) -C Documentation/lguest
+ endif
else
ifeq ($(DEB_HOST_ARCH_OS), kfreebsd)
$(PMAKE) -C $(architecture)/compile/GENERIC
pgpVoCoMMSA2y.pgp
Description: PGP signature

