All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arnout Vandecappelle <arnout@mind.be>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] sysklogd: override SKFLAGS with TARGET_CFLAGS
Date: Sun, 21 Feb 2016 01:00:44 +0100	[thread overview]
Message-ID: <56C8FE2C.1070000@mind.be> (raw)
In-Reply-To: <1455967730-10332-1-git-send-email-romain.naour@gmail.com>

On 02/20/16 12:28, Romain Naour wrote:
> TARGET_CFLAGS is not taken into account since SKFLAGS is used as CFLAGS.
> We need to override SKFLAGS with TARGET_CFLAGS but keep -DSYSV which was
> present in SKFLAGS.
> 
> Improve the previous fix introduced by
> 8e3a5c13546451c0c6ceb8bc64e4397ceed14aca.
> 
> Fixes:
> http://autobuild.buildroot.net/results/2fb/2fb94ecfdc32761a09da35e6fcbdd512847ec911
> 
> Signed-off-by: Romain Naour <romain.naour@gmail.com>
> Reported-by: Peter Korsgaard <peter@korsgaard.com>
> Cc: Peter Korsgaard <peter@korsgaard.com>
> ---
>  package/sysklogd/sysklogd.mk | 12 +++---------
>  1 file changed, 3 insertions(+), 9 deletions(-)
> 
> diff --git a/package/sysklogd/sysklogd.mk b/package/sysklogd/sysklogd.mk
> index 9e315bc..49997d4 100644
> --- a/package/sysklogd/sysklogd.mk
> +++ b/package/sysklogd/sysklogd.mk
> @@ -14,16 +14,10 @@ ifeq ($(BR2_PACKAGE_BUSYBOX),y)
>  SYSKLOGD_DEPENDENCIES = busybox
>  endif
>  
> -# CS PowerPC 2012.03 triggers compiler bug.
> -ifeq ($(BR2_TOOLCHAIN_EXTERNAL_CODESOURCERY_POWERPC_E500V2),y)
> -define SYSKLOGD_WORKAROUND_COMPILER_BUG
> -	$(SED) 's/-O3/-O2/' $(@D)/Makefile
> -endef
> -SYSKLOGD_POST_PATCH_HOOKS = SYSKLOGD_WORKAROUND_COMPILER_BUG
> -endif
> -
> +# Override SKFLAGS which is used as CFLAGS.
>  define SYSKLOGD_BUILD_CMDS
> -	$(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)
> +	$(MAKE) $(TARGET_CONFIGURE_OPTS) SKFLAGS="$(TARGET_CFLAGS) -DSYSV" \

 Doesn't that make the bug above reappear when you have configured
BR2_OPTIMIZE_3? In other words, shouldn't we do something like:

ifeq ($(BR2_TOOLCHAIN...),y)
SYSKLOGD_CFLAGS = $(subst -O3,-O2,$(TARGET_CFLAGS))
else
SYSKLOGD_CFLAGS = $(TARGET_CFLAGS)
endif
SYSKLOGD_CFLAGS += -DSYSV


 Regards,
 Arnout


> +		-C $(@D)
>  endef
>  
>  define SYSKLOGD_INSTALL_TARGET_CMDS
> 


-- 
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF

  parent reply	other threads:[~2016-02-21  0:00 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-20 11:28 [Buildroot] [PATCH] sysklogd: override SKFLAGS with TARGET_CFLAGS Romain Naour
2016-02-20 20:25 ` Peter Korsgaard
2016-02-21  0:00 ` Arnout Vandecappelle [this message]
2016-02-21  9:21   ` Peter Korsgaard

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=56C8FE2C.1070000@mind.be \
    --to=arnout@mind.be \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.