Makefile 876 B

1234567891011121314151617181920212223242526272829
  1. BASEDIR=~/lfs-book/
  2. lfs:
  3. xsltproc --xinclude --nonet -stringparam base.dir $(BASEDIR) \
  4. stylesheets/lfs-chunked.xsl index.xml
  5. if [ ! -e $(BASEDIR)stylesheets ]; then \
  6. mkdir -p $(BASEDIR)stylesheets; \
  7. fi;
  8. cp stylesheets/lfs.css $(BASEDIR)stylesheets
  9. if [ ! -e $(BASEDIR)images ]; then \
  10. mkdir -p $(BASEDIR)images; \
  11. fi;
  12. cp /usr/share/xml/docbook/xsl-stylesheets-1.65.1/images/*.png \
  13. $(BASEDIR)images
  14. cd $(BASEDIR); sed -i -e "s@../stylesheets@stylesheets@" \
  15. index.html part1.html part2.html part3.html longindex.html
  16. cd $(BASEDIR); sed -i -e "s@../images@images@g" \
  17. index.html part1.html part2.html part3.html longindex.html
  18. pdf:
  19. xsltproc --xinclude --nonet --output lfs.fo stylesheets/lfs-pdf.xsl \
  20. index.xml
  21. sed -i -e "s/inherit/all/" lfs.fo
  22. fop.sh lfs.fo lfs.pdf
  23. validate:
  24. xmllint --noout --nonet --xinclude --postvalid index.xml