All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] docs: make 'gmake dist-docs' work
@ 2013-04-22 11:55 Egger Christoph
  2013-04-24 11:48 ` Ian Campbell
  0 siblings, 1 reply; 6+ messages in thread
From: Egger Christoph @ 2013-04-22 11:55 UTC (permalink / raw)
  To: xen-devel; +Cc: Ian Campbell

[-- Attachment #1: Type: text/plain, Size: 1606 bytes --]

doc: Makefile fixes
    
- use correct pathes (make gmake dist-docs from toplevel directory work)
- use tools as found by configure (perl)
    
Signed-off-by: Christoph Egger <chegger@amazon.de>
diff --git a/docs/Makefile b/docs/Makefile
index 5f319a1..d247dea 100644
--- a/docs/Makefile
+++ b/docs/Makefile
@@ -1,5 +1,3 @@
-#!/usr/bin/make -f
-
 XEN_ROOT=$(CURDIR)/..
 include $(XEN_ROOT)/Config.mk
 -include $(XEN_ROOT)/config/Docs.mk
@@ -75,7 +73,7 @@ clean:
 
 .PHONY: distclean
 distclean: clean
-	rm -rf ../config/Docs.mk config.log config.status config.cache \
+	rm -rf $(XEN_ROOT)/config/Docs.mk config.log config.status config.cache \
 		autom4te.cache
 
 .PHONY: install
@@ -88,8 +86,8 @@ install: all
 	cp -R man5 $(DESTDIR)$(MANDIR)
 	[ ! -d html ] || cp -R html $(DESTDIR)$(DOCDIR)
 
-html/index.html: $(DOC_HTML) ./gen-html-index INDEX
-	perl -w -- ./gen-html-index -i INDEX html $(DOC_HTML)
+html/index.html: $(DOC_HTML) $(CURDIR)/gen-html-index INDEX
+	$(PERL) -w -- $(CURDIR)/gen-html-index -i INDEX html $(DOC_HTML)
 
 html/%.html: %.markdown
 	$(INSTALL_DIR) $(@D)
@@ -123,13 +121,13 @@ else
 	@echo "pod2html not installed; skipping $<."
 endif
 
-html/hypercall/index.html: ./xen-headers
+html/hypercall/index.html: $(CURDIR)/xen-headers
 	rm -rf $(@D)
 	$(INSTALL_DIR) $(@D)
-	./xen-headers -O $(@D) \
+	$(PERL) -w $(CURDIR)/xen-headers -O $(@D) \
 		-T 'arch-x86_64 - Xen public headers' \
 		-X arch-ia64 -X arch-x86_32 -X xen-x86_32 -X arch-arm \
-		../xen include/public include/xen/errno.h
+		$(XEN_ROOT)/xen include/public include/xen/errno.h
 
 -include html/hypercall/.deps
 

[-- Attachment #2: patch_docs.diff --]
[-- Type: text/plain, Size: 1754 bytes --]

commit eab28e737b01fdbe929a66a6f1c55a3b89bc2fb7
Author: Christoph Egger <chegger@amazon.de>
Date:   Thu Apr 4 13:30:30 2013 +0000

    doc: Makefile fixes
    
    - use correct pathes (make gmake dist-docs from toplevel directory work)
    - use tools as found by configure (perl)
    
    Signed-off-by: Christoph Egger <chegger@amazon.de>

diff --git a/docs/Makefile b/docs/Makefile
index 5f319a1..d247dea 100644
--- a/docs/Makefile
+++ b/docs/Makefile
@@ -1,5 +1,3 @@
-#!/usr/bin/make -f
-
 XEN_ROOT=$(CURDIR)/..
 include $(XEN_ROOT)/Config.mk
 -include $(XEN_ROOT)/config/Docs.mk
@@ -75,7 +73,7 @@ clean:
 
 .PHONY: distclean
 distclean: clean
-	rm -rf ../config/Docs.mk config.log config.status config.cache \
+	rm -rf $(XEN_ROOT)/config/Docs.mk config.log config.status config.cache \
 		autom4te.cache
 
 .PHONY: install
@@ -88,8 +86,8 @@ install: all
 	cp -R man5 $(DESTDIR)$(MANDIR)
 	[ ! -d html ] || cp -R html $(DESTDIR)$(DOCDIR)
 
-html/index.html: $(DOC_HTML) ./gen-html-index INDEX
-	perl -w -- ./gen-html-index -i INDEX html $(DOC_HTML)
+html/index.html: $(DOC_HTML) $(CURDIR)/gen-html-index INDEX
+	$(PERL) -w -- $(CURDIR)/gen-html-index -i INDEX html $(DOC_HTML)
 
 html/%.html: %.markdown
 	$(INSTALL_DIR) $(@D)
@@ -123,13 +121,13 @@ else
 	@echo "pod2html not installed; skipping $<."
 endif
 
-html/hypercall/index.html: ./xen-headers
+html/hypercall/index.html: $(CURDIR)/xen-headers
 	rm -rf $(@D)
 	$(INSTALL_DIR) $(@D)
-	./xen-headers -O $(@D) \
+	$(PERL) -w $(CURDIR)/xen-headers -O $(@D) \
 		-T 'arch-x86_64 - Xen public headers' \
 		-X arch-ia64 -X arch-x86_32 -X xen-x86_32 -X arch-arm \
-		../xen include/public include/xen/errno.h
+		$(XEN_ROOT)/xen include/public include/xen/errno.h
 
 -include html/hypercall/.deps
 

[-- Attachment #3: Type: text/plain, Size: 126 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH] docs: make 'gmake dist-docs' work
  2013-04-22 11:55 [PATCH] docs: make 'gmake dist-docs' work Egger Christoph
@ 2013-04-24 11:48 ` Ian Campbell
  2013-04-24 12:54   ` Christoph Egger
  0 siblings, 1 reply; 6+ messages in thread
From: Ian Campbell @ 2013-04-24 11:48 UTC (permalink / raw)
  To: Egger Christoph; +Cc: xen-devel

On Mon, 2013-04-22 at 12:55 +0100, Egger Christoph wrote:
> doc: Makefile fixes
>     
> - use correct pathes (make gmake dist-docs from toplevel directory work)
> - use tools as found by configure (perl)

Did you test this? Because it causes the hypercall docs to not be built
or installed for me.
        w /local/scratch/ianc/devel/committer.git/docs/xen-headers -O html/hypercall \
        		-T 'arch-x86_64 - Xen public headers' \
        		-X arch-ia64 -X arch-x86_32 -X xen-x86_32 -X arch-arm \
        		/local/scratch/ianc/devel/committer.git/docs/../xen include/public include/xen/errno.h
        w: invalid option -- 'O'
        
        Usage:
         w [options]
        
        Options:
         -h, --no-header     do not print header
         -u, --no-current    ignore current process username
         -s, --short         short format
         -f, --from          show remote hostname field
         -o, --old-style     old style output
        
             --help     display this help and exit
         -V, --version  output version information and exit
        
        For more details see w(1).
        make[1]: [html/hypercall/index.html] Error 1 (ignored)

$(PERL) is defined in config/Tools.mk but docs/Makefile by design only
includes config/Docs.mk. I think you need to check for perl in
docs/configure.ac as well and propagate the result into config/Docs.mk
        AC_ARG_VAR([PERL], [Path to Perl parser])
        AX_PATH_PROG_OR_FAIL([PERL], [perl])
        
The reason for checking twice is to support people who only want to
build the docs and not the tools and therefore only run configure in the
subdirectory.

Ian.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] docs: make 'gmake dist-docs' work
  2013-04-24 11:48 ` Ian Campbell
@ 2013-04-24 12:54   ` Christoph Egger
  2013-04-24 13:02     ` Ian Campbell
  0 siblings, 1 reply; 6+ messages in thread
From: Christoph Egger @ 2013-04-24 12:54 UTC (permalink / raw)
  To: Ian Campbell; +Cc: xen-devel

On 24.04.13 13:48, Ian Campbell wrote:
> On Mon, 2013-04-22 at 12:55 +0100, Egger Christoph wrote:
>> doc: Makefile fixes
>>     
>> - use correct pathes (make gmake dist-docs from toplevel directory work)
>> - use tools as found by configure (perl)
> 
> Did you test this?

Yes.

[...]

> $(PERL) is defined in config/Tools.mk but docs/Makefile by design only
> includes config/Docs.mk. I think you need to check for perl in
> docs/configure.ac as well and propagate the result into config/Docs.mk
>         AC_ARG_VAR([PERL], [Path to Perl parser])
>         AX_PATH_PROG_OR_FAIL([PERL], [perl])

docs/Makefile also includes Config.mk which in turn includes
config/Tools.mk.
>From there $(PERL) is defined and makes this patch work.

Christoph

> The reason for checking twice is to support people who only want to
> build the docs and not the tools and therefore only run configure in the
> subdirectory.
> 
> Ian.
> 
> 

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] docs: make 'gmake dist-docs' work
  2013-04-24 12:54   ` Christoph Egger
@ 2013-04-24 13:02     ` Ian Campbell
  2013-05-10 12:06       ` Christoph Egger
  0 siblings, 1 reply; 6+ messages in thread
From: Ian Campbell @ 2013-04-24 13:02 UTC (permalink / raw)
  To: Christoph Egger; +Cc: xen-devel

On Wed, 2013-04-24 at 13:54 +0100, Christoph Egger wrote:
> On 24.04.13 13:48, Ian Campbell wrote:
> > On Mon, 2013-04-22 at 12:55 +0100, Egger Christoph wrote:
> >> doc: Makefile fixes
> >>     
> >> - use correct pathes (make gmake dist-docs from toplevel directory work)
> >> - use tools as found by configure (perl)
> > 
> > Did you test this?
> 
> Yes.

Against unstable?

> [...]
> 
> > $(PERL) is defined in config/Tools.mk but docs/Makefile by design only
> > includes config/Docs.mk. I think you need to check for perl in
> > docs/configure.ac as well and propagate the result into config/Docs.mk
> >         AC_ARG_VAR([PERL], [Path to Perl parser])
> >         AX_PATH_PROG_OR_FAIL([PERL], [perl])
> 
> docs/Makefile also includes Config.mk which in turn includes
> config/Tools.mk.

Not here it doesn't:
        $ git show --oneline
        0a97f68 install qemu into the location specified via configure --prefix.
        ...
        $ grep Tools.mk Config.mk 
        $
        $ grep include Config.mk 
        -include $(XEN_ROOT)/.config
        include $(XEN_ROOT)/config/$(XEN_OS).mk
        include $(XEN_ROOT)/config/$(XEN_TARGET_ARCH).mk
        EXTRA_INCLUDES += $(EXTRA_PREFIX)/include
        $
        $ rgrep -l Tools.mk *
        tools/config.status
        tools/Makefile
        tools/Rules.mk
        tools/configure.ac
        tools/config.log
        tools/configure

Perhaps you have some other local patches?

Ian.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] docs: make 'gmake dist-docs' work
  2013-04-24 13:02     ` Ian Campbell
@ 2013-05-10 12:06       ` Christoph Egger
  2013-05-10 14:00         ` Christoph Egger
  0 siblings, 1 reply; 6+ messages in thread
From: Christoph Egger @ 2013-05-10 12:06 UTC (permalink / raw)
  To: Ian Campbell; +Cc: xen-devel

On 24.04.13 15:02, Ian Campbell wrote:
> On Wed, 2013-04-24 at 13:54 +0100, Christoph Egger wrote:
>> On 24.04.13 13:48, Ian Campbell wrote:
>>> On Mon, 2013-04-22 at 12:55 +0100, Egger Christoph wrote:
>>>> doc: Makefile fixes
>>>>     
>>>> - use correct pathes (make gmake dist-docs from toplevel directory work)
>>>> - use tools as found by configure (perl)
>>>
>>> Did you test this?
>>
>> Yes.
> 
> Against unstable?

yes.

> 
>> [...]
>>
>>> $(PERL) is defined in config/Tools.mk but docs/Makefile by design only
>>> includes config/Docs.mk. I think you need to check for perl in
>>> docs/configure.ac as well and propagate the result into config/Docs.mk
>>>         AC_ARG_VAR([PERL], [Path to Perl parser])
>>>         AX_PATH_PROG_OR_FAIL([PERL], [perl])
>>
>> docs/Makefile also includes Config.mk which in turn includes
>> config/Tools.mk.
> 
> Not here it doesn't:
>         $ git show --oneline
>         0a97f68 install qemu into the location specified via configure --prefix.
>         ...
>         $ grep Tools.mk Config.mk 
>         $
>         $ grep include Config.mk 
>         -include $(XEN_ROOT)/.config
>         include $(XEN_ROOT)/config/$(XEN_OS).mk
>         include $(XEN_ROOT)/config/$(XEN_TARGET_ARCH).mk
>         EXTRA_INCLUDES += $(EXTRA_PREFIX)/include
>         $
>         $ rgrep -l Tools.mk *
>         tools/config.status
>         tools/Makefile
>         tools/Rules.mk
>         tools/configure.ac
>         tools/config.log
>         tools/configure
> 
> Perhaps you have some other local patches?

Yes. Just submitted with subject
'[Xen-devel] [PATCH] Make sure to use tools as found by configure'.

Christoph

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] docs: make 'gmake dist-docs' work
  2013-05-10 12:06       ` Christoph Egger
@ 2013-05-10 14:00         ` Christoph Egger
  0 siblings, 0 replies; 6+ messages in thread
From: Christoph Egger @ 2013-05-10 14:00 UTC (permalink / raw)
  To: Ian Campbell; +Cc: xen-devel

On 10.05.13 14:06, Christoph Egger wrote:
> On 24.04.13 15:02, Ian Campbell wrote:
>> On Wed, 2013-04-24 at 13:54 +0100, Christoph Egger wrote:
>>> On 24.04.13 13:48, Ian Campbell wrote:
>>>> On Mon, 2013-04-22 at 12:55 +0100, Egger Christoph wrote:
>>>>> doc: Makefile fixes
>>>>>     
>>>>> - use correct pathes (make gmake dist-docs from toplevel directory work)
>>>>> - use tools as found by configure (perl)
>>>>
>>>> Did you test this?
>>>
>>> Yes.
>>
>> Against unstable?
> 
> yes.
> 
>>
>>> [...]
>>>
>>>> $(PERL) is defined in config/Tools.mk but docs/Makefile by design only
>>>> includes config/Docs.mk. I think you need to check for perl in
>>>> docs/configure.ac as well and propagate the result into config/Docs.mk
>>>>         AC_ARG_VAR([PERL], [Path to Perl parser])
>>>>         AX_PATH_PROG_OR_FAIL([PERL], [perl])
>>>
>>> docs/Makefile also includes Config.mk which in turn includes
>>> config/Tools.mk.
>>
>> Not here it doesn't:
>>         $ git show --oneline
>>         0a97f68 install qemu into the location specified via configure --prefix.
>>         ...
>>         $ grep Tools.mk Config.mk 
>>         $
>>         $ grep include Config.mk 
>>         -include $(XEN_ROOT)/.config
>>         include $(XEN_ROOT)/config/$(XEN_OS).mk
>>         include $(XEN_ROOT)/config/$(XEN_TARGET_ARCH).mk
>>         EXTRA_INCLUDES += $(EXTRA_PREFIX)/include
>>         $
>>         $ rgrep -l Tools.mk *
>>         tools/config.status
>>         tools/Makefile
>>         tools/Rules.mk
>>         tools/configure.ac
>>         tools/config.log
>>         tools/configure
>>
>> Perhaps you have some other local patches?
> 
> Yes. Just submitted with subject
> '[Xen-devel] [PATCH] Make sure to use tools as found by configure'.

I send a new version.

Christoph

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2013-05-10 14:00 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-22 11:55 [PATCH] docs: make 'gmake dist-docs' work Egger Christoph
2013-04-24 11:48 ` Ian Campbell
2013-04-24 12:54   ` Christoph Egger
2013-04-24 13:02     ` Ian Campbell
2013-05-10 12:06       ` Christoph Egger
2013-05-10 14:00         ` Christoph Egger

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.