docs: make 'gmake dist-docs' work
PATCH v2 1/1 docs: make 'gmake dist-docs' work
doc: buildsystem fixes
- use correct pathes (make gmake dist-docs from toplevel directory work)
- configure detects perl as tools/configure does
config/Docs.mk.in +1 -0
@@ -11,3 +11,4 @@ POD2HTML := @POD2HTML@ POD2TEXT := @POD2TEXT@ MARKDOWN := @MARKDOWN@ +PERL := @PERL@
docs/Makefile +6 -8
@@ -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 @@ .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 @@ 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 @@ @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-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
docs/configure.ac +4 -0
@@ -10,6 +10,7 @@ # M4 Macro includes m4_include([../m4/docs_tool.m4]) +m4_include([../m4/path_or_fail.m4]) AX_DOCS_TOOL_PROG([FIG2DEV], [fig2dev]) AX_DOCS_TOOL_PROG([POD2MAN], [pod2man])
@@ -17,4 +18,7 @@ AX_DOCS_TOOL_PROG([POD2TEXT], [pod2text]) AX_DOCS_TOOL_PROGS([MARKDOWN], [markdown], [markdown markdown_py]) +AC_ARG_VAR([PERL], [Path to Perl parser]) +AX_PATH_PROG_OR_FAIL([PERL], [perl]) + AC_OUTPUT()
doc: buildsystem fixes
- use correct pathes (make gmake dist-docs from toplevel directory work)
- configure detects perl as tools/configure does
config/Docs.mk.in +1 -0
@@ -11,3 +11,4 @@ POD2HTML := @POD2HTML@ POD2TEXT := @POD2TEXT@ MARKDOWN := @MARKDOWN@ +PERL := @PERL@
docs/Makefile +6 -8
@@ -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 @@ .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 @@ 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 @@ @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-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
docs/configure.ac +4 -0
@@ -10,6 +10,7 @@ # M4 Macro includes m4_include([../m4/docs_tool.m4]) +m4_include([../m4/path_or_fail.m4]) AX_DOCS_TOOL_PROG([FIG2DEV], [fig2dev]) AX_DOCS_TOOL_PROG([POD2MAN], [pod2man])
@@ -17,4 +18,7 @@ AX_DOCS_TOOL_PROG([POD2TEXT], [pod2text]) AX_DOCS_TOOL_PROGS([MARKDOWN], [markdown], [markdown markdown_py]) +AC_ARG_VAR([PERL], [Path to Perl parser]) +AX_PATH_PROG_OR_FAIL([PERL], [perl]) + AC_OUTPUT()
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Quoted 3 lines · Christoph Egger
doc: buildsystem fixes
- use correct pathes (make gmake dist-docs from toplevel directory work)
This ("make dist-docs") seems to work for me, how does it fail for you?
Quoted 4 lines
- configure detects perl as
tools/configuredoesSigned-off-by Christoph Egger <[email protected]>Reviewed-by Matthew Wilson <[email protected]>
Regardless of the above this patch is in itself correct so:
Acked + applied.
Quoted 6 lines · Ian Campbell
Quoted 3 lines · Christoph Egger
doc: buildsystem fixes
- use correct pathes (make gmake dist-docs from toplevel directory work)
This ("make dist-docs") seems to work for me, how does it fail for you?
On the toplevel directory '../xen' and '../config' point to non-existent directories.
On the toplevel directory './gen-html-index' does not exist.
Quoted 7 lines
Quoted 4 lines
- configure detects perl as
tools/configuredoesSigned-off-by Christoph Egger <[email protected]>Reviewed-by Matthew Wilson <[email protected]>Regardless of the above this patch is in itself correct so:
Acked + applied.
Thanks.
Christoph
Quoted 11 lines · Christoph Egger
Quoted 6 lines · Ian Campbell
Quoted 3 lines · Christoph Egger
doc: buildsystem fixes
- use correct pathes (make gmake dist-docs from toplevel directory work)
This ("make dist-docs") seems to work for me, how does it fail for you?
On the toplevel directory '../xen' and '../config' point to non-existent directories.
On the toplevel directory './gen-html-index' does not exist.
I'm confused. By toplevel you mean "xen.git" and not "xen.git/docs", right?
make dist-docs turns into "make -C docs install" (with DESTDIR set) so at the time ../xen or ../config are evaluated you should be in xen.git/docs.
Or are you saying that you are extracting the docs subdir out to elsewhere? Perhaps you are doing an out of tree build or something else complex?
I'm not suggesting your changes are wrong. I'd just like to understand the breakage...
Ian.
Quoted 7 lines · Ian Campbell
Quoted 6 lines · Christoph Egger
Quoted 5 lines · Ian Campbell
Quoted 3 lines · Christoph Egger
doc: buildsystem fixes
- use correct pathes (make gmake dist-docs from toplevel directory work)
Quoted 8 lines
Quoted 5 lines
Quoted 1 line
This ("make dist-docs") seems to work for me, how does it fail for you?
On the toplevel directory '../xen' and '../config' point to non-existent directories.
On the toplevel directory './gen-html-index' does not exist.I'm confused. By toplevel you mean "xen.git" and not "xen.git/docs", right?
Yes.
Quoted 7 lines
make dist-docs turns into "make -C docs install" (with DESTDIR set) so at the time ../xen or ../config are evaluated you should be in xen.git/docs.
Or are you saying that you are extracting the docs subdir out to elsewhere? Perhaps you are doing an out of tree build or something else complex?
No.
My build procedure is:
- run configure
- gmake -jN dist-xen
- gmake -jN dist-tools
- gmake dist-docs
Quoted 2 lines
I'm not suggesting your changes are wrong. I'd just like to understand the breakage...
I retried w/o my patch to get the error message:
xen.git$ gmake dist-docs
[...]
./xen-headers -O html/hypercall \
-T 'arch-x86_64 - Xen public headers' \
-X arch-x86_32 -X xen-x86_32 -X arch-arm \
../xen include/public include/xen/errno.hgmake[1]: ./xen-headers: Command not found gmake[1]: *** [html/hypercall/index.html] Error 127 gmake[1]: Leaving directory `/home/chegger/xen.git/docs'
gmake: *** [install-docs] Error 2
xen.git$
Since I am on the toplevel directory (or the shell at least) calling ./xen-headers can't be found, of course. That's my thinking.
I also made general cleanup to make 'docs' consistent with the other parts of the buildsystem.
Christoph
Quoted 46 lines · Christoph Egger
Quoted 7 lines · Ian Campbell
Quoted 6 lines · Christoph Egger
Quoted 5 lines · Ian Campbell
Quoted 3 lines · Christoph Egger
doc: buildsystem fixes
- use correct pathes (make gmake dist-docs from toplevel directory work)
Quoted 8 lines
Quoted 5 lines
Quoted 1 line
This ("make dist-docs") seems to work for me, how does it fail for you?
On the toplevel directory '../xen' and '../config' point to non-existent directories.
On the toplevel directory './gen-html-index' does not exist.I'm confused. By toplevel you mean "xen.git" and not "xen.git/docs", right?
Yes.
Quoted 7 lines
make dist-docs turns into "make -C docs install" (with DESTDIR set) so at the time ../xen or ../config are evaluated you should be in xen.git/docs.
Or are you saying that you are extracting the docs subdir out to elsewhere? Perhaps you are doing an out of tree build or something else complex?
No.
My build procedure is:- run configure
- gmake -jN dist-xen
- gmake -jN dist-tools
- gmake dist-docsQuoted 2 lines
I'm not suggesting your changes are wrong. I'd just like to understand the breakage...
I retried w/o my patch to get the error message:
xen.git$ gmake dist-docs
[...]./xen-headers -O html/hypercall \ -T 'arch-x86_64 - Xen public headers' \ -X arch-x86_32 -X xen-x86_32 -X arch-arm \ ../xen include/public include/xen/errno.h
Quoted 8 lines
gmake[1]: ./xen-headers: Command not found gmake[1]: *** [html/hypercall/index.html] Error 127 gmake[1]: Leaving directory `/home/chegger/xen.git/docs'
gmake: *** [install-docs] Error 2
xen.git$Since I am on the toplevel directory (or the shell at least) calling ./xen-headers can't be found, of course. That's my thinking.
I think you are mistaken, since the
Leaving directory `/home/chegger/xen.git/docs'
tells us that gmake previously entered this directory. That is how make (not just gmake) normally operates and is what "make -C docs" does.
Prior to your recent patch the invocation of ./xen-headers was via:
perl -w -- ./gen-html-index
Which is not consistent with your logs above. Do you have some other local patches which remove the "perl -w -- " prefix?
If you cropped it from the logs by mistake then the "Command not found" likely refers to "perl" and not "./xen-headers".
If you are trying to execute ./gen-html-index directly then the "Command not found" might be down to the shebang in the script which refers to /usr/bin/perl, which doesn't exist for you.
On Linux that would come out as "Bad interpreter", but NetBSD may differ I suppose.
Ian.
Quoted 61 lines · Ian Campbell
Quoted 46 lines · Christoph Egger
Quoted 7 lines · Ian Campbell
Quoted 6 lines · Christoph Egger
Quoted 5 lines · Ian Campbell
Quoted 3 lines · Christoph Egger
doc: buildsystem fixes
- use correct pathes (make gmake dist-docs from toplevel directory work)
Quoted 8 lines
Quoted 5 lines
Quoted 1 line
This ("make dist-docs") seems to work for me, how does it fail for you?
On the toplevel directory '../xen' and '../config' point to non-existent directories.
On the toplevel directory './gen-html-index' does not exist.I'm confused. By toplevel you mean "xen.git" and not "xen.git/docs", right?
Yes.
Quoted 7 lines
make dist-docs turns into "make -C docs install" (with DESTDIR set) so at the time ../xen or ../config are evaluated you should be in xen.git/docs.
Or are you saying that you are extracting the docs subdir out to elsewhere? Perhaps you are doing an out of tree build or something else complex?
No.
My build procedure is:- run configure
- gmake -jN dist-xen
- gmake -jN dist-tools
- gmake dist-docsQuoted 2 lines
I'm not suggesting your changes are wrong. I'd just like to understand the breakage...
I retried w/o my patch to get the error message:
xen.git$ gmake dist-docs
[...]./xen-headers -O html/hypercall \ -T 'arch-x86_64 - Xen public headers' \ -X arch-x86_32 -X xen-x86_32 -X arch-arm \ ../xen include/public include/xen/errno.hQuoted 8 lines
gmake[1]: ./xen-headers: Command not found gmake[1]: *** [html/hypercall/index.html] Error 127 gmake[1]: Leaving directory `/home/chegger/xen.git/docs'
gmake: *** [install-docs] Error 2
xen.git$Since I am on the toplevel directory (or the shell at least) calling ./xen-headers can't be found, of course. That's my thinking.
I think you are mistaken, since the
Leaving directory `/home/chegger/xen.git/docs'
tells us that gmake previously entered this directory. That is how make (not just gmake) normally operates and is what "make -C docs" does.
Quoted 4 lines
Prior to your recent patch the invocation of ./xen-headers was via:
perl -w -- ./gen-html-indexWhich is not consistent with your logs above. Do you have some other local patches which remove the "perl -w -- " prefix?
No, there is no other local patch in docs/
Same lines with my patch:
/usr/pkg/bin/perl -w /home/chegger/xen.git/docs/xen-headers -O html/hypercall \
-T 'arch-x86_64 - Xen public headers' \
-X arch-x86_32 -X xen-x86_32 -X arch-arm \
/home/chegger/xen.git/docs/../xen include/public include/xen/errno.h/usr/pkg/bin/perl -w -- /home/chegger/xen.git/docs/gen-html-index -i INDEX html html/misc/hvm-emulated-unplug.html html/misc/xl-numa-placement.html html/misc/efi.html html/misc/qemu-upstream_howto_use_it.html html/misc/xl-network-configuration.html html/misc/xen-command-line.html html/misc/xenstore-paths.html html/misc/coverage.html html/man/xm.1.html html/man/xl.1.html html/man/xl.conf.5.html html/man/xend-config.sxp.5.html html/man/xl.cfg.5.html html/man/xmdomain.cfg.5.html html/man/xlcpupool.cfg.5.html html/misc/dump-core-format.txt html/misc/kexec_and_kdump.txt html/misc/grant-tables.txt html/misc/xenpaging.txt html/misc/vtpm.txt html/misc/xen-error-handling.txt html/misc/xsm-flask.txt html/misc/console.txt html/misc/vtd.txt html/misc/distro_mapping.txt html/misc/libxl_memory.txt html/
misc/crashdb.txt html/misc/xl-disk-configuration.txt html/misc/sedf_scheduler_mini-HOWTO.txt html/misc/xenstore.txt html/misc/vbd-interface.txt html/misc/tscmode.txt html/hypercall/index.ht!
ml
Quoted 6 lines
If you cropped it from the logs by mistake then the "Command not found" likely refers to "perl" and not "./xen-headers".
If you are trying to execute ./gen-html-index directly then the "Command not found" might be down to the shebang in the script which refers to
/usr/bin/perl, which doesn't exist for you.
Yes, make configure to define $(PERL) is the real fix as Tim stated out in the other mail.
Quoted 2 lines
On Linux that would come out as "Bad interpreter", but NetBSD may differ I suppose.
More likely a difference to the korn-shell:
xen.git/docs$ ./xen-headers
ksh: ./xen-headers: No such file or directory xen.git/docs$ ./gen-html-index
ksh: ./gen-html-index: cannot execute - Permission denied xen.git/docs$
Christoph
Quoted 12 lines · Christoph Egger
Quoted 2 lines · Ian Campbell
I'm not suggesting your changes are wrong. I'd just like to understand the breakage...
I retried w/o my patch to get the error message:
xen.git$ gmake dist-docs
[...]./xen-headers -O html/hypercall \ -T 'arch-x86_64 - Xen public headers' \ -X arch-x86_32 -X xen-x86_32 -X arch-arm \ ../xen include/public include/xen/errno.h
Quoted 8 lines
gmake[1]: ./xen-headers: Command not found gmake[1]: *** [html/hypercall/index.html] Error 127 gmake[1]: Leaving directory `/home/chegger/xen.git/docs'
gmake: *** [install-docs] Error 2
xen.git$Since I am on the toplevel directory (or the shell at least) calling ./xen-headers can't be found, of course. That's my thinking.
make has gone into docs/ for you -- I suspect the 'Command not found' comes from the '#!/usr/bin/perl -w' at the top of docs/xen-headers, and so the important change in the patch is to use $(PERL) in the invocation.
Cheers,
Tim.