From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] cached downloads for scm branches
Date: Thu, 20 Oct 2016 21:38:41 +0200 [thread overview]
Message-ID: <20161020213841.75105d07@free-electrons.com> (raw)
In-Reply-To: <f006d88783fb1d99aaef2d6cab1dfc88@walle.cc>
Hello,
On Thu, 20 Oct 2016 19:27:19 +0200, Michael Walle wrote:
> If I have a package which downloads it's source from a SCM branch, the
> download will be cached in DL_DIR/<pkgname>-<branchname>.tar.gz. This
> makes sense if the version is a tag or a (git) hash. But if used with
> branches, the package will never be downloaded again until I remove it
> from the DL_DIR. This may be the intended behaviour, but as far as I can
> tell, I have no chance to change it.
>
> Do I miss something? Does it make sense to add a new package variable to
> force a download?
This behavior is intended and adding a new package variable to force a
download is not what we want to do. Indeed, Buildroot aims at doing
*reproducible* builds. If a package points to a branch, then you have
no idea what you are building, this what you're building depends on the
moment you start the build (as it decides when you will fetch, and
therefore what you will fetch).
*However*, we have a mechanism called <pkg>_OVERRIDE_SRCDIR, which
allows you to tell Buildroot: "For this specific package, please skip
the download/extract/patch steps, and instead take the source from
<this> local directory". Thanks to that, you can checkout/clone your
project source code in <this> folder, and ask Buildroot to fetch it
from there. This is what we recommend during active development on a
given component.
See
http://free-electrons.com/doc/training/buildroot/buildroot-slides.pdf
slides 261 and following for more details.
Best regards,
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
next prev parent reply other threads:[~2016-10-20 19:38 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-20 17:27 [Buildroot] cached downloads for scm branches Michael Walle
2016-10-20 19:38 ` Thomas Petazzoni [this message]
2016-10-20 20:29 ` Michael Walle
2016-10-21 11:46 ` Jérôme Pouiller
2016-10-21 18:09 ` Arnout Vandecappelle
2016-10-20 19:45 ` 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=20161020213841.75105d07@free-electrons.com \
--to=thomas.petazzoni@free-electrons.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox