[PATCH 2/2] Moved the ppc64 image size check.

David Shea dshea at redhat.com
Wed Oct 2 15:57:21 UTC 2013


This moves the ppc64.img size check to after the image has been
generated.
---
 scripts/mk-images.ppc | 31 +++++++++++++++----------------
 1 file changed, 15 insertions(+), 16 deletions(-)

diff --git a/scripts/mk-images.ppc b/scripts/mk-images.ppc
index b9e65e9..269d80e 100644
--- a/scripts/mk-images.ppc
+++ b/scripts/mk-images.ppc
@@ -31,21 +31,6 @@ makeBootImages() {
             --loaderbin loader \
             --modules "$INITRDMODS spufs viocd gpio_mdio"
 
-        if (( $(stat --format=%s $TOPDESTPATH/ppc/ppc64/$RAMDISK) > 32*1024*1024 )); then
-            echo "***"
-            echo "*** PPC64 $RAMDISK is larger than 32 MB, aborting"
-            echo "***"
-            echo "*** This file is generated by scripts/mk-images.ppc in anaconda, but the most"
-            echo "*** likely causes of this problem are:"
-            echo "***     kernel module set on ppc64 grew in size"
-            echo "***     dependent libraries or programs grew in size"
-            echo "***"
-            echo "*** Please contact the anaconda development team for help determining which"
-            echo "*** component in the distribution is at fault."
-            echo "***"
-            exit 1
-        fi
-
         cp $KERNELROOT/boot/vmlinuz-* $TOPDESTPATH/ppc/ppc64/vmlinuz
         sed -e "s/%BITS%/64/" -e "s/%PRODUCT%/$PRODUCT/" -e "s/%VERSION%/$VERSION/" \
             $BOOTDISKDIR/yaboot.conf.in > $TOPDESTPATH/ppc/ppc64/yaboot.conf
@@ -80,8 +65,22 @@ __EOT__
                 fi
         fi
 
-        echo >> $TOPDESTPATH/.treeinfo
+        if (( $(stat --format=%s $TOPDESTPATH/ppc/ppc64/$RAMDISK) > 32*1024*1024 )); then
+            echo "***"
+            echo "*** PPC64 $RAMDISK is larger than 32 MB, aborting"
+            echo "***"
+            echo "*** This file is generated by scripts/mk-images.ppc in anaconda, but the most"
+            echo "*** likely causes of this problem are:"
+            echo "***     kernel module set on ppc64 grew in size"
+            echo "***     dependent libraries or programs grew in size"
+            echo "***"
+            echo "*** Please contact the anaconda development team for help determining which"
+            echo "*** component in the distribution is at fault."
+            echo "***"
+            exit 1
+        fi
 
+        echo >> $TOPDESTPATH/.treeinfo
 
     elif [ "$KERNELARCH" = "ppc" ]; then
         FAKEARCH="ppc"
-- 
1.8.3.1



More information about the anaconda-patches mailing list