public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] kbuild: create a build directory automatically for out-of-tree build
@ 2014-03-24  4:55 Masahiro Yamada
  2014-03-24 23:41 ` Simon Glass
  2014-03-28 21:16 ` [U-Boot] " Tom Rini
  0 siblings, 2 replies; 7+ messages in thread
From: Masahiro Yamada @ 2014-03-24  4:55 UTC (permalink / raw)
  To: u-boot

Prior to Kbuild, the build system created a build directory,
when it did not exist, for out-of-tree build.

This feature was dropped when we switched to Kbuild
because many of lines in makefiles were copied from Linux Kernel.
(In Linux Kernel, we have to create a build directory by ourselves
before starting build.)

That feature seems worth reviving for less typing
even if our code and Linux Kernel diverge.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Suggested-by: Simon Glass <sjg@chromium.org>
---
 Makefile | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index 538c3bf..0522ba8 100644
--- a/Makefile
+++ b/Makefile
@@ -124,7 +124,8 @@ ifneq ($(KBUILD_OUTPUT),)
 # Invoke a second make in the output directory, passing relevant variables
 # check that the output directory actually exists
 saved-output := $(KBUILD_OUTPUT)
-KBUILD_OUTPUT := $(shell cd $(KBUILD_OUTPUT) && /bin/pwd)
+KBUILD_OUTPUT := $(shell mkdir -p $(KBUILD_OUTPUT) && cd $(KBUILD_OUTPUT) \
+								&& /bin/pwd)
 $(if $(KBUILD_OUTPUT),, \
      $(error output directory "$(saved-output)" does not exist))
 
-- 
1.8.3.2

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [U-Boot] [PATCH] kbuild: create a build directory automatically for out-of-tree build
  2014-03-24  4:55 [U-Boot] [PATCH] kbuild: create a build directory automatically for out-of-tree build Masahiro Yamada
@ 2014-03-24 23:41 ` Simon Glass
  2014-03-27 17:20   ` Tom Rini
  2014-03-28 21:16 ` [U-Boot] " Tom Rini
  1 sibling, 1 reply; 7+ messages in thread
From: Simon Glass @ 2014-03-24 23:41 UTC (permalink / raw)
  To: u-boot

+Tom

On 23 March 2014 22:55, Masahiro Yamada <yamada.m@jp.panasonic.com> wrote:

> Prior to Kbuild, the build system created a build directory,
> when it did not exist, for out-of-tree build.
>
> This feature was dropped when we switched to Kbuild
> because many of lines in makefiles were copied from Linux Kernel.
> (In Linux Kernel, we have to create a build directory by ourselves
> before starting build.)
>
> That feature seems worth reviving for less typing
> even if our code and Linux Kernel diverge.
>
> Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
> Suggested-by: Simon Glass <sjg@chromium.org>
>

Acked-by: Simon Glass <sjg@chromium.org>
Tested-by: Simon Glass <sjg@chromium.org>

Arguably could be a bug-fix for this release.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot] [PATCH] kbuild: create a build directory automatically for out-of-tree build
  2014-03-24 23:41 ` Simon Glass
@ 2014-03-27 17:20   ` Tom Rini
  2014-03-28  2:37     ` Masahiro Yamada
  0 siblings, 1 reply; 7+ messages in thread
From: Tom Rini @ 2014-03-27 17:20 UTC (permalink / raw)
  To: u-boot

On Mon, Mar 24, 2014 at 05:41:47PM -0600, Simon Glass wrote:
> +Tom
> 
> On 23 March 2014 22:55, Masahiro Yamada <yamada.m@jp.panasonic.com> wrote:
> 
> > Prior to Kbuild, the build system created a build directory,
> > when it did not exist, for out-of-tree build.
> >
> > This feature was dropped when we switched to Kbuild
> > because many of lines in makefiles were copied from Linux Kernel.
> > (In Linux Kernel, we have to create a build directory by ourselves
> > before starting build.)
> >
> > That feature seems worth reviving for less typing
> > even if our code and Linux Kernel diverge.
> >
> > Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
> > Suggested-by: Simon Glass <sjg@chromium.org>
> >
> 
> Acked-by: Simon Glass <sjg@chromium.org>
> Tested-by: Simon Glass <sjg@chromium.org>
> 
> Arguably could be a bug-fix for this release.

Yeah, I like this and will pick it up.  The only question is, has this
idea already been rejected in the kernel?

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20140327/e22f001d/attachment.pgp>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot] [PATCH] kbuild: create a build directory automatically for out-of-tree build
  2014-03-27 17:20   ` Tom Rini
@ 2014-03-28  2:37     ` Masahiro Yamada
  2014-03-28  2:43       ` Simon Glass
  2014-04-15  4:38       ` Masahiro Yamada
  0 siblings, 2 replies; 7+ messages in thread
From: Masahiro Yamada @ 2014-03-28  2:37 UTC (permalink / raw)
  To: u-boot

Hi Tom,


On Thu, 27 Mar 2014 13:20:33 -0400
Tom Rini <trini@ti.com> wrote:

> On Mon, Mar 24, 2014 at 05:41:47PM -0600, Simon Glass wrote:
> > +Tom
> > 
> > On 23 March 2014 22:55, Masahiro Yamada <yamada.m@jp.panasonic.com> wrote:
> > 
> > > Prior to Kbuild, the build system created a build directory,
> > > when it did not exist, for out-of-tree build.
> > >
> > > This feature was dropped when we switched to Kbuild
> > > because many of lines in makefiles were copied from Linux Kernel.
> > > (In Linux Kernel, we have to create a build directory by ourselves
> > > before starting build.)
> > >
> > > That feature seems worth reviving for less typing
> > > even if our code and Linux Kernel diverge.
> > >
> > > Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
> > > Suggested-by: Simon Glass <sjg@chromium.org>
> > >
> > 
> > Acked-by: Simon Glass <sjg@chromium.org>
> > Tested-by: Simon Glass <sjg@chromium.org>
> > 
> > Arguably could be a bug-fix for this release.
> 
> Yeah, I like this and will pick it up.  The only question is, has this
> idea already been rejected in the kernel?
> 

I have not sent this patch to the kernel community yet.
OK. I will.


Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot] [PATCH] kbuild: create a build directory automatically for out-of-tree build
  2014-03-28  2:37     ` Masahiro Yamada
@ 2014-03-28  2:43       ` Simon Glass
  2014-04-15  4:38       ` Masahiro Yamada
  1 sibling, 0 replies; 7+ messages in thread
From: Simon Glass @ 2014-03-28  2:43 UTC (permalink / raw)
  To: u-boot

Hi,

On 27 March 2014 20:37, Masahiro Yamada <yamada.m@jp.panasonic.com> wrote:

> Hi Tom,
>
>
> On Thu, 27 Mar 2014 13:20:33 -0400
> Tom Rini <trini@ti.com> wrote:
>
> > On Mon, Mar 24, 2014 at 05:41:47PM -0600, Simon Glass wrote:
> > > +Tom
> > >
> > > On 23 March 2014 22:55, Masahiro Yamada <yamada.m@jp.panasonic.com>
> wrote:
> > >
> > > > Prior to Kbuild, the build system created a build directory,
> > > > when it did not exist, for out-of-tree build.
> > > >
> > > > This feature was dropped when we switched to Kbuild
> > > > because many of lines in makefiles were copied from Linux Kernel.
> > > > (In Linux Kernel, we have to create a build directory by ourselves
> > > > before starting build.)
> > > >
> > > > That feature seems worth reviving for less typing
> > > > even if our code and Linux Kernel diverge.
> > > >
> > > > Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
> > > > Suggested-by: Simon Glass <sjg@chromium.org>
> > > >
> > >
> > > Acked-by: Simon Glass <sjg@chromium.org>
> > > Tested-by: Simon Glass <sjg@chromium.org>
> > >
> > > Arguably could be a bug-fix for this release.
> >
> > Yeah, I like this and will pick it up.  The only question is, has this
> > idea already been rejected in the kernel?
> >
>
> I have not sent this patch to the kernel community yet.
> OK. I will.
>

My point is that this is a change from the old U-Boot behaviour, so it
would be nice to fix it.

Regards,
Simon


>
>
> Best Regards
> Masahiro Yamada
>
>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot] kbuild: create a build directory automatically for out-of-tree build
  2014-03-24  4:55 [U-Boot] [PATCH] kbuild: create a build directory automatically for out-of-tree build Masahiro Yamada
  2014-03-24 23:41 ` Simon Glass
@ 2014-03-28 21:16 ` Tom Rini
  1 sibling, 0 replies; 7+ messages in thread
From: Tom Rini @ 2014-03-28 21:16 UTC (permalink / raw)
  To: u-boot

On Mon, Mar 24, 2014 at 01:55:27PM +0900, Masahiro Yamada wrote:

> Prior to Kbuild, the build system created a build directory,
> when it did not exist, for out-of-tree build.
> 
> This feature was dropped when we switched to Kbuild
> because many of lines in makefiles were copied from Linux Kernel.
> (In Linux Kernel, we have to create a build directory by ourselves
> before starting build.)
> 
> That feature seems worth reviving for less typing
> even if our code and Linux Kernel diverge.
> 
> Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
> Suggested-by: Simon Glass <sjg@chromium.org>
> Acked-by: Simon Glass <sjg@chromium.org>
> Tested-by: Simon Glass <sjg@chromium.org>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20140328/52ab2212/attachment.pgp>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot] [PATCH] kbuild: create a build directory automatically for out-of-tree build
  2014-03-28  2:37     ` Masahiro Yamada
  2014-03-28  2:43       ` Simon Glass
@ 2014-04-15  4:38       ` Masahiro Yamada
  1 sibling, 0 replies; 7+ messages in thread
From: Masahiro Yamada @ 2014-04-15  4:38 UTC (permalink / raw)
  To: u-boot

Hi Tom,


On Fri, 28 Mar 2014 11:37:28 +0900
Masahiro Yamada <yamada.m@jp.panasonic.com> wrote:

> Hi Tom,
> 
> 
> On Thu, 27 Mar 2014 13:20:33 -0400
> Tom Rini <trini@ti.com> wrote:
> 
> > On Mon, Mar 24, 2014 at 05:41:47PM -0600, Simon Glass wrote:
> > > +Tom
> > > 
> > > On 23 March 2014 22:55, Masahiro Yamada <yamada.m@jp.panasonic.com> wrote:
> > > 
> > > > Prior to Kbuild, the build system created a build directory,
> > > > when it did not exist, for out-of-tree build.
> > > >
> > > > This feature was dropped when we switched to Kbuild
> > > > because many of lines in makefiles were copied from Linux Kernel.
> > > > (In Linux Kernel, we have to create a build directory by ourselves
> > > > before starting build.)
> > > >
> > > > That feature seems worth reviving for less typing
> > > > even if our code and Linux Kernel diverge.
> > > >
> > > > Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
> > > > Suggested-by: Simon Glass <sjg@chromium.org>
> > > >
> > > 
> > > Acked-by: Simon Glass <sjg@chromium.org>
> > > Tested-by: Simon Glass <sjg@chromium.org>
> > > 
> > > Arguably could be a bug-fix for this release.
> > 
> > Yeah, I like this and will pick it up.  The only question is, has this
> > idea already been rejected in the kernel?
> > 
> 
> I have not sent this patch to the kernel community yet.
> OK. I will.
> 

The good news is this feature was merged
in Linux Kernel mainline (commit 1c9e70a55).


Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2014-04-15  4:38 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-24  4:55 [U-Boot] [PATCH] kbuild: create a build directory automatically for out-of-tree build Masahiro Yamada
2014-03-24 23:41 ` Simon Glass
2014-03-27 17:20   ` Tom Rini
2014-03-28  2:37     ` Masahiro Yamada
2014-03-28  2:43       ` Simon Glass
2014-04-15  4:38       ` Masahiro Yamada
2014-03-28 21:16 ` [U-Boot] " Tom Rini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox