diff options
author | Masahiro Yamada <yamada.masahiro@socionext.com> | 2017-06-24 21:53:08 -0400 |
---|---|---|
committer | Masahiro Yamada <yamada.masahiro@socionext.com> | 2017-06-29 19:59:55 -0400 |
commit | 44ea9948e93556a501c6de50b0a77042a0ba077f (patch) | |
tree | 2ae45a5a7c417b98d59dd0b394b4d8a78cffd701 /arch/tile | |
parent | 9289ea7f952b14ef2627edc49f9508234952a85e (diff) |
tile: fix dependency and .*.cmd inclusion for incremental build
Build targets using if_changed(_rule) must depend on FORCE so that
they are evaluated every time.
In order to include .*.cmd files correctly, build targets added to
"targets" must not be prefixed with $(obj)/ because it is done by
scripts/Makefile.lib .
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'arch/tile')
-rw-r--r-- | arch/tile/kernel/vdso/Makefile | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/arch/tile/kernel/vdso/Makefile b/arch/tile/kernel/vdso/Makefile index c54fff37b5ff..cf162a23e866 100644 --- a/arch/tile/kernel/vdso/Makefile +++ b/arch/tile/kernel/vdso/Makefile | |||
@@ -42,10 +42,9 @@ $(obj)/vdso.o: $(obj)/vdso.so | |||
42 | 42 | ||
43 | # link rule for the .so file, .lds has to be first | 43 | # link rule for the .so file, .lds has to be first |
44 | SYSCFLAGS_vdso.so.dbg = $(c_flags) | 44 | SYSCFLAGS_vdso.so.dbg = $(c_flags) |
45 | $(obj)/vdso.so.dbg: $(src)/vdso.lds $(obj-vdso) | 45 | $(obj)/vdso.so.dbg: $(src)/vdso.lds $(obj-vdso) FORCE |
46 | $(call if_changed,vdsold) | 46 | $(call if_changed,vdsold) |
47 | 47 | ||
48 | |||
49 | # We also create a special relocatable object that should mirror the symbol | 48 | # We also create a special relocatable object that should mirror the symbol |
50 | # table and layout of the linked DSO. With ld -R we can then refer to | 49 | # table and layout of the linked DSO. With ld -R we can then refer to |
51 | # these symbols in the kernel code rather than hand-coded addresses. | 50 | # these symbols in the kernel code rather than hand-coded addresses. |
@@ -96,17 +95,17 @@ KBUILD_CFLAGS_32 := $(filter-out -m64,$(KBUILD_CFLAGS)) | |||
96 | KBUILD_CFLAGS_32 += -m32 -fPIC -shared | 95 | KBUILD_CFLAGS_32 += -m32 -fPIC -shared |
97 | 96 | ||
98 | obj-vdso32 = $(patsubst %, v%32.o, $(vdso-syms)) | 97 | obj-vdso32 = $(patsubst %, v%32.o, $(vdso-syms)) |
99 | obj-vdso32 := $(addprefix $(obj)/, $(obj-vdso32)) | ||
100 | 98 | ||
101 | targets += $(obj-vdso32) vdso32.so vdso32.so.dbg | 99 | targets += $(obj-vdso32) vdso32.so vdso32.so.dbg |
100 | obj-vdso32 := $(addprefix $(obj)/, $(obj-vdso32)) | ||
102 | 101 | ||
103 | $(obj-vdso32:%=%): KBUILD_AFLAGS = $(KBUILD_AFLAGS_32) | 102 | $(obj-vdso32:%=%): KBUILD_AFLAGS = $(KBUILD_AFLAGS_32) |
104 | $(obj-vdso32:%=%): KBUILD_CFLAGS = $(KBUILD_CFLAGS_32) | 103 | $(obj-vdso32:%=%): KBUILD_CFLAGS = $(KBUILD_CFLAGS_32) |
105 | 104 | ||
106 | $(obj)/vgettimeofday32.o: $(obj)/vgettimeofday.c | 105 | $(obj)/vgettimeofday32.o: $(obj)/vgettimeofday.c FORCE |
107 | $(call if_changed_rule,cc_o_c) | 106 | $(call if_changed_rule,cc_o_c) |
108 | 107 | ||
109 | $(obj)/vrt_sigreturn32.o: $(obj)/vrt_sigreturn.S | 108 | $(obj)/vrt_sigreturn32.o: $(obj)/vrt_sigreturn.S FORCE |
110 | $(call if_changed,as_o_S) | 109 | $(call if_changed,as_o_S) |
111 | 110 | ||
112 | # Force dependency | 111 | # Force dependency |
@@ -114,5 +113,5 @@ $(obj)/vdso32.o: $(obj)/vdso32.so | |||
114 | 113 | ||
115 | SYSCFLAGS_vdso32.so.dbg = -m32 -shared -s -Wl,-soname=linux-vdso32.so.1 \ | 114 | SYSCFLAGS_vdso32.so.dbg = -m32 -shared -s -Wl,-soname=linux-vdso32.so.1 \ |
116 | $(call cc-ldoption, -Wl$(comma)--hash-style=both) | 115 | $(call cc-ldoption, -Wl$(comma)--hash-style=both) |
117 | $(obj)/vdso32.so.dbg: $(src)/vdso.lds $(obj-vdso32) | 116 | $(obj)/vdso32.so.dbg: $(src)/vdso.lds $(obj-vdso32) FORCE |
118 | $(call if_changed,vdsold) | 117 | $(call if_changed,vdsold) |