[CRIU] Re: [PATCH]

Kinsbursky Stanislav skinsbursky at openvz.org
Thu Apr 5 09:21:29 EDT 2012


05.04.2012 17:13, Cyrill Gorcunov пишет:
> On Thu, Apr 05, 2012 at 05:09:35PM +0400, Kinsbursky Stanislav wrote:
>> 05.04.2012 17:02, Cyrill Gorcunov пишет:
>>> Guys, while being mocking with root Makefile I found that
>>> filtering of goals is not going fine, ie "make clean" called
>>> twice in a row forced make to generate deps, which is useless
>>> of course.
>>>
>>> So the fix is below, please review. The idea is to generate
>>> deps IIF they are really needed, which are the cases
>>>
>>>   - one of *.o,*.s,*.i file is about to build
>>>   - one of general targets such as crtools,zdtm,test-legacy
>>>     acquired
>>>
>>> anything else (including clean,docs and such) should not
>>> generate deps, saving cpu cycles ;)
>> I'm really confused.
>> Git commit d1df3f60 did exactly the same. But this code part was
>> rewritten several times already (I missed these patches).
>> Or I'm missing something?
>>
> No, it didn't (it should actually :). There were a typo in
> commit, the variable should be referenced as $() clause.

Which variable?
Here is the patch:

commit af76a228edbbfffa231f9594f2152137a03df1a2

<snip>

diff --git a/Makefile b/Makefile
index 854dd65..af96112 100644
--- a/Makefile
+++ b/Makefile
@@ -182,4 +182,9 @@ cscope:
         $(Q) $(CSCOPE) -bkqu
  .PHONY: cscope

+no-blob-targets := tags clean cscope
+
+ifeq ($(filter-out no-blob-targets, $(MAKECMDGOALS)),)
  -include $(DEPS)
+endif
+


> And the second, it didn't take into account empty make goal.

No, it did.
IOW, deps were built for any target except "tags", "clean" and "cscope".

BTW, doesn't it is easier to use short list of targets, which doesn't require 
deps, instead of the long list, which does?

-- 
Best regards,
Stanislav Kinsbursky




More information about the CRIU mailing list