# # Makefile # Copyright (C) 1997-2000 by John Heidemann # $Id: Makefile.in,v 1.28 2004/02/04 17:21:32 johnh Exp johnh $ # # This program is distributed under terms of the GNU general # public license, version 2. See the file COPYING # in $dblib for details. # # Where does perl live? # PERL=/usr/local/bin/perl PERL=@PERL@ # Requires perl 5 for some commands. prefix = @prefix@ # Where should the scripts be installed? # BINDIR=/usr/local/bin BINDIR=@mybindir@ # Where should the support files go? # LIBDIR=/usr/local/lib/jdb LIBDIR=@mydatadir@ ###################################################################### # No need to change things below this line. # MYPERL=/usr/bin/perl LIBFILES=README COPYING release \ dblib.pl \ DbGetopt.pm DbTDistr.pm OTHERFILES=Makefile.in \ configure configure.in install-sh \ CONF/README CONF/configure.in.fns CONF/configure.in.perl \ DATA/[a-z]* DBFILES=\ db2dcliff \ dbcol \ dbcolcreate \ dbcoldefine \ dbcoldiff \ dbcolhisto \ dbcolize \ dbcolmerge \ dbcolmovingstats \ dbcolmultiscale \ dbcolneaten \ dbcolpercentile \ dbcolrename \ dbcolscorrelate \ dbcolsplittocols \ dbcolsplittorows \ dbcolstats \ dbcoltighten \ dbfilesplit \ dbformmail \ dbjoin \ dblistize \ dbmultistats \ dbrecolize \ dbrow \ dbrowaccumulate \ dbrowdiff \ dbrowenumerate \ dbroweval \ dbrowsplituniq \ dbrowuniq \ dbsort \ dbstats \ dbstripcomments \ dbstripextraheaders \ dbstripleadingspace CONVERTERS=\ crl_to_db \ db_to_html_table \ dmalloc_to_db \ ipchain_logs_to_db \ kitrace_to_db \ ns_to_db \ tabdelim_to_db \ tcpdump_to_db BINFILES=$(DBFILES) $(CONVERTERS) TESTFILES=\ db_test_suite \ t_distribution \ TEST/*.{cmd,in,in-2,out,code} all: @echo 'Done. (To install, do "make install", possibly preceeded by "make test".)' install_lib: test -d $(LIBDIR) || mkdir $(LIBDIR) for i in $(LIBFILES); do echo $$i; cp $$i $(LIBDIR); done install_bin: test -d $(BINDIR) || mkdir $(BINDIR) for i in $(BINFILES); do \ echo $$i; \ sed -e "s@$(MYPERL)@$(PERL)@" -e 's@dblibdir *= *".*"@dblibdir = "$(LIBDIR)"@' -e 's@dbbindir *= *".*"@dbbindir = "$(BINDIR)"@' <$$i >$(BINDIR)/$$i; \ chmod +x $(BINDIR)/$$i; \ done install: install_lib install_bin clean: rm TEST/*.diff TEST/*.trial # # tests # test: ./db_test_suite test_where: @echo MYPERL=$(MYPERL) @echo PERL=$(PERL) @echo SRC=`pwd` # # distribution stuff # TOSHAR=$(LIBFILES) $(OTHERFILES) $(BINFILES) $(TESTFILES) PACKAGE=jdb shar: shar $(TOSHAR) >$(PACKAGE)-`cat release`.shar shar.gz: shar $(TOSHAR) |gzip >$(PACKAGE)-`cat release`.shar.gz .tar_files: Makefile release for i in $(TOSHAR); \ do \ echo ./$(PACKAGE)-`cat release`/$$i; \ done >.tar_files tar: .tar_files ln -s . ./$(PACKAGE)-`cat release` tar cvf - `cat .tar_files` >$(PACKAGE)-`cat release`.tar rm ./$(PACKAGE)-`cat release` tar.gz: .tar_files ln -s . ./$(PACKAGE)-`cat release` tar cvf - `cat .tar_files` |gzip >$(PACKAGE)-`cat release`.tar.gz rm ./$(PACKAGE)-`cat release` release_cp: cp $(PACKAGE)-`cat release`.tar.gz $$HOME/LIB/WWW/SOFTWARE/JDB cp README $$HOME/LIB/WWW/SOFTWARE/JDB/jdb-`cat release`_README.txt mv $(PACKAGE)-`cat release`.tar.gz RELEASES