linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] kbuild: make samples depend on headers_install
@ 2016-07-04 14:39 Arnd Bergmann
  2016-07-22 11:59 ` Michal Marek
  0 siblings, 1 reply; 2+ messages in thread
From: Arnd Bergmann @ 2016-07-04 14:39 UTC (permalink / raw)
  To: Michal Marek, Michal Marek
  Cc: linux-kbuild, Peter Foley, Jiri Kosina, Arnd Bergmann, linux-kernel

Olof's build test setup keeps failing to compile arm64 kernels
because of a toolchain that uses outdated kernel headers:

/work/build/batch/samples/seccomp/bpf-fancy.c:13:27: fatal error: linux/seccomp.h: No such file or directory

This is of course something he could change, but it also indicates
that others may run into the same problem. Running 'make headers_install'
avoids the issue by ensuring that the kernel headers are put into
the $(objdir)/usr/include path before we build the samples.

The same problem happened for the Documentation build in the
past and was fixed up with commit 8e2faea877eb ("Make Documenation
depend on headers_install"). This adds an identical Makefile dependency
for the samples/ subdirectory.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index ec355167cf36..4a44055e3433 100644
--- a/Makefile
+++ b/Makefile
@@ -1633,7 +1633,7 @@ endif
 	$(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1) \
 	$(build)=$(build-dir)
 # Make sure the latest headers are built for Documentation
-Documentation/: headers_install
+Documentation/ samples/: headers_install
 %/: prepare scripts FORCE
 	$(cmd_crmodverdir)
 	$(Q)$(MAKE) KBUILD_MODULES=$(if $(CONFIG_MODULES),1) \
-- 
2.9.0

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] kbuild: make samples depend on headers_install
  2016-07-04 14:39 [PATCH] kbuild: make samples depend on headers_install Arnd Bergmann
@ 2016-07-22 11:59 ` Michal Marek
  0 siblings, 0 replies; 2+ messages in thread
From: Michal Marek @ 2016-07-22 11:59 UTC (permalink / raw)
  To: Arnd Bergmann; +Cc: linux-kbuild, Peter Foley, Jiri Kosina, linux-kernel

On 2016-07-04 16:39, Arnd Bergmann wrote:
> Olof's build test setup keeps failing to compile arm64 kernels
> because of a toolchain that uses outdated kernel headers:
> 
> /work/build/batch/samples/seccomp/bpf-fancy.c:13:27: fatal error: linux/seccomp.h: No such file or directory
> 
> This is of course something he could change, but it also indicates
> that others may run into the same problem. Running 'make headers_install'
> avoids the issue by ensuring that the kernel headers are put into
> the $(objdir)/usr/include path before we build the samples.
> 
> The same problem happened for the Documentation build in the
> past and was fixed up with commit 8e2faea877eb ("Make Documenation
> depend on headers_install"). This adds an identical Makefile dependency
> for the samples/ subdirectory.
> 
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
>  Makefile | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied to kbuild.git#kbuild.

Michal

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-07-22 11:59 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-04 14:39 [PATCH] kbuild: make samples depend on headers_install Arnd Bergmann
2016-07-22 11:59 ` Michal Marek

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).