fp@369: #------------------------------------------------------------------------------
fp@369: #
fp@369: #  LaTeX Makefile
fp@369: #
fp@369: #  $Id$
fp@369: #
fp@369: #------------------------------------------------------------------------------
fp@369: 
fp@369: FILE := ethercat_doc
fp@369: 
fp@369: LATEX_OPTIONS := -file-line-error-style
fp@369: 
fp@1140: COMMANDS := \
fp@1140: 	alias \
fp@1140: 	config \
fp@1514: 	cstruct \
fp@1140: 	data \
fp@1140: 	debug \
fp@1140: 	domains \
fp@1423: 	download \
fp@1485: 	eoe \
fp@1423: 	foe_read \
fp@1423: 	foe_write \
fp@1423: 	graph \
fp@1140: 	master \
fp@1140: 	pdos \
fp@1423: 	reg_read \
fp@1423: 	reg_write \
fp@1140: 	sdos \
fp@1140: 	sii_read \
fp@1140: 	sii_write \
fp@1423: 	slaves \
fp@1917: 	soe_read \
fp@1917: 	soe_write \
fp@1140: 	states \
fp@1423: 	upload \
fp@1423: 	version \
fp@1140: 	xml
fp@1140: 
fp@1140: EXT_PREFIX := external/ethercat_
fp@1140: EXT_FILES := $(addprefix $(EXT_PREFIX),$(COMMANDS))
fp@1140: ETHERCAT_CMD := ../tool/ethercat
fp@1140: ETHERCAT_HELP := $(ETHERCAT_CMD) -h
fp@1140: 
fp@369: #------------------------------------------------------------------------------
fp@369: 
fp@1140: all: pdf
fp@369: 
fp@1140: $(EXT_FILES): $(ETHERCAT_CMD)
fp@1140: 	@mkdir -pv external
fp@1140: 	@echo Creating $@...
fp@1140: 	$(shell $(subst $(EXT_PREFIX),$(ETHERCAT_HELP) ,$@) > $@)
fp@369: 
fp@1140: pdf: $(EXT_FILES)
fp@1202: 	$(MAKE) -C images
fp@1202: 	$(MAKE) -C graphs
fp@371: 	pdflatex $(LATEX_OPTIONS) $(FILE)
fp@371: 
fp@371: index:
fp@371: 	makeindex $(FILE)
fp@1306: 	makeindex $(FILE).nlo -s nomencl.ist -o $(FILE).nls
fp@369: 
fp@369: clean:
fp@1289: 	@rm -f \
fp@1289: 		$(FILE).aux \
fp@1289: 		$(FILE).dvi \
fp@1289: 		$(FILE).idx \
fp@1289: 		$(FILE).ilg \
fp@1289: 		$(FILE).ind \
fp@1289: 		$(FILE).lof \
fp@1289: 		$(FILE).log \
fp@1289: 		$(FILE).lol \
fp@1289: 		$(FILE).lot \
fp@1289: 		$(FILE).nlo \
fp@1306: 		$(FILE).nls \
fp@1289: 		$(FILE).out \
fp@1289: 		$(FILE).pdf \
fp@1289: 		$(FILE).toc \
fp@1289: 		*~ \
fp@1289: 		images/*.bak
fp@369: 
fp@369: #------------------------------------------------------------------------------