Patchwork [v5,7/7] package: Introduce NOMMU symbol

login
register
mail settings
Submitter Sonic Zhang
Date April 12, 2013, 10:18 a.m.
Message ID <1365761909-15305-7-git-send-email-sonic.adi@gmail.com>
Download mbox | patch
Permalink /patch/236022/
State Changes Requested
Headers show

Comments

Sonic Zhang - April 12, 2013, 10:18 a.m.
From: Sonic Zhang <sonic.zhang@analog.com>

Introduce NOMMU symbol __NOMMU__

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
---
 package/Makefile.in |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
Thomas Petazzoni - April 16, 2013, 9:30 p.m.
Dear Sonic Zhang,

On Fri, 12 Apr 2013 18:18:29 +0800, Sonic Zhang wrote:

>  ifeq ($(BR2_BINFMT_FLAT),y)
>  TARGET_LDFLAGS += $(if $($(PKG)_FLAT_STACKSIZE),-Wl$(comma)-elf2flt=-s$($(PKG)_FLAT_STACKSIZE))
> +
> +ifneq ($(BR2_USE_MMU), y)

There shouldn't be any space between the comma and the y.

> +TARGET_CFLAGS += -D__NOMMU__
>  endif
>  
>  ifeq ($(BR2_BINFMT_FLAT_SHARED),y)

And you're adding a ifneq condition without adding any endif. Smells
like untested code :)

Thomas
Sonic Zhang - April 17, 2013, 7:27 a.m.
Hi Thomas,

On Wed, Apr 17, 2013 at 5:30 AM, Thomas Petazzoni
<thomas.petazzoni@free-electrons.com> wrote:
> Dear Sonic Zhang,
>
> On Fri, 12 Apr 2013 18:18:29 +0800, Sonic Zhang wrote:
>
>>  ifeq ($(BR2_BINFMT_FLAT),y)
>>  TARGET_LDFLAGS += $(if $($(PKG)_FLAT_STACKSIZE),-Wl$(comma)-elf2flt=-s$($(PKG)_FLAT_STACKSIZE))
>> +
>> +ifneq ($(BR2_USE_MMU), y)
>
> There shouldn't be any space between the comma and the y.
>
>> +TARGET_CFLAGS += -D__NOMMU__
>>  endif
>>
>>  ifeq ($(BR2_BINFMT_FLAT_SHARED),y)
>
> And you're adding a ifneq condition without adding any endif. Smells
> like untested code :)
>
That's an error when I rebase this patch automatically. Should be fixed soon.

Regards,

Sonic

Patch

diff --git a/package/Makefile.in b/package/Makefile.in
index a449089..e7bb61f 100644
--- a/package/Makefile.in
+++ b/package/Makefile.in
@@ -105,6 +105,9 @@  TARGET_LDFLAGS = $(call qstrip,$(BR2_TARGET_LDFLAGS))
 
 ifeq ($(BR2_BINFMT_FLAT),y)
 TARGET_LDFLAGS += $(if $($(PKG)_FLAT_STACKSIZE),-Wl$(comma)-elf2flt=-s$($(PKG)_FLAT_STACKSIZE))
+
+ifneq ($(BR2_USE_MMU), y)
+TARGET_CFLAGS += -D__NOMMU__
 endif
 
 ifeq ($(BR2_BINFMT_FLAT_SHARED),y)