All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michal Marek <mmarek@suse.cz>
To: Masahiro Yamada <yamada.m@jp.panasonic.com>,
	linux-kbuild@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH 3/3] kbuild: handle C=... and M=... after entering into build directory
Date: Wed, 01 Oct 2014 23:25:05 +0200	[thread overview]
Message-ID: <542C7131.1090902@suse.cz> (raw)
In-Reply-To: <1410260544-22657-4-git-send-email-yamada.m@jp.panasonic.com>

Dne 9.9.2014 13:02, Masahiro Yamada napsal(a):
>  sub-make: FORCE
>  	$(Q)$(MAKE) -C $(KBUILD_OUTPUT) KBUILD_SRC=$(CURDIR) \
> -	KBUILD_EXTMOD="$(KBUILD_EXTMOD)" -f $(CURDIR)/Makefile \
> -	$(filter-out _all sub-make,$(MAKECMDGOALS))
> +	-f $(CURDIR)/Makefile $(filter-out _all sub-make,$(MAKECMDGOALS))
>  
>  # Leave processing to above invocation of make
>  skip-makefile := 1
> @@ -188,6 +158,34 @@ ifeq ($(skip-makefile),)
>  # so that IDEs/editors are able to understand relative filenames.
>  MAKEFLAGS += --no-print-directory
>  
> +# Call a source code checker (by default, "sparse") as part of the
> +# C compilation.
> +#
> +# Use 'make C=1' to enable checking of only re-compiled files.
> +# Use 'make C=2' to enable checking of *all* source files, regardless
> +# of whether they are re-compiled or not.
> +#
> +# See the file "Documentation/sparse.txt" for more details, including
> +# where to get the "sparse" utility.
> +
> +ifeq ("$(origin C)", "command line")

I thought that the origin check would not work in the sub-make, because
the variables are part of the environment. But the sub-makes learn about
commandline variables from the MAKEFLAGS variable, so it works as
expected. Nice cleanup!

Michal

      parent reply	other threads:[~2014-10-01 21:25 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-09 11:02 [PATCH 0/3] kbuild: better implementation to display "Entering directory ..." Masahiro Yamada
2014-09-09 11:02 ` [PATCH 1/3] kbuild: fake the "Entering directory ..." message more simply Masahiro Yamada
2014-09-09 16:28   ` Peter Foley
2014-10-01 21:21   ` Michal Marek
2014-09-09 11:02 ` [PATCH 2/3] kbuild: use $(Q) for sub-make target Masahiro Yamada
2014-09-09 16:25   ` Peter Foley
2014-09-09 11:02 ` [PATCH 3/3] kbuild: handle C=... and M=... after entering into build directory Masahiro Yamada
2014-09-09 16:27   ` Peter Foley
2014-10-01 21:25   ` Michal Marek [this message]

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=542C7131.1090902@suse.cz \
    --to=mmarek@suse.cz \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=yamada.m@jp.panasonic.com \
    /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.