lkml.org 
[lkml]   [2016]   [Jun]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 2/6] scripts/gdb: rebuild constants.py on dependancy change
Date
The autogenerated constants.py file was only being built on the initial
call, and if the constants.py.in file changed. As we are utilising the
CPP hooks, we can successfully use the call if_changed_dep rules to
determine when to rebuild the file based on it's inclusions.

Reported-by: Jan Kiszka <jan.kiszka@web.de>
Signed-off-by: Kieran Bingham <kieran@bingham.xyz>
---
scripts/gdb/linux/Makefile | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/scripts/gdb/linux/Makefile b/scripts/gdb/linux/Makefile
index 7a33556db4e1..8b00031f5349 100644
--- a/scripts/gdb/linux/Makefile
+++ b/scripts/gdb/linux/Makefile
@@ -13,8 +13,9 @@ quiet_cmd_gen_constants_py = GEN $@
$(CPP) -E -x c -P $(c_flags) $< > $@ ;\
sed -i '1,/<!-- end-c-headers -->/d;' $@

-$(obj)/constants.py: $(SRCTREE)/$(obj)/constants.py.in
- $(call if_changed,gen_constants_py)
+targets += constants.py
+$(obj)/constants.py: $(SRCTREE)/$(obj)/constants.py.in FORCE
+ $(call if_changed_dep,gen_constants_py)

build_constants_py: $(obj)/constants.py
@:
--
2.7.4
\
 
 \ /
  Last update: 2016-06-28 17:41    [W:0.363 / U:0.616 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site