# part of dvi2bitmap # Copyright 1999, 2000 Council for the Central Laboratories of the Research Councils. # See file LICENCE for conditions. # # $Id: Makefile.in,v 1.31 2001/01/12 13:02:52 norman Exp $ # C++ all-warnings flags: # g++ -Wall (GNU) # CC +w2 (Sun Workshop compilers) # cxx -w0 (Compaq compilers) DEFS=@DEFS@ CPPFLAGS=@CPPFLAGS@ CXX=@CXX@ CXXFLAGS=@CXXFLAGS@ $(CPPFLAGS) $(DEFS) LIBS=-lm @LIBS@ KPATHSEA_OBJ=@KPATHSEAOBJ@ PNG_OBJ=@PNGOBJ@ GIF_OBJ=@GIFOBJ@ EXEC=dvi2bitmap OBJS=dvi2bitmap.o DviFile.o InputByteStream.o PkFont.o Bitmap.o \ BitmapImage.o XBMBitmap.o PageRange.o \ $(KPATHSEA_OBJ) $(PNG_OBJ) $(GIF_OBJ) # Add a suffix rule for stupid makes (hello, Tru64...) .SUFFIXES: .o .cc .cc.o: $(CXX) $(CXXFLAGS) -c $< $(EXEC): $(OBJS) $(CXX) $(OBJS) $(LIBS) -o $@ # for i in *.cc;do echo `echo $i|sed 's/\.cc/.o/'`: $i `sed -n '/^#include/s/^[^\"]*\"\(.*\)\".*/\1/p' $i`;done Bitmap.o: Bitmap.cc dvi2bitmap.h config.h Bitmap.h BitmapImage.h BitmapImage.o: BitmapImage.cc config.h BitmapImage.h PNGBitmap.h GIFBitmap.h XBMBitmap.h DviFile.o: DviFile.cc DviFile.h PkFont.h InputByteStream.h GIFBitmap.o: GIFBitmap.cc config.h Bitmap.h GIFBitmap.h InputByteStream.o: InputByteStream.cc config.h dvi2bitmap.h InputByteStream.h PNGBitmap-greyscale.o: PNGBitmap-greyscale.cc config.h Bitmap.h PNGBitmap.h PNGBitmap.o: PNGBitmap.cc config.h Bitmap.h PNGBitmap.h PageRange.o: PageRange.cc config.h PageRange.h PkFont.o: PkFont.cc config.h dvi2bitmap.h kpathsea.h InputByteStream.h PkFont.h XBMBitmap.o: XBMBitmap.cc config.h Bitmap.h XBMBitmap.h dvi2bitmap.o: dvi2bitmap.cc config.h dvi2bitmap.h DviFile.h PkFont.h Bitmap.h BitmapImage.h verbosity.h PageRange.h version.h kpathsea.h kpathsea.o: kpathsea.cc config.h kpathsea.h # for i in *.h *.cc;do echo "$i:" `sed -n '/^#include/s/^[^\"]*\"\(.*\)\".*/\1/p' $i`;done Bitmap.h: dvi2bitmap.h verbosity.h BitmapImage.h: dvi2bitmap.h verbosity.h Bitmap.h DviFile.h: dvi2bitmap.h InputByteStream.h PkFont.h verbosity.h GIFBitmap.h: dvi2bitmap.h BitmapImage.h InputByteStream.h: dvi2bitmap.h verbosity.h PNGBitmap.h: dvi2bitmap.h BitmapImage.h PageRange.h: verbosity.h PkFont.h: InputByteStream.h dvi2bitmap.h verbosity.h XBMBitmap.h: dvi2bitmap.h BitmapImage.h kpathsea.h: verbosity.h # Distribution configure: config/configure.in autoconf config/configure.in >configure chmod 755 configure dvi2bitmap.mantext: dvi2bitmap.1 nroff -man dvi2bitmap.1 >dvi2bitmap.mantext dvi2bitmap_source.tar: configure dvi2bitmap.mantext echo "Packaging up dvi2bitmap version" `cat VERSION` tar cf $@ *.cc *.h Makefile.in config.h.in README VERSION \ configure config/config* config/install-sh \ extras test \ dvi2bitmap.1 dvi2bitmap.mantext LICENCE # In Makefile.starlink, dvi2bitmap_doc.tar is listed as a SOURCE file, so # this target should only ever be required in the distribuTION # directory, and never in the distribuTED directory. dvi2bitmap_doc.tar: doc/dvi2bitmap.sgml cd doc; $(MAKE) doc.tar ln doc/doc.tar $@ # Merge dvi2bitmap_{source,doc}.tar into a single file for general distribution # The following could be done more directly by using, say, # tarball=$(shell cat VERSION), but that's specific to GNU make, I think. dvi2bitmap-%.tar: dvi2bitmap_source.tar dvi2bitmap_doc.tar rm -Rf distrib mkdir -p distrib/$(@:.tar=) cd distrib/$(@:.tar=); \ tar xf ../../dvi2bitmap_source.tar; \ tar xf ../../dvi2bitmap_doc.tar cd distrib; tar cf $@ $(@:.tar=) mv distrib/$@ . rm -Rf distrib # In the included make command here, specify Makefile.in explicitly. # This is because this target is usually run at packaging time, on a # freshly-exported, and hence unconfigured, copy of the source set, so # that the file Makefile will probably not exist and this command will # fail (since -f is one of the options which is not passed down to # sub-makes in $(MAKE)). dvi2bitmap.tar: dvi2bitmap_source.tar dvi2bitmap_doc.tar FN=dvi2bitmap-`cat VERSION`.tar; \ $(MAKE) -f Makefile.in $$FN; \ rm -f $@; \ ln -s $$FN $@ version.h README dvi2bitmap.1 Makefile.starlink: VERSION ./propagate-version version.h README dvi2bitmap.1 Makefile.starlink # Build defects list. This requires non-distributed scripts, # so is not buildable after distribution. defects.html: defects.xml java com.jclark.xsl.sax.Driver defects.xml /home/norman/sgml/defect/defects.xslt defects.html test: FORCE cd test; $(MAKE) test # Housekeeping targets tidy: FORCE rm -f *~ config/*~ clean: tidy rm -f *.o $(EXEC) rm -f dvi2bitmap_doc.tar dvi2bitmap.mantext rm -f dvi2bitmap.tar.Z dvi2bitmap_source.tar rm -f config.log config.status cd doc; $(MAKE) clean FORCE: