From: Arnout Vandecappelle <arnout@mind.be>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 1/5] support/download: fix the bzr helper
Date: Mon, 07 Jul 2014 07:54:56 +0200 [thread overview]
Message-ID: <53BA3630.9040305@mind.be> (raw)
In-Reply-To: <7397ced020b7a64534c6a240304998d2bf11c961.1404681878.git.yann.morin.1998@free.fr>
On 06/07/14 23:27, Yann E. MORIN wrote:
> bzr uses the name of the extension of the output file to known what
> output format to use: tar, tgz, tar.bz2... If no extension is
> recognised, bzr will output to a directory.
>
> Since we use 'mktemp .XXXXXX' to generate temporary files, it obviously
> never ends with a recognised extension. Thus, bzr expects the output to
> be a directory, and fails since it is a file.
I think it would be much simpler and more natural to use
tmp_dl="$( mktemp "${BUILD_DIR}/.XXXXXX.tar.gz" )"
tmp_output="$( mktemp "${output}.XXXXXX.tar.gz" )"
>
> Fix that by forcing the output format.
But of course, forcing it explicitly never hurts.
So even with my earlier comment, this one gets my
Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Regards,
Arnout
>
> Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
> ---
> support/download/bzr | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/support/download/bzr b/support/download/bzr
> index 3f52ee9..19d837d 100755
> --- a/support/download/bzr
> +++ b/support/download/bzr
> @@ -26,7 +26,7 @@ tmp_output="$( mktemp "${output}.XXXXXX" )"
> # - finally, we atomically rename to the final file
>
> ret=1
> -if ${BZR} export "${tmp_dl}" "${repo}" -r "${rev}"; then
> +if ${BZR} export --format=tgz "${tmp_dl}" "${repo}" -r "${rev}"; then
> if mv "${tmp_dl}" "${tmp_output}"; then
> mv "${tmp_output}" "${output}"
> ret=0
>
--
Arnout Vandecappelle arnout at mind be
Senior Embedded Software Architect +32-16-286500
Essensium/Mind http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint: 7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
next prev parent reply other threads:[~2014-07-07 5:54 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-06 21:27 [Buildroot] [PATCH 0/5] Cleanups in download helpers (branch yem/check-downloads) Yann E. MORIN
2014-07-06 21:27 ` [Buildroot] [PATCH 1/5] support/download: fix the bzr helper Yann E. MORIN
2014-07-07 5:54 ` Arnout Vandecappelle [this message]
2014-07-06 21:27 ` [Buildroot] [PATCH 2/5] support/download: properly use temp files Yann E. MORIN
2014-07-07 6:11 ` Arnout Vandecappelle
2014-07-07 21:38 ` Yann E. MORIN
2014-07-08 16:42 ` Arnout Vandecappelle
2014-07-08 21:52 ` Yann E. MORIN
2014-07-09 7:45 ` Thomas Petazzoni
2014-07-10 15:59 ` Yann E. MORIN
2014-07-06 21:27 ` [Buildroot] [PATCH 3/5] support/download: simplify the local-files helper Yann E. MORIN
2014-07-08 8:49 ` Peter Korsgaard
2014-07-06 21:27 ` [Buildroot] [PATCH 4/5] support/download: only create final temp file when needed Yann E. MORIN
2014-07-07 16:08 ` Arnout Vandecappelle
2014-07-07 21:53 ` Yann E. MORIN
2014-07-08 15:53 ` Arnout Vandecappelle
2014-07-06 21:27 ` [Buildroot] [PATCH 5/5] support/download: rationalise naming and use of the temporary files Yann E. MORIN
2014-07-06 21:40 ` Yann E. MORIN
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=53BA3630.9040305@mind.be \
--to=arnout@mind.be \
--cc=buildroot@busybox.net \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.