# Makefile for teTeX's extra scripts - te@informatik.uni-hannover.de.
# Public domain.

ac_include ../make/paths.make
ac_include ../make/common.make
ac_include ../make/programs.make

SCRIPTS= dvi2fax ps2frag texconfig dvired pslatex texi2html texi2pdf allcm allneeded fontexport fontimport kpsetool mkfontdesc

LIVESCRIPTS = \
	amstex calatex context csplain cylatex delatex dklatex \
	einitex elatex ellatex eplain eslatex etlatex evirtex  \
	filatex frlatex gblatex hrlatex hugelatex hugetex hulatex  \
	inimf inimpost iniomega initex itlatex jadetex jadetexpdf  \
	lambda latex mex mltex nelatex nllatex nolatex  \
	pdfinitex pdflatex pdftexinfo pdfvirtex platex pslatex  \
	ptlatex rulatex rolatex silatex texinfo texsis \
	virmf virmpost viromega virtex \
	texutil.perl 

manpgs=texi2html texconfig
default:all
all: $(SCRIPTS) $(LIVESCRIPTS)

install: install-data install-exec

# Auxiliary files.
install-data::
	$(SHELL) $(top_srcdir)/../mkinstalldirs $(mandir)
	for p in $(manpgs); do \
	  $(INSTALL_DATA) $(srcdir)/$$p.man $(mandir)/$$p.$(manext); \
	done

install-exec:
	-$(SHELL) $(srcdir)/../mkinstalldirs $(scriptdir)
	for s in $(SCRIPTS) $(LIVESCRIPTS); do \
	  rm -f $(scriptdir)/$$s ; \
	  $(INSTALL_SCRIPT) $(srcdir)/$$s $(scriptdir)/$$s; \
	done
	cd  $(bindir); rm -f allec texhash kpsepath kpsexpand; \
	  ln -s kpsetool kpsepath; \
	  ln -s kpsetool kpsexpand ; \
	  ln -s allcm allec; \
	  ln -s mktexlsr texhash

ac_include ../make/clean.make

config.status: $(srcdir)/configure
	$(SHELL) $(srcdir)/configure --no-create --verbose

Makefile: $(srcdir)/Makefile.in config.status
	$(SHELL) config.status

ac_include ../make/misc.make

