On Fri, Jun 26, 2015 at 09:51:26AM +0200, Michal Privoznik wrote:
On 25.06.2015 23:09, Martin Kletzander wrote:
> On Wed, Jun 24, 2015 at 12:44:37PM +0200, Martin Kletzander wrote:
>> On Wed, Jun 24, 2015 at 08:53:21AM +0200, Peter Krempa wrote:
>>> On Tue, Jun 23, 2015 at 14:46:36 +0200, Martin Kletzander wrote:
>>>> On Tue, Jun 23, 2015 at 01:56:00PM +0200, Michal Privoznik wrote:
>>>>> The acl.html file includes aclperms.htmlinc which is generated.
>>>>> However, acl.html is generated too from acl.html.tmp. And in fact,
>>>>> this is the place where the aclperms file is needed. Fix the
>>>>> dependency in Makefile.
>>>>>
>>>>> Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
>>>>> ---
>>>>>
>>>>
>>>> ACK (I thought I ACKed the previous one with this modification, I
>>>> don't know why :).
>>>>
>>>>> diff to v1:
>>>>> - Fix the origin of the error
>>>>>
>>>>> docs/Makefile.am | 2 +-
>>>>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>>>>
>>>>> diff --git a/docs/Makefile.am b/docs/Makefile.am
>>>>> index b7b49cb..13dddf8 100644
>>>>> --- a/docs/Makefile.am
>>>>> +++ b/docs/Makefile.am
>>>>> @@ -163,7 +163,7 @@ EXTRA_DIST= \
>>>>> sitemap.html.in aclperms.htmlinc \
>>>>> todo.pl hvsupport.pl todo.cfg-example
>>>>>
>>>>> -acl.html:: $(srcdir)/aclperms.htmlinc
>>>>> +acl.html.tmp: $(srcdir)/aclperms.htmlinc
>>>
>>> Now after a build I get:
>>>
>>> $ git status
>>> On branch master
>>> Your branch is up-to-date with 'origin/master'.
>>> Untracked files:
>>> (use "git add <file>..." to include in what will be
committed)
>>>
>>> docs/acl.html.tmp
>>>
>>> nothing added to commit but untracked files present (use "git add"
to
>>> track)
>>
>> Aha! I guess that's why the double colon must be there, because it
>> sets one dependency and then there are bunch of other rules that I
>> haven't found the first time (using wildcards), like '%.html:
%.html.tmp'
>>
>> Weird that I don't see that after build...
>>
>
> Now I see that. And I probably figured out why. No double colon has
> anything to do with it. And it's probably the reason why there was
> acl.html specified instead of acl.html.tmp.
>
> the thing is that if you have:
>
> filename: another.file
>
> in the Makefile and you run make, it will keep that immediate file in
> place, but if the immediate file is specified using wildcards, e.g.:
>
> %name: another.file
>
> make will clean that up after using it. I couldn't find why it does
> that and whether that's documented behaviour, but it certainly is
> something I didn't expect. You can try that this is fixed by
> changing:
>
> acl.html.tmp: $(srcdir)/aclperms.htmlinc
>
> to
>
> %acl.html.tmp: $(srcdir)/aclperms.htmlinc
The other option would be to:
Which is exactly what I said in the last paragraph that you removed in
your reply. Since the serialization is not any problem here, ACK to
the diff below if you change GENERATED to something more descriptive
and lowercase (as all the other *_generated lists use in this file),
e.g. acl_generated.
diff --git a/docs/Makefile.am b/docs/Makefile.am
index 13dddf8..16eb137 100644
--- a/docs/Makefile.am
+++ b/docs/Makefile.am
@@ -163,7 +163,7 @@ EXTRA_DIST= \
sitemap.html.in aclperms.htmlinc \
todo.pl hvsupport.pl todo.cfg-example
-acl.html.tmp: $(srcdir)/aclperms.htmlinc
+GENERATED=aclperms.htmlinc
$(srcdir)/aclperms.htmlinc: $(top_srcdir)/src/access/viraccessperm.h \
$(srcdir)/genaclperms.pl Makefile.am
@@ -228,7 +228,7 @@ internals/%.html.tmp: internals/%.html.in subsite.xsl page.xsl
sitemap.html.in
$(top_srcdir)/docs/subsite.xsl $< > $@ \
|| { rm $@ && exit 1; }; fi
-%.html.tmp: %.html.in site.xsl page.xsl sitemap.html.in
+%.html.tmp: %.html.in site.xsl page.xsl sitemap.html.in $(GENERATED)
@if [ -x $(XSLTPROC) ] ; then \
echo "Generating $@"; \
name=`echo $@ | sed -e 's/.tmp//'`; \
Michal
--
libvir-list mailing list
libvir-list(a)redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list