Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH RFC] Revert "Added local directory as source of kernel code"
Date: Mon, 12 Dec 2016 17:27:15 +0100	[thread overview]
Message-ID: <20161212172715.4a8ab39f@free-electrons.com> (raw)
In-Reply-To: <CALAjcgVnSzgNmmue22YdgSyd1b2-ZywEZZYmJm+U04HF4_DwVQ@mail.gmail.com>

Hello,

On Sun, 11 Dec 2016 22:06:44 -0500, James Knight wrote:

> > But nothing prevents people from having a version-controlled local.mk,
> > which makes it not-local anymore.  
> 
> This.
> 
> (sorry for the delay. was trying trying to upgrade from a
> 2015.11.x-based series to a 2016.11.x-based series and just found out
> that BR2_LINUX_KERNEL_CUSTOM_LOCAL_PATH is gone; original comments
> here [1], if your email is past retention)
> 
> For my build environment, I prepare a series of sources before
> invoking a Buildroot make. This includes preparing BR2_EXTERNAL
> modules, cache content (dl) and my target kernel sources. The
> initialization phase allows me to adjust source locations for a
> specific build, for example, targeting a local Git repository for
> kernel sources instead of a specific tarball. I was able to easily
> achieve this by defining a custom local path in my Buildroot
> configuration as follows:
> 
>     BR2_LINUX_KERNEL_CUSTOM_LOCAL=y
>     BR2_LINUX_KERNEL_CUSTOM_LOCAL_PATH="$(MYCUSTOM_LINUX_DIR)"
> 
> With the revert of this patch, it seems the best "correct" approach is
> to use the override-srcdir mechanism. As Thomas mentions though,
> modifying my `local.mk` file to be under version control makes it no
> longer local anymore. While I would love to have the feature back, if
> this is a rare/odd usage, I don't mind modifying my repository to
> support custom kernel local paths (rather than customizing a local.mk
> file). Thoughts?
> 
> I don't believe BR2_LINUX_KERNEL_CUSTOM_LOCAL_PATH hurts
> reproducibility in all cases. If a build environment ensures the
> kernel custom path's content is managed properly for a build invoke,
> would there be a reproducibility issue (unless I'm overlooking
> something)?

I don't really feel very strongly about this.

However, what was odd with BR2_LINUX_KERNEL_CUSTOM_LOCAL_PATH is that
we were providing this for the Linux kernel package, but not for any
other package. I think the reason we removed it is because someone
wanted to add the same feature to U-Boot or some other package, and we
said we didn't want to add this possibility to each and every package
in Buildroot.

I am however surprised that you need something like this for a build
that will be done by others. Why is it that you need to "prepare your
kernel sources" before starting the build? Why aren't you referencing a
given commit in some Git repository?

In the worst case, adding local.mk (which you can rename, it's
configurable in BR2_PACKAGE_OVERRIDE_FILE) to your version control
system will do the trick. But I'm still interested in understanding
your more global use case for this functionality.

> On a related note, if the intent is to still leave this reverted,
> BR2_LINUX_KERNEL_CUSTOM_LOCAL is still being reference in the
> `linux-header` package [2] and `linux/Config.in` [3] (just dead code).
> I can whip up a patch if no one wants to take a stab at it?
> 
> [1]: https://patchwork.ozlabs.org/patch/641254/
> [2]: https://git.buildroot.net/buildroot/tree/package/linux-headers/linux-headers.mk?id=0d7383a0a7f5c69cb0e4a4eb0d32d2536cd7e0e8#n20
> [3]: https://git.buildroot.net/buildroot/tree/linux/Config.in#n113

Please submit a patch :-)

Thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

  reply	other threads:[~2016-12-12 16:27 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-27 22:34 [Buildroot] [PATCH RFC] Revert "Added local directory as source of kernel code" Yann E. MORIN
2016-08-27 20:23 ` Thomas Petazzoni
2016-08-27 22:54   ` Yann E. MORIN
2016-08-28  7:23     ` Thomas Petazzoni
2016-08-28 20:37   ` Peter Korsgaard
2016-08-28 21:48     ` Yann E. MORIN
2016-08-29  7:16       ` Thomas Petazzoni
2016-12-12  3:06         ` James Knight
2016-12-12 16:27           ` Thomas Petazzoni [this message]
2016-12-12 17:35           ` Yann E. MORIN
2016-12-12 17:52             ` Thomas Petazzoni
2016-12-12 22:31               ` James Knight

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=20161212172715.4a8ab39f@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