linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Michael Buesch <mb@bu3sch.de>
To: Andrew Morton <akpm@osdl.org>
Cc: paulus@au.ibm.com, linuxppc-dev@ozlabs.org
Subject: [PATCH v2] powerpc: Do not fail build if mkimage is not available
Date: Wed, 26 Dec 2007 16:55:56 +0100	[thread overview]
Message-ID: <200712261655.56432.mb@bu3sch.de> (raw)

This fixes the boot image wrapper script to not fail the kernel
build if mkimage is not available.
As some distributions don't ship the mkimage program and some people are not
interested in uboot images anyway, we don't want to fail the whole kernel
build process because of this unneeded dependency.

Simply drop an error message, but don't fail the build.

Signed-off-by: Michael Buesch <mb@bu3sch.de>

---

Josh Boyer is working on merging mkimage into the kernel tree.
Until that happened, please merge the patch below into the mainline kernel
to avoid build breakage for people without installed uboot tools.

Index: wireless-2.6/arch/powerpc/boot/wrapper
===================================================================
--- wireless-2.6.orig/arch/powerpc/boot/wrapper	2007-12-26 16:48:47.000000000 +0100
+++ wireless-2.6/arch/powerpc/boot/wrapper	2007-12-26 16:52:58.000000000 +0100
@@ -197,8 +197,11 @@ fi
 case "$platform" in
 uboot)
     rm -f "$ofile"
+    set +e
     mkimage -A ppc -O linux -T kernel -C gzip -a 00000000 -e 00000000 \
 	$uboot_version -d "$vmz" "$ofile"
+    [ $? -eq 0 ] || exit 0
+    set -e
     if [ -z "$cacheit" ]; then
 	rm -f "$vmz"
     fi
@@ -254,8 +257,11 @@ coff)
     ;;
 cuboot*)
     gzip -f -9 "$ofile"
+    set +e
     mkimage -A ppc -O linux -T kernel -C gzip -a "$base" -e "$entry" \
             $uboot_version -d "$ofile".gz "$ofile"
+    [ $? -eq 0 ] || exit 0
+    set -e
     ;;
 treeboot*)
     mv "$ofile" "$ofile.elf"

             reply	other threads:[~2007-12-26 15:57 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-26 15:55 Michael Buesch [this message]
2007-12-26 16:03 ` [PATCH v2] powerpc: Do not fail build if mkimage is not available Andreas Schwab
2007-12-26 16:08   ` Michael Buesch
2007-12-26 16:19     ` Andreas Schwab
2007-12-27 10:14     ` Wolfgang Denk
2007-12-27 10:17       ` Andreas Schwab
2007-12-27 18:13       ` Michael Buesch

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200712261655.56432.mb@bu3sch.de \
    --to=mb@bu3sch.de \
    --cc=akpm@osdl.org \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=paulus@au.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).