From 5deda0893748753129b7f2f5ce97bae96b1adbfe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ozan=20=C3=87a=C4=9Flayan?= Date: Sat, 16 May 2009 23:16:20 +0000 Subject: [PATCH] Build the kernel with debug symbols if debugSymbols=True is given in actions.py. This will eliminate the necessarity of another kernel configuration patch for kernel-debug package. --- pisi/actionsapi/kerneltools.py | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/pisi/actionsapi/kerneltools.py b/pisi/actionsapi/kerneltools.py index a010e952..cb91e646 100644 --- a/pisi/actionsapi/kerneltools.py +++ b/pisi/actionsapi/kerneltools.py @@ -111,15 +111,13 @@ def __getExtraVersion(): # Configuration stuff # ####################### - def configure(): - # Set EXTRAVERSION - extraversion = __getExtraVersion() # I don't know what for but let's clean *.orig files shelltools.system("find . -name \"*.orig\" | xargs rm -f") - pisitools.dosed("Makefile", "EXTRAVERSION =.*", "EXTRAVERSION = %s" % extraversion) + # Set EXTRAVERSION + pisitools.dosed("Makefile", "EXTRAVERSION =.*", "EXTRAVERSION = %s" % __getExtraVersion()) # Configure the kernel configtype = os.getenv("KCONFIG") @@ -129,12 +127,16 @@ def configure(): autotools.make("oldconfig") -###################### -# Installation stuff # -###################### +################################## +# Building and nstallation stuff # +################################## -def build(): - autotools.make("CONFIG_DEBUG_SECTION_MISMATCH=y") +def build(debugSymbols=False): + extra_config = ["CONFIG_DEBUG_SECTION_MISMATCH=y"] + if debugSymbols: + extra_config.append("CONFIG_DEBUG_INFO=y") + + autotools.make("%s" " ".join(extra_config)) def install(): suffix = __getSuffix()