]>
Commit | Line | Data |
---|---|---|
04fd09d4 SL |
1 | From 419d53935ba421921c5a7f22ff30ff6d9caf8b17 Mon Sep 17 00:00:00 2001 |
2 | From: Masahiro Yamada <yamada.masahiro@socionext.com> | |
3 | Date: Fri, 15 Feb 2019 13:04:26 +0900 | |
4 | Subject: h8300: use cc-cross-prefix instead of hardcoding h8300-unknown-linux- | |
5 | ||
6 | [ Upstream commit fc2b47b55f17fd996f7a01975ce1c33c2f2513f6 ] | |
7 | ||
8 | It believe it is a bad idea to hardcode a specific compiler prefix | |
9 | that may or may not be installed on a user's system. It is annoying | |
10 | when testing features that should not require compilers at all. | |
11 | ||
12 | For example, mrproper, headers_install, etc. should work without | |
13 | any compiler. | |
14 | ||
15 | They look like follows on my machine. | |
16 | ||
17 | $ make ARCH=h8300 mrproper | |
18 | ./scripts/gcc-version.sh: line 26: h8300-unknown-linux-gcc: command not found | |
19 | ./scripts/gcc-version.sh: line 27: h8300-unknown-linux-gcc: command not found | |
20 | make: h8300-unknown-linux-gcc: Command not found | |
21 | make: h8300-unknown-linux-gcc: Command not found | |
22 | [ a bunch of the same error messages continue ] | |
23 | ||
24 | $ make ARCH=h8300 headers_install | |
25 | ./scripts/gcc-version.sh: line 26: h8300-unknown-linux-gcc: command not found | |
26 | ./scripts/gcc-version.sh: line 27: h8300-unknown-linux-gcc: command not found | |
27 | make: h8300-unknown-linux-gcc: Command not found | |
28 | HOSTCC scripts/basic/fixdep | |
29 | make: h8300-unknown-linux-gcc: Command not found | |
30 | WRAP arch/h8300/include/generated/uapi/asm/kvm_para.h | |
31 | [ snip ] | |
32 | ||
33 | The solution is to delete this line, or to use cc-cross-prefix like | |
34 | some architectures do. I chose the latter as a moderate fixup. | |
35 | ||
36 | I added an alternative 'h8300-linux-' because it is available at: | |
37 | ||
38 | https://mirrors.edge.kernel.org/pub/tools/crosstool/files/bin/x86_64/8.1.0/ | |
39 | ||
40 | Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> | |
41 | Signed-off-by: Sasha Levin <sashal@kernel.org> | |
42 | --- | |
43 | arch/h8300/Makefile | 2 +- | |
44 | 1 file changed, 1 insertion(+), 1 deletion(-) | |
45 | ||
46 | diff --git a/arch/h8300/Makefile b/arch/h8300/Makefile | |
47 | index e1c02ca230cb..073bba6f9f60 100644 | |
48 | --- a/arch/h8300/Makefile | |
49 | +++ b/arch/h8300/Makefile | |
50 | @@ -23,7 +23,7 @@ KBUILD_AFLAGS += $(aflags-y) | |
51 | LDFLAGS += $(ldflags-y) | |
52 | ||
53 | ifeq ($(CROSS_COMPILE),) | |
54 | -CROSS_COMPILE := h8300-unknown-linux- | |
55 | +CROSS_COMPILE := $(call cc-cross-prefix, h8300-unknown-linux- h8300-linux-) | |
56 | endif | |
57 | ||
58 | core-y += arch/$(ARCH)/kernel/ arch/$(ARCH)/mm/ | |
59 | -- | |
60 | 2.19.1 | |
61 |