Makefile 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. #!/bin/make -f
  2. # file: docbook/Makefile
  3. # ====================================================================
  4. # environment definitions;
  5. # --------------------------------------------------------------------
  6. include ../make.def
  7. DOCBOOK=/usr/share/xml/docbook/stylesheet/docbook-xsl/fo
  8. DOCBOOK=/usr/share/xml/docbook/stylesheet/docbook-xsl/html
  9. LIBRARY=${DOC}/plc-utils
  10. XFLAGS=--skip-validation
  11. # ====================================================================
  12. # symbols;
  13. # --------------------------------------------------------------------
  14. TRASH=*~ *.[0-9][0-9][0-9] t t.* *.1 *.1a *.1.html *.c.html *.cpp.html *.h.html *.hpp.html *.1.html *.1a.html *.sh.html *.xml.html *.xsd.html ch[0-9][0-9]*.html hpp.txt cpp.txt piboffset.* plc-utils.txt cpp.txt hpp.txt
  15. STYLES=param.xsl lists.xsl synop.xsl
  16. BOOKS=index.html
  17. # ====================================================================
  18. # pseudo targets;
  19. # --------------------------------------------------------------------
  20. all compile: manuals ${BOOKS}
  21. manuals:
  22. ${SHELL} ../docbook/manuals
  23. scripts:
  24. library:
  25. install -m ${DIR_PERM} -o ${OWNER} -g ${GROUP} -d ${LIBRARY}
  26. install: compile library
  27. if [ -d ${LIBRARY} ]; then install -m ${WWW_PERM} -o ${OWNER} -g ${GROUP} *.html *.css *.png *.jpg ${LIBRARY}; fi
  28. uninstall:
  29. rm -f ${LIBRARY}/*.c.html ${LIBRARY}/*.h.html ${LIBRARY}/*.1.html
  30. setup:
  31. install ${STYLES} ${DOCBOOK}
  32. clean:
  33. rm -f ${BOOKS} ${TRASH}
  34. check:
  35. # ${SHELL} docbook.sh
  36. ignore:
  37. echo ${TOOLS} | tr ' ' '\n' > .gitignore
  38. # ====================================================================
  39. # pseudo targets;
  40. # --------------------------------------------------------------------
  41. index.html: plc-utils.xml *.xml *.png
  42. xmlto ${XFLAGS} -o . html ${<}
  43. plc-utils.pdf: *.xml *.png
  44. docbook2pdf ${<}
  45. plc-utils.txt: *.xml
  46. xmlto ${XFLAGS} txt ${<}