# # Maketool - GTK-based front end for gmake # Copyright (c) 1999-2003 Greg Banks # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # # $Id: help.mk.in,v 1.6 2003/09/30 12:16:10 gnb Exp $ # prefix= @prefix@ PACKAGE= @PACKAGE@ VERSION= @VERSION@ # We expect the including Makefile to set LANG helpdir= @datadir@/$(PACKAGE)/help/$(LANG) INSTALL= @INSTALL@ DB2HTML= db2html NSGMLS= nsgmls OUTDIR= help HTML_FILES= `ls $(OUTDIR)/*.html` IMAGES= `ls *.gif` INSTALLABLES= $(HTML_FILES) $(IMAGES) index.dat HTML4DTD= /usr/share/doc/openjade-1.3/pubtext/HTML4.dtd HELPCOMMON= ../common RM= /bin/rm -f top_builddir= ../../.. ### # all all:: html index.dat html: $(OUTDIR)/maketool.html $(OUTDIR)/maketool.html: help.sgml entities.sgml $(DB2HTML) --dsl $(HELPCOMMON)/help.dsl help.sgml # $(JADE) -t sgml -i html -d ../help.dsl $(SGMLDIR)/style/dsssl/docbook/docbook.dcl help.sgml at=@ entities.sgml: $(HELPCOMMON)/entities.sgml.in sed \ -e 's|${at}LANG${at}|$(LANG)|g' \ -e 's|${at}VERSION${at}|$(VERSION)|g' \ < $(HELPCOMMON)/entities.sgml.in > $@ index.dat: help.sgml awk -f $(HELPCOMMON)/extract-anchors.awk $(OUTDIR)/*.html > $@ maintainer-clean:: $(RM) entities.sgml # install install:: installdirs installdirs:: test -d $(helpdir) || $(INSTALL) -d -m 755 $(helpdir) install:: @echo "Installing:" @for file in $(INSTALLABLES) ; do \ if [ -z "$$INSTALL_VERBOSE" ]; then \ echo -n "."; \ else \ echo $$file; \ fi; \ $(INSTALL) -m 644 $$file $(helpdir); \ done @[ -z "$$INSTALL_VERBOSE" ] && echo "done" uninstall:: @echo "Uninstalling:" -@for file in $(INSTALLABLES) ; do \ if [ -z "$$INSTALL_VERBOSE" ]; then \ echo -n "."; \ else \ echo $$file; \ fi; \ $(RM) $(helpdir)/$$file; \ done @[ -z "$$INSTALL_VERBOSE" ] && echo "done" # check # $(NSGMLS) -sv $(SGMLDIR)/jade/pubtext/HTML4.dcl $$file; \ checkhtml: @echo "Checking HTML files..." -@for file in dummy $(HTML_FILES) ; do \ test $$file == dummy && continue; \ echo $$file; \ $(NSGMLS) -sv $$file; \ done checksgml: @echo "Checking SGML..." $(NSGMLS) -sv help.sgml #clean maintainer-clean:: -$(RM) -r $(OUTDIR) clean:: -$(RM) -r $(OUTDIR).junk ### maintainer-clean:: distclean distclean:: clean # Making a distribution distdir= $(top_builddir)/$(PACKAGE)-$(VERSION)/doc/help/$(LANG) DISTFILES= Makefile help.sgml entities.sgml $(INSTALLABLES) $(HTML_MANIFEST) dist: html entities.sgml index.dat for file in $(DISTFILES); do \ dir=`dirname $$file` ;\ if [ $dir = "." ]; then dir= ; else dir=/$$dir ; fi ;\ [ -d $(distdir)/$$dir ] || mkdir -p $(distdir)$$dir ;\ ln $$file $(distdir)$$dir 2>/dev/null || cp -p $$file $(distdir)$$dir 2>/dev/null; \ done