linux-kbuild.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Konstantin Khlebnikov <koct9i@gmail.com>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Michal Marek <mmarek@suse.cz>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	linux-kbuild <linux-kbuild@vger.kernel.org>,
	Paul Bolle <pebolle@tiscali.nl>
Subject: Re: [PATCH v2 0/4] kconfig: store default ARCH in .config
Date: Mon, 1 Sep 2014 11:35:06 +0400	[thread overview]
Message-ID: <CALYGNiPUCFkx6sgLbCKrXbDVERhyaWyGJPp64fowBWpUALXqEQ@mail.gmail.com> (raw)
In-Reply-To: <CAMuHMdXKyTJZM9fwcCZ+-vCX3SZ9JuhPiNNAhyu=vrZuOjsw8w@mail.gmail.com>

On Mon, Sep 1, 2014 at 11:24 AM, Geert Uytterhoeven
<geert@linux-m68k.org> wrote:
> Hi Konstantin,
>
> On Mon, Sep 1, 2014 at 9:16 AM, Konstantin Khlebnikov <koct9i@gmail.com> wrote:
>> This is second attempt of fixing target archecture amnesia.
>> v1 patch: http://lkml.kernel.org/r/20140706080234.19520.96704.stgit@zurg
>>
>> First version saved ARCH as CONFIG_DEFAULT_ARCH and used it as defult ARCH.
>>
>> This version changes semantic of Kconfig option env="...", now it acts more
>> like the user input, except that the value comes from the environment.
>> Variable from environment overrides all defaults and value from config file.
>> If environment variable is not defined this option has no effect.
>>
>> So, now ARCH is saved as CONFIG_ARCH.
>>
>> Also this patchset links CONFIG_CROSS_COMPILE and CROSS_COMPILE in the same way.
>> Changing it in command line/environment also updates value in the config file.
>
> Thanks, I haven't tried this yet, but it looks promising!
>
> For the record, right now I use a GNUmakefile (which takes precedence over
> the Makefile) in the build directory containing e.g.

Heh, I've used and seen a lot of such hacks.
GNUmakefile also might include Makefile after defining environment.

>
> MAKEARGS = ARCH=arm CROSS_COMPILE=arm-unknown-linux-gnueabi-
>
> MAKEFLAGS += --no-print-directory
>
> .PHONY: all $(MAKECMDGOALS)
>
> all := $(filter-out all Makefile,$(MAKECMDGOALS))
>
> all:
>         $(MAKE) $(MAKEARGS) $(all) -f Makefile
>
> Makefile:;
>
> $(all) %/: all
>         @:
>
> Gr{oetje,eeting}s,
>
>                         Geert
>
> --
> Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
>
> In personal conversations with technical people, I call myself a hacker. But
> when I'm talking to journalists I just say "programmer" or something like that.
>                                 -- Linus Torvalds

  reply	other threads:[~2014-09-01  7:35 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-01  7:16 [PATCH v2 0/4] kconfig: store default ARCH in .config Konstantin Khlebnikov
2014-09-01  7:16 ` [PATCH v2 1/4] kconfig: save values imported from environment into config file Konstantin Khlebnikov
2014-09-01  7:16 ` [PATCH v2 2/4] scripts/config: add option for changing output for undefined options Konstantin Khlebnikov
2014-09-01  7:16 ` [PATCH v2 3/4] kconfig: get target architecture from config file Konstantin Khlebnikov
2014-09-01  7:16 ` [PATCH v2 4/4] kconfig: link CONFIG_CROSS_COMPILE with environment variable Konstantin Khlebnikov
2014-09-03 21:11   ` Paul Bolle
2014-09-04  5:23     ` Konstantin Khlebnikov
2014-09-01  7:24 ` [PATCH v2 0/4] kconfig: store default ARCH in .config Geert Uytterhoeven
2014-09-01  7:35   ` Konstantin Khlebnikov [this message]
2014-10-27 17:20 ` Konstantin Khlebnikov
2014-12-10 20:24   ` Paul Bolle

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=CALYGNiPUCFkx6sgLbCKrXbDVERhyaWyGJPp64fowBWpUALXqEQ@mail.gmail.com \
    --to=koct9i@gmail.com \
    --cc=geert@linux-m68k.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mmarek@suse.cz \
    --cc=pebolle@tiscali.nl \
    /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;
as well as URLs for NNTP newsgroup(s).