# you may set this to empty in order to install the files
# non-locally.
LOCAL=local

USRDIR=/usr/$(LOCAL)

# directory for tbents.txt
TBLIBDIR= $(USRDIR)/share/xml/tbook

# directory for Info files
INFODIR= $(USRDIR)/share/info

# directory for the stylesheets
XSLTDIR= $(USRDIR)/share/xml/texi2latex

# destination directory for executables
DESTDIR= $(USRDIR)/bin

# Options for the C++ compiler
CXXFLAGS = -O2

# The standard file permissions for installed 
# non-executables
PERMS= a+r,u+w

# No changes should be necessary below this line 
# -----------------------------------------------------

.PHONY : install clean

texi2latex.info.gz: texi2latex.texi
	LANG=en ; makeinfo --enable-encoding --no-split $<
	gzip -f $(basename $<).info

install : texi2latex.info.gz
	install -d $(ROOT)$(INFODIR)
	install --mode=$(PERMS) texi2latex.info.gz $(ROOT)$(INFODIR)
	- install-info --info-file=$(ROOT)$(INFODIR)/texi2latex.info.gz \
	  --dir-file=$(ROOT)$(INFODIR)/dir

clean :
	rm -f texi2latex.info.gz texi2latex.info *.aux *.toc *.dvi *.pdf
