$(obj)/compat/.xlat/%.h: $(obj)/compat/%.h $(obj)/compat/.xlat/%.lst $(srctree)/tools/compat-xlat-header.py FORCE
$(call if_changed,xlat_headers)
-quiet_cmd_xlat_lst = GEN $@
-cmd_xlat_lst = \
- grep -v '^[[:blank:]]*$(pound)' $< | sed -ne 's,@arch@,$(compat-arch-y),g' -re 's,[[:blank:]]+$*\.h[[:blank:]]*$$,,p' >$@.new; \
- $(call move-if-changed,$@.new,$@)
+filechk_xlat_lst = \
+ sed -ne '/^[[:blank:]]*$(pound)/d' -e 's,@arch@,$(compat-arch-y),g' -re 's,[[:blank:]]+$*\.h[[:blank:]]*$$,,p' $<
.PRECIOUS: $(obj)/compat/.xlat/%.lst
targets += $(patsubst compat/%.h, compat/.xlat/%.lst, $(headers-y))
$(obj)/compat/.xlat/%.lst: $(srcdir)/xlat.lst FORCE
- $(call if_changed,xlat_lst)
+ $(call filechk,xlat_lst)
xlat-y := $(shell sed -ne 's,@arch@,$(compat-arch-y),g' -re 's,^[?!][[:blank:]]+[^[:blank:]]+[[:blank:]]+,,p' $(srcdir)/xlat.lst | uniq)
xlat-y := $(filter $(patsubst compat/%,%,$(headers-y)),$(xlat-y))