[Lunar-commits] r22449 - moonbase/trunk/kernel/linux-2.6-mm

Auke Kok sofar at lunar-linux.org
Mon Dec 4 20:00:23 CET 2006


Author: sofar
Date: 2006-12-04 20:00:23 +0100 (Mon, 04 Dec 2006)
New Revision: 22449

Modified:
   moonbase/trunk/kernel/linux-2.6-mm/BUILD
   moonbase/trunk/kernel/linux-2.6-mm/POST_INSTALL
   moonbase/trunk/kernel/linux-2.6-mm/PRE_BUILD
Log:
Updates to this - making it ready for my automatically updating linux-2.6-mm module changes coming up in a second.


Modified: moonbase/trunk/kernel/linux-2.6-mm/BUILD
===================================================================
--- moonbase/trunk/kernel/linux-2.6-mm/BUILD	2006-12-04 18:46:40 UTC (rev 22448)
+++ moonbase/trunk/kernel/linux-2.6-mm/BUILD	2006-12-04 19:00:23 UTC (rev 22449)
@@ -20,19 +20,19 @@
 done
 
 (
+
+    MYARCH="`arch | grep -qw i.86 && echo i386 || arch`"
     
     cp  /usr/src/linux/.config  $CONFIG_CACHE/.config-2.6-mm
-    rm -f arch/i386/boot/bzImage
+    rm -f arch/$MYARCH/boot/bzImage
     
-    
     make  ${MAKES:+-j$MAKES} bzImage      &&
     make  ${MAKES:+-j$MAKES} modules      &&
     backup_mods_krnl ${VERSION}    &&
     prepare_install                &&
     make  modules_install          &&
 
-    cp arch/i386/boot/bzImage /boot/${VERSION}		   && 
+    cp arch/$MYARCH/boot/bzImage /boot/${VERSION}		   && 
     cp System.map             /boot/System.map-${VERSION}  	
 
 ) > $C_FIFO 2>&1
-

Modified: moonbase/trunk/kernel/linux-2.6-mm/POST_INSTALL
===================================================================
--- moonbase/trunk/kernel/linux-2.6-mm/POST_INSTALL	2006-12-04 18:46:40 UTC (rev 22448)
+++ moonbase/trunk/kernel/linux-2.6-mm/POST_INSTALL	2006-12-04 19:00:23 UTC (rev 22449)
@@ -6,7 +6,5 @@
 #  Reinstall packages that add their own kernel modules
 lin -c kernel-reqs
 
-
-# create /sys
 mkdir -p /sys
 

Modified: moonbase/trunk/kernel/linux-2.6-mm/PRE_BUILD
===================================================================
--- moonbase/trunk/kernel/linux-2.6-mm/PRE_BUILD	2006-12-04 18:46:40 UTC (rev 22448)
+++ moonbase/trunk/kernel/linux-2.6-mm/PRE_BUILD	2006-12-04 19:00:23 UTC (rev 22449)
@@ -1,43 +1,23 @@
 cd /usr/src
 
-if [ ! -d /usr/src/linux-${VERSION} ]; then
-    
-    rm  -rf  linux-${KERNEL_VERSION} # we remove this one just in case
-    rm  -rf  linux-${VERSION}
-    rm  -rf  linux
-    
-    unpack  $SOURCE
-    
-    # the main kernel tarball unpacks with 2.6.X name, not with the -mm added
-    # so, e.g.: linux-2.6.X will be renamed as linux-2.6.X-mmY
-    
-    mv linux-${KERNEL_VERSION} linux-${VERSION}
-    
-    ln -sf linux-${VERSION}  linux
-    
-    chown root.root linux
-    
-    cd linux
-    
-    patch_it ${SOURCE2} 1 || exit 1
+if [ -d $SOURCE_DIRECTORY ]; then
+	message "Removing old -mm kernel source, conserving -mm .config"
+	cp $SOURCE_DIRECTORY/.config /etc/lunar/local/.config-2.6-mm
+	rm -rf $SOURCE_DIRECTORY
+fi
 
-    for config in .config-2.6-mm .config.2.6.stable
-    do	
-      if [ -f  $CONFIG_CACHE/${config} ]; then 
-         cp  $CONFIG_CACHE/${config}  /usr/src/linux/.config
-         message "Importing ${config} as kernel default configuration"
-      else	
-         break
-      fi
-    done
-    
-else
+validate_source_dir $SOURCE_DIRECTORY &&
+mk_source_dir $SOURCE_DIRECTORY &&
+ln -sf $SOURCE_DIRECTORY /usr/src/linux &&
+cd $SOURCE_DIRECTORY &&
+tar x --transform "s/linux-$KERNEL_VERSION\///" -f $SOURCE_CACHE/$SOURCE &&
+patch_it $SOURCE2 1 &&
+patch_it $SOURCE3 1 || exit 1
 
-    message "Sources found: /usr/src/linux-${VERSION}"
-    
-    if [ "`readlink linux`" != "linux-${VERSION}" ]; then
-       rm -rf linux	
-       ln -s linux-${VERSION} linux
-    fi
-
-fi
+for CONF in .config-2.6-mm .config.2.6.stable ; do	
+	if [ -f $CONFIG_CACHE/$CONF ]; then 
+		message "Importing $CONF as kernel default configuration"
+		cp $CONFIG_CACHE/$CONF /usr/src/linux/.config
+		break
+	fi
+done



More information about the Lunar-commits mailing list