SVN: geninitrd/trunk/geninitrd

glen glen at pld-linux.org
Mon Aug 15 12:24:41 CEST 2011


Author: glen
Date: Mon Aug 15 12:24:41 2011
New Revision: 12325

Modified:
   geninitrd/trunk/geninitrd
Log:
ikconfig: try also /boot/config-$kernel before falling back to extraction from vmlinuz

Modified: geninitrd/trunk/geninitrd
==============================================================================
--- geninitrd/trunk/geninitrd	(original)
+++ geninitrd/trunk/geninitrd	Mon Aug 15 12:24:41 2011
@@ -286,10 +286,17 @@
 	local kofile=$(modinfo -k $kernel -n configs 2> /dev/null)
 	if [ -n "$kofile" ]; then
 		/lib/geninitrd/extract-ikconfig $kofile
-	else
-		# try vmlinuz itself
-		/lib/geninitrd/extract-ikconfig /boot/vmlinuz-$kernel
+		return
 	fi
+
+	# see if config available as separate file
+	if [ -f /boot/config-$kernel ]; then
+	   cat /boot/config-$kernel
+	   return
+   	fi
+
+	# finally try vmlinuz itself
+	/lib/geninitrd/extract-ikconfig /boot/vmlinuz-$kernel
 }
 
 # Finds module dependencies


More information about the pld-cvs-commit mailing list