Makefile 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. ifeq ($(TOPDIR),)
  2. TOPDIR:=${CURDIR}/..
  3. endif
  4. all: compile
  5. include $(TOPDIR)/rules.mk
  6. include $(INCLUDE_DIR)/prereq.mk
  7. MAIN = openwrt.tex
  8. DEPS = $(MAIN) Makefile config.tex network.tex network-scripts.tex network-scripts.tex wireless.tex build.tex adding.tex bugs.tex $(TMP_DIR)/.prereq-docs
  9. compile:
  10. $(NO_TRACE_MAKE) cleanup
  11. latex $(MAIN)
  12. $(NO_TRACE_MAKE) openwrt.pdf openwrt.html
  13. $(NO_TRACE_MAKE) cleanup
  14. $(TMP_DIR)/.prereq-docs:
  15. mkdir -p $(TMP_DIR)
  16. $(NO_TRACE_MAKE) prereq
  17. touch $@
  18. openwrt.html: $(DEPS)
  19. htlatex $(MAIN)
  20. openwrt.pdf: $(DEPS)
  21. pdflatex $(MAIN)
  22. clean: cleanup
  23. rm -f openwrt.pdf openwrt.html openwrt.css
  24. cleanup: FORCE
  25. rm -f *.log *.aux *.toc *.out *.lg *.dvi *.idv *.4ct *.4tc *.xref *.tmp *.dvi
  26. $(eval $(call RequireCommand,latex, \
  27. You need to install LaTeX to build the OpenWrt documentation \
  28. ))
  29. $(eval $(call RequireCommand,pdflatex, \
  30. You need to install LaTeX to build the OpenWrt documentation \
  31. ))
  32. $(eval $(call RequireCommand,htlatex, \
  33. You need to install tex4ht to build the OpenWrt documentation \
  34. ))
  35. FORCE:
  36. .PHONY: FORCE