public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] Default to HOSTARCH if ARCH isn't specified
@ 2009-04-20 17:03 Kumar Gala
  2009-04-20 18:56 ` Jean-Christophe PLAGNIOL-VILLARD
  2009-04-20 20:36 ` Wolfgang Denk
  0 siblings, 2 replies; 4+ messages in thread
From: Kumar Gala @ 2009-04-20 17:03 UTC (permalink / raw)
  To: u-boot

Its possible to build natively on several platforms so we might not
explicitly set ARCH but detect it via HOSTARCH.  As such there are
some things that expect ARCH to be set to work correctly.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
---
 Makefile |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/Makefile b/Makefile
index e91c051..c56d6db 100644
--- a/Makefile
+++ b/Makefile
@@ -137,6 +137,10 @@ ifeq ($(ARCH),powerpc)
 ARCH = ppc
 endif
 
+ifndef ARCH
+ARCH = $(HOSTARCH)
+endif
+
 ifeq ($(obj)include/config.mk,$(wildcard $(obj)include/config.mk))
 
 # load ARCH, BOARD, and CPU configuration
-- 
1.6.0.6

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

* [U-Boot] [PATCH] Default to HOSTARCH if ARCH isn't specified
  2009-04-20 17:03 [U-Boot] [PATCH] Default to HOSTARCH if ARCH isn't specified Kumar Gala
@ 2009-04-20 18:56 ` Jean-Christophe PLAGNIOL-VILLARD
  2009-04-20 20:36 ` Wolfgang Denk
  1 sibling, 0 replies; 4+ messages in thread
From: Jean-Christophe PLAGNIOL-VILLARD @ 2009-04-20 18:56 UTC (permalink / raw)
  To: u-boot

On 12:03 Mon 20 Apr     , Kumar Gala wrote:
> Its possible to build natively on several platforms so we might not
> explicitly set ARCH but detect it via HOSTARCH.  As such there are
> some things that expect ARCH to be set to work correctly.
> 
> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>

Best Regards,
J.

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

* [U-Boot] [PATCH] Default to HOSTARCH if ARCH isn't specified
  2009-04-20 17:03 [U-Boot] [PATCH] Default to HOSTARCH if ARCH isn't specified Kumar Gala
  2009-04-20 18:56 ` Jean-Christophe PLAGNIOL-VILLARD
@ 2009-04-20 20:36 ` Wolfgang Denk
  2009-04-20 20:49   ` Scott Wood
  1 sibling, 1 reply; 4+ messages in thread
From: Wolfgang Denk @ 2009-04-20 20:36 UTC (permalink / raw)
  To: u-boot

Dear Kumar Gala,

In message <1240247017-1069-1-git-send-email-galak@kernel.crashing.org> you wrote:
> Its possible to build natively on several platforms so we might not
> explicitly set ARCH but detect it via HOSTARCH.  As such there are
> some things that expect ARCH to be set to work correctly.
> 
> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
> ---
>  Makefile |    4 ++++
>  1 files changed, 4 insertions(+), 0 deletions(-)
> 
> diff --git a/Makefile b/Makefile
> index e91c051..c56d6db 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -137,6 +137,10 @@ ifeq ($(ARCH),powerpc)
>  ARCH = ppc
>  endif
>  
> +ifndef ARCH
> +ARCH = $(HOSTARCH)
> +endif
> +

In current mainline U-Boot, such a patch is not needed (which is just a
friendly version of saying it does not make sense :-), because ARCH
gets loaded from include/config.mk after running "make <board>_config".

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
"I used to think that the brain was the most wonderful  organ  in  my
body. Then I realized who was telling me this."        - Emo Phillips

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

* [U-Boot] [PATCH] Default to HOSTARCH if ARCH isn't specified
  2009-04-20 20:36 ` Wolfgang Denk
@ 2009-04-20 20:49   ` Scott Wood
  0 siblings, 0 replies; 4+ messages in thread
From: Scott Wood @ 2009-04-20 20:49 UTC (permalink / raw)
  To: u-boot

Wolfgang Denk wrote:
> Dear Kumar Gala,
> 
> In message <1240247017-1069-1-git-send-email-galak@kernel.crashing.org> you wrote:
>> diff --git a/Makefile b/Makefile
>> index e91c051..c56d6db 100644
>> --- a/Makefile
>> +++ b/Makefile
>> @@ -137,6 +137,10 @@ ifeq ($(ARCH),powerpc)
>>  ARCH = ppc
>>  endif
>>  
>> +ifndef ARCH
>> +ARCH = $(HOSTARCH)
>> +endif
>> +
> 
> In current mainline U-Boot, such a patch is not needed (which is just a
> friendly version of saying it does not make sense :-), because ARCH
> gets loaded from include/config.mk after running "make <board>_config".

In which case, we should probably add "override" to the place where it 
is set, so as to avoid interference from any ARCH variable that might be 
set (we could then remove the powerpc->ppc bit).

-Scott

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

end of thread, other threads:[~2009-04-20 20:49 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-04-20 17:03 [U-Boot] [PATCH] Default to HOSTARCH if ARCH isn't specified Kumar Gala
2009-04-20 18:56 ` Jean-Christophe PLAGNIOL-VILLARD
2009-04-20 20:36 ` Wolfgang Denk
2009-04-20 20:49   ` Scott Wood

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