Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH v3 2/2] logrotate: use pkg-config for the opt library
Date: Thu, 5 Mar 2015 09:28:10 +0100	[thread overview]
Message-ID: <20150305092810.284ba54a@free-electrons.com> (raw)
In-Reply-To: <CAHkwnC_SRcjuP+yk4_O8WixZLKVuxLRs-N4+xe12doA=a27jSA@mail.gmail.com>

Dear Fabio Porcedda,

On Thu, 5 Mar 2015 00:38:25 +0100, Fabio Porcedda wrote:

> > It's not currently supported in Buildroot, but LOADLIBES is extended by
> > the logrotate Makefile with -lacl or -lselinux when WITH_ACL or
> > WITH_SELINUX are used. I'm not sure this will play well with your
> > proposed solution.
> 
> Thanks for noticing it.
> I didn't know that a variable forced from the command line cannot be extended.
> Now I'm aware of it.

Depends on whether you pass variables in the environment (on the left
hand side of make) or as make options (on the right hand side of make).
Demonstration with a simple Makefile:

===
FOO = -lbaz

ifeq ($(WITH_SELINUX),yes)
FOO += -lselinux
endif

all:
	@echo $(FOO)
===

And now, the different cases:

thomas at skate:/tmp$ make
-lbaz
thomas at skate:/tmp$ make FOO=-lpouet
-lpouet
thomas at skate:/tmp$ make FOO=-lpouet WITH_SELINUX=yes
-lpouet
thomas at skate:/tmp$ make WITH_SELINUX=yes
-lbaz -lselinux
thomas at skate:/tmp$ FOO=-lpouet make
-lbaz
thomas at skate:/tmp$ FOO=-lpouet make WITH_SELINUX=yes
-lbaz -lselinux

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

  reply	other threads:[~2015-03-05  8:28 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-01 21:06 [Buildroot] [PATCH v3 0/2] Fix logrotate autobuild failure Fabio Porcedda
2015-03-01 21:06 ` [Buildroot] [PATCH v3 1/2] popt: add to the "popt.pc" file the libintl library Fabio Porcedda
2015-03-04 22:27   ` Thomas Petazzoni
2015-03-01 21:06 ` [Buildroot] [PATCH v3 2/2] logrotate: use pkg-config for the opt library Fabio Porcedda
2015-03-04 22:29   ` Thomas Petazzoni
2015-03-04 23:38     ` Fabio Porcedda
2015-03-05  8:28       ` Thomas Petazzoni [this message]
2015-03-05  8:43         ` Fabio Porcedda
2015-03-01 21:35 ` [Buildroot] [PATCH v3 0/2] Fix logrotate autobuild failure Peter Korsgaard
2015-03-01 21:43   ` Fabio Porcedda

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=20150305092810.284ba54a@free-electrons.com \
    --to=thomas.petazzoni@free-electrons.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox