mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-07-18 09:05:10 +00:00
GNU make tries to rebuild any makefiles it uses. While in general it's a good idea (and it is used e.g. in autoconf-based builds), in our case it is not necessary, as all the makefiles are static. More to say, as we have a few "match anything" rules for subdirectories, Makefiles in these subdirs are also matching these rules, which leads to excessive (re)building while a particular makefile is needed. Protect such Makefiles with explicit (or pattern) rules, so make knows it should do nothing to rebuild those. Signed-off-by: Kir Kolyshkin <kir@openvz.org> Reviewed-by: Dmitry Safonov <dsafonov@virtuozzo.com> Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
21 lines
452 B
Makefile
21 lines
452 B
Makefile
all-y += libpy-images rpc_pb2.py
|
|
|
|
.PHONY: .FORCE
|
|
|
|
$(obj)/images/Makefile: ;
|
|
$(obj)/images/%: .FORCE
|
|
$(Q) $(MAKE) $(build)=$(obj)/images $@
|
|
|
|
libpy-images:
|
|
$(Q) $(MAKE) $(build)=$(obj)/images all
|
|
.PHONY: libpy-images
|
|
|
|
rpc_pb2.py:
|
|
$(Q) protoc -I=images/ --python_out=$(obj) images/$(@:_pb2.py=.proto)
|
|
|
|
cleanup-y += $(addprefix $(obj)/,rpc_pb2.py *.pyc)
|
|
|
|
clean-lib-py:
|
|
$(Q) $(MAKE) $(build)=$(obj)/images clean
|
|
.PHONY: clean-lib-py
|
|
clean: clean-lib-py
|