linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: David Woodhouse <dwmw2@infradead.org>
To: linuxppc-dev@ozlabs.org
Subject: [PPC BOOT] Create otheros.bld next to specified output file, not in $object directory.
Date: Mon, 03 Dec 2007 02:48:03 +0000	[thread overview]
Message-ID: <1196650083.13978.113.camel@pmac.infradead.org> (raw)

The bootwrapper script currently generates an 'otheros.bld' file in
addition to the file specified by the -o option, when asked to build a
wrapper for PS3.

It should do that in the same directory as the output, not the directory
where the wrapper objects are kept (which might potentially not be
writable when the script runs).

Arguably, the 'otheros.bld' ought to be created with the filename
specified as the -o argument. But that's a more intrusive change.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>

--- a/arch/powerpc/boot/wrapper
+++ b/arch/powerpc/boot/wrapper
@@ -287,8 +289,6 @@ ps3)
     overlay_dest="256"
     overlay_size="256"
 
-    rm -f "$object/otheros.bld"
-
     ${CROSS}objcopy -O binary "$ofile" "$ofile.bin"
 
     dd if="$ofile.bin" of="$ofile.bin" conv=notrunc   \
@@ -299,6 +299,8 @@ ps3)
         skip=$system_reset_overlay seek=$overlay_dest \
         count=$overlay_size bs=1
 
-    gzip --force -9 --stdout "$ofile.bin" > "$object/otheros.bld"
+    odir="$(dirname "$ofile.bin")"
+    rm -f "$odir/otheros.bld"
+    gzip --force -9 --stdout "$ofile.bin" > "$odir/otheros.bld"
     ;;
 esac

-- 
dwmw2

             reply	other threads:[~2007-12-03  2:48 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-03  2:48 David Woodhouse [this message]
2007-12-03  2:49 ` [PPC BOOT] Find device-tree source file in default directory David Woodhouse
2007-12-03  2:52   ` [PPC BOOT] Allow for bootwrapper utilities being in different directory to objects David Woodhouse
2007-12-03  2:56     ` [PPC BOOT] 'make bootwrapper_install' David Woodhouse
2007-12-03 15:08   ` [PPC BOOT] Find device-tree source file in default directory Scott Wood
2007-12-03 15:13     ` David Woodhouse
2007-12-03  3:33 ` [PPC BOOT] Create otheros.bld next to specified output file, not in $object directory Geoff Levand

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=1196650083.13978.113.camel@pmac.infradead.org \
    --to=dwmw2@infradead.org \
    --cc=linuxppc-dev@ozlabs.org \
    /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).