OSDN Git Service

tools build: Fix cross compile build
authorJiri Olsa <jolsa@redhat.com>
Tue, 13 Oct 2015 12:43:58 +0000 (14:43 +0200)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 13 Oct 2015 14:59:43 +0000 (11:59 -0300)
He Kuang the new fixdep tool breaks cross compiling. The reason is it
wouldn't get compiled under host arch, but under cross arch and failed
to run.

We need to add support for host side tools build, meanwhile disabling
fixdep usage for cross arch builds.

Reported-by: He Kuang <hekuang@huawei.com>
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/20151013124358.GB9467@krava.brq.redhat.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/build/Makefile.include

index 6572bb0..4e09ad6 100644 (file)
@@ -1,6 +1,10 @@
 build := -f $(srctree)/tools/build/Makefile.build dir=. obj
 
+ifdef CROSS_COMPILE
+fixdep:
+else
 fixdep:
        $(Q)$(MAKE) -C $(srctree)/tools/build fixdep
+endif
 
 .PHONY: fixdep