# Copyright © 2007 Pippijn van Steenhoven / The Ermyth Team # Rights to this code are documented in doc/poddoc/license.pod # # $Id: Makefile.in,v 1.6 2007/09/05 11:23:15 pippijn Exp $ PERL = @PERL@ CXX = @CXX@ RM = @RM@ CP = @CP@ INSTALL = @INSTALL@ MKDEP = @MKDEP@ CXXFLAGS = @CXXFLAGS@ -I../include -DBINDIR=\"$(bindir)\" # Want absolute paths? SRCDIR = . @ABSPATHS@SRCDIR= @SRCDIR@/test TESTCOUNT = 200 default: build SRCS = \ ${SRCDIR}/balloc.C \ ${SRCDIR}/metadata.C \ ${SRCDIR}/random.C \ .SUFFIXES: .t OBJS = ${SRCS:.C=.t} build: ${SRCDIR}/unit/runtest.h ${OBJS} .C.t: @echo " LD $@" @${CXX} -L${SRCDIR}/../src -L${SRCDIR}/../modules -l@PACKAGE_NAME@ -lservices ${CPPFLAGS} ${CXXFLAGS} $< -o $@ install: test: ${OBJS} @LD_LIBRARY_PATH=${SRCDIR}/../src:${SRCDIR}/../modules; \ for i in ${OBJS}; do \ echo "[$@] ==> $$i"; \ $$i; \ done $(SRCDIR)/unit/runtest.h: $(SRCDIR)/unit/runtest.h.in @echo "Generating $@" @${PERL} ${SRCDIR}/unit/gentests ${TESTCOUNT} $< > $@ .PHONY: depend clean distclean # This sed command sucks but I don't know a better way -- jilles depend: ${SRCDIR}/unit/runtest.h @${MKDEP} ${PICFLAGS} ${CPPFLAGS} ${CXXFLAGS} ${SRCS} | sed -e 's|\([^.]*\)\.o:|$(SRCDIR)/\1.t:|' > .depend clean: @${RM} -f *.o *.t *~ ${SRCDIR}/unit/runtest.h distclean: clean @${RM} -f Makefile .depend maintainer-clean: distclean include .depend