documentation/Makefile
author Knud Baastrup <kba@deif.com>
Tue, 14 Apr 2015 10:12:55 -0400
changeset 2625 e25af8bd3957
parent 1917 6129a5f715fb
child 2646 0c56c67072a6
permissions -rw-r--r--
Eoe mac address now derived from unique mac.
The EoE MAC address is now derived from the NIC part of the first global
unique MAC address of the linked list of available network interfaces or
otherwise the MAC address used by the EtherCAT master. The EoE MAC address
will get the format 02:NIC:NIC:NIC:RP:RP where NIC comes from the unique MAC
address (if available) and RP is the ring position of the EoE slave.
#------------------------------------------------------------------------------
#
#  LaTeX Makefile
#
#  $Id$
#
#------------------------------------------------------------------------------

FILE := ethercat_doc

LATEX_OPTIONS := -file-line-error-style

COMMANDS := \
	alias \
	config \
	cstruct \
	data \
	debug \
	domains \
	download \
	eoe \
	foe_read \
	foe_write \
	graph \
	master \
	pdos \
	reg_read \
	reg_write \
	sdos \
	sii_read \
	sii_write \
	slaves \
	soe_read \
	soe_write \
	states \
	upload \
	version \
	xml

EXT_PREFIX := external/ethercat_
EXT_FILES := $(addprefix $(EXT_PREFIX),$(COMMANDS))
ETHERCAT_CMD := ../tool/ethercat
ETHERCAT_HELP := $(ETHERCAT_CMD) -h

#------------------------------------------------------------------------------

all: pdf

$(EXT_FILES): $(ETHERCAT_CMD)
	@mkdir -pv external
	@echo Creating $@...
	$(shell $(subst $(EXT_PREFIX),$(ETHERCAT_HELP) ,$@) > $@)

pdf: $(EXT_FILES)
	$(MAKE) -C images
	$(MAKE) -C graphs
	pdflatex $(LATEX_OPTIONS) $(FILE)

index:
	makeindex $(FILE)
	makeindex $(FILE).nlo -s nomencl.ist -o $(FILE).nls

clean:
	@rm -f \
		$(FILE).aux \
		$(FILE).dvi \
		$(FILE).idx \
		$(FILE).ilg \
		$(FILE).ind \
		$(FILE).lof \
		$(FILE).log \
		$(FILE).lol \
		$(FILE).lot \
		$(FILE).nlo \
		$(FILE).nls \
		$(FILE).out \
		$(FILE).pdf \
		$(FILE).toc \
		*~ \
		images/*.bak

#------------------------------------------------------------------------------