devbook.am 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. #
  2. # Generate output formats for a single DocBook/XML with/without chapters
  3. #
  4. # Variables set by the calling Makefile:
  5. # noinst_DATA: developers docs are not installed
  6. # docbook: the main DocBook/XML file, no chapters, appendix or image files
  7. # chapters: all files pulled in by an XInclude statement and images.
  8. #
  9. #
  10. # This makefile is intended for Developers Documentation and is not installed.
  11. # Do not use for Users docs or Specs which need to be installed and require olink support
  12. # Refer to http://www.x.org/releases/X11R7.6/doc/xorg-docs/ReleaseNotes.html#id2584393
  13. # for an explanation on documents classification.
  14. #
  15. # Developers documnetation is not installed
  16. noinst_DATA =
  17. # DocBook/XML file with chapters, appendix and images it includes
  18. dist_noinst_DATA = $(docbook) $(chapters)
  19. if HAVE_STYLESHEETS
  20. XMLTO_HTML_FLAGS = \
  21. --searchpath "$(XORG_SGML_PATH)/X11" \
  22. --searchpath "$(abs_top_builddir)" \
  23. -x $(STYLESHEET_SRCDIR)/xorg-xhtml.xsl
  24. noinst_DATA += $(docbook:.xml=.html)
  25. %.html: %.xml $(chapters)
  26. $(AM_V_GEN)$(XMLTO) $(XMLTO_HTML_FLAGS) xhtml-nochunks $<
  27. if HAVE_XMLTO_TEXT
  28. noinst_DATA += $(docbook:.xml=.txt)
  29. %.txt: %.xml $(chapters)
  30. $(AM_V_GEN)$(XMLTO) $(XMLTO_HTML_FLAGS) txt $<
  31. endif HAVE_XMLTO_TEXT
  32. if HAVE_FOP
  33. XMLTO_FO_FLAGS = \
  34. --searchpath "$(XORG_SGML_PATH)/X11" \
  35. --searchpath "$(abs_top_builddir)" \
  36. --stringparam img.src.path=$(abs_builddir)/ \
  37. -x $(STYLESHEET_SRCDIR)/xorg-fo.xsl
  38. noinst_DATA += $(docbook:.xml=.pdf) $(docbook:.xml=.ps)
  39. %.pdf: %.xml $(chapters)
  40. $(AM_V_GEN)$(XMLTO) $(XMLTO_FO_FLAGS) --with-fop pdf $<
  41. %.ps: %.xml $(chapters)
  42. $(AM_V_GEN)$(XMLTO) $(XMLTO_FO_FLAGS) --with-fop ps $<
  43. endif HAVE_FOP
  44. endif HAVE_STYLESHEETS
  45. CLEANFILES = $(noinst_DATA)