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 1/2] pkg-kconfig: support alternative .config location
Date: Mon, 12 Sep 2016 22:17:30 +0200	[thread overview]
Message-ID: <20160912221730.6b167675@free-electrons.com> (raw)
In-Reply-To: <1473705627-32589-2-git-send-email-eric.le.bihan.dev@free.fr>

Hello,

On Mon, 12 Sep 2016 20:40:26 +0200, Eric Le Bihan wrote:

> diff --git a/package/pkg-kconfig.mk b/package/pkg-kconfig.mk
> index b0f5178..46e1bef 100644
> --- a/package/pkg-kconfig.mk
> +++ b/package/pkg-kconfig.mk
> @@ -36,6 +36,7 @@ $(2)_KCONFIG_EDITORS ?= menuconfig
>  $(2)_KCONFIG_OPTS ?=
>  $(2)_KCONFIG_FIXUP_CMDS ?=
>  $(2)_KCONFIG_FRAGMENT_FILES ?=
> +$(2)_KCONFIG_DOTCONFIG ?= $$($(2)_DIR)/.config

I think I'd prefer if this variable contained the path of the .config
relative to the source directory of the package. I.e just:

$(2)_KCONFIG_DOTCONFIG ?= .config

here

>  
>  # The config file as well as the fragments could be in-tree, so before
>  # depending on them the package should be extracted (and patched) first.
> @@ -91,9 +92,10 @@ endef
>  # fragments are merged together to .config, after the package has been patched.
>  # Since the file could be a defconfig file it needs to be expanded to a
>  # full .config first.
> -$$($(2)_DIR)/.config: $$($(2)_KCONFIG_FILE) $$($(2)_KCONFIG_FRAGMENT_FILES)
> +$$($(2)_KCONFIG_DOTCONFIG): $$($(2)_KCONFIG_FILE) $$($(2)_KCONFIG_FRAGMENT_FILES)

$$($(2)_DIR)/$$($(2)_KCONFIG_DOTCONFIG)

here

>  	$$(Q)$$(if $$($(2)_KCONFIG_DEFCONFIG), \
>  		$$($(2)_KCONFIG_MAKE) $$($(2)_KCONFIG_DEFCONFIG), \
> +		mkdir -p $$(dir $$(@)); \

It's not immediately clear why you need this. Are there cases where the
directory containing the .config may not exist? If so, it should be
explained in the commit log. And you can replace $$(dir $$(@)) by
$$(@D).

Thanks,

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

  reply	other threads:[~2016-09-12 20:17 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-12 18:40 [Buildroot] [PATCH 0/2] Introducing Xvisor Eric Le Bihan
2016-09-12 18:40 ` [Buildroot] [PATCH 1/2] pkg-kconfig: support alternative .config location Eric Le Bihan
2016-09-12 20:17   ` Thomas Petazzoni [this message]
2016-09-12 18:40 ` [Buildroot] [PATCH 2/2] xvisor: new package Eric Le Bihan
2016-09-12 20:25   ` Thomas Petazzoni

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=20160912221730.6b167675@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