From: Allen Martin <amartin@nvidia.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v2 1/7] tegra: Rework Tamonten support
Date: Fri, 8 Jun 2012 23:25:35 -0700 [thread overview]
Message-ID: <20120609062534.GA28640@nvidia.com> (raw)
In-Reply-To: <4FD2DF19.4010405@wwwdotorg.org>
On Fri, Jun 08, 2012 at 10:28:57PM -0700, Stephen Warren wrote:
> On 06/08/2012 03:27 PM, Allen Martin wrote:
> > On Fri, Jun 08, 2012 at 02:07:25PM -0700, Stephen Warren wrote:
> >> On 06/08/2012 02:01 PM, Allen Martin wrote:
> >>> On Fri, May 25, 2012 at 06:46:22AM -0700, Thierry Reding wrote:
> >>>> This commit uses the common Tegra board implementation instead of
> >>>> duplicating a lot of the code. In addition, the Plutux and Medcom
> >>>> specific board files can be removed as the MMC/SD setup is common
> >>>> among all Tamonten-based boards.
> >>>>
> >>>> ...
> >>>> diff --git a/board/avionic-design/medcom/Makefile b/board/avionic-design/medcom/Makefile
> >>>> index b0c318c..d96d043 100644
> >>>> --- a/board/avionic-design/medcom/Makefile
> >>>> +++ b/board/avionic-design/medcom/Makefile
> >>>> @@ -26,12 +26,12 @@
> >>>> include $(TOPDIR)/config.mk
> >>>>
> >>>> ifneq ($(OBJTREE),$(SRCTREE))
> >>>> -$(shell mkdir -p $(obj)../common)
> >>>> +$(shell mkdir -p $(obj)../common $(obj)../../nvidia/common)
> >>>> endif
> >>>>
> >>>> LIB = $(obj)lib$(BOARD).o
> >>>>
> >>>
> >>> This breaks with my patchset to split out the arm7 code to an SPL
> >>> because even though SRCDIR and OBJDIR are the same, in the SPL build
> >>> $(obj) is a subdir of $(SPLTREE) not $(OBJTREE) (not my doing).
> >>>
> >>> How about the following instead which seems more to the point:
> >>>
> >>> ifeq ($(wildcard $(obj)../common),)
> >>> $(shell mkdir -p $(obj)../common)
> >>> endif
> >>> ifeq ($(wildcard $(obj)../../nvidia/common),)
> >>> $(shell mkdir -p $(obj)../../nvidia/common)
> >>> endif
> >>
> >> Maybe I'm just not reading it right, but isn't that just running the
> >> exact same mkdir commands, just splitting it into two commands, and
> >> making them optional based on the $(wildcard)? I'm still not clear what
> >> the problem is.
> >>
> >> Anyway, if this is an issue, then compal/paz00 and compulabl/trimslice
> >> will need to be fixed for the SPL changes in the same way.
> >
> > The problem is this:
> >
> >>>> ifneq ($(OBJTREE),$(SRCTREE))
> >
> > is true, but these directories:
> >
> >>>> +$(shell mkdir -p $(obj)../common $(obj)../../nvidia/common)
> >
> > don't exist because $(obj) is not under $(OBJTREE) in the SPL build,
> > it's under $(SPLTREE)
>
> OK, so I think the issue is just that $(obj) isn't the correct place to
> mkdir these, not that we shouldn't attempt to mkdir any directory. In
> other words, don't you need to switch between mkdir in the object tree
> or the SPL tree rather than switching between doing a mkdir and not?
> It's quite possible this only affects builds where OBJDIR!=SRCDIR, so a
> regular build might not show up the problem I /think/ exists in the code
> quoted a couple of emails above.
$(obj) is always the place where the object files are going to be
placed, that may be in $(OBJTREE) or in $(SRCTREE) or in $(SPLTREE)
depending on what you're building and what you have set.
I think the $(wildcard) suggestion I made is the most straightforward,
it basically says "we're about to spit out an object file to here, so
make sure the directory exists first". In the "normal" case where
your object files are in your source tree the directory will already
exist so it won't do anything.
-Allen
--
nvpublic
next prev parent reply other threads:[~2012-06-09 6:25 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-25 13:46 [U-Boot] [PATCH v2 1/7] tegra: Rework Tamonten support Thierry Reding
2012-05-25 13:46 ` [U-Boot] [PATCH v2 2/7] tegra: medcom: Add device tree support Thierry Reding
2012-05-25 13:46 ` [U-Boot] [PATCH v2 3/7] tegra: plutux: " Thierry Reding
2012-05-25 13:46 ` [U-Boot] [PATCH v2 4/7] tegra: Allow boards to perform early GPIO setup Thierry Reding
2012-05-25 16:24 ` Stephen Warren
2012-05-25 17:31 ` Thierry Reding
2012-05-25 17:59 ` Thierry Reding
2012-05-31 20:35 ` Tom Warren
2012-06-04 6:09 ` Thierry Reding
2012-06-04 16:47 ` Tom Warren
2012-05-25 13:46 ` [U-Boot] [PATCH v2 5/7] tegra: Implement gpio_early_init() on Tamonten Thierry Reding
2012-05-25 16:27 ` Stephen Warren
2012-05-25 17:40 ` Thierry Reding
2012-05-25 18:56 ` Kai Poggensee
2012-05-29 14:57 ` Thierry Reding
2012-05-29 16:06 ` Stephen Warren
2012-05-25 13:46 ` [U-Boot] [PATCH v2 6/7] tegra: Use SD write-protect GPIO " Thierry Reding
2012-05-25 13:46 ` [U-Boot] [PATCH v2 7/7] tegra: Add Tamonten Evaluation Carrier support Thierry Reding
2012-05-25 16:31 ` Stephen Warren
2012-06-08 20:01 ` [U-Boot] [PATCH v2 1/7] tegra: Rework Tamonten support Allen Martin
2012-06-08 21:07 ` Stephen Warren
2012-06-08 21:27 ` Allen Martin
2012-06-09 5:28 ` Stephen Warren
2012-06-09 6:25 ` Allen Martin [this message]
2012-06-09 16:18 ` Stephen Warren
2012-06-11 9:29 ` Thierry Reding
2012-06-11 17:59 ` Allen Martin
2012-06-11 18:07 ` Thierry Reding
2012-06-11 18:03 ` Allen Martin
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=20120609062534.GA28640@nvidia.com \
--to=amartin@nvidia.com \
--cc=u-boot@lists.denx.de \
/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