make build-coverage. addresses #277

git-svn-id: file:///svn/tokudb@1729 c7de825b-a66e-492c-adef-691d508d4ae1
This commit is contained in:
Rich Prohaska 2008-01-18 14:43:32 +00:00
parent 08dca9d5b5
commit 63f80c0cd6
4 changed files with 14 additions and 10 deletions

View file

@ -1,7 +1,13 @@
TAGS: */*.c */*.h
etags */*.c */*.h
SRCDIRS = newbrt src src/tests cxx cxx/tests utils db-benchmark-test db-benchmark-test-cxx
clean:
cd newbrt;make clean
cd src;make clean
cd db-benchmark-test-cxx;make clean
for d in $(SRCDIRS); do $(MAKE) -k -C $$d clean; done
build:
for d in $(SRCDIRS); do $(MAKE) -k -C $$d; done
build-coverage:
for d in $(SRCDIRS); do $(MAKE) -k -C $$d -k OPTFLAGS="-O0" GCOV_FLAGS="-fprofile-arcs -ftest-coverage"; done

View file

@ -7,9 +7,8 @@
BENCHDBS = bench.bdb/ bench.tokudb
OPTFLAGS = -O2
CXXFLAGS = -Wall -Werror -g
CXXFLAGS = -Wall -Werror -g $(OPTFLAGS) $(GCOV_FLAGS)
# CFLAGS += -pg
CXXFLAGS += $(OPTFLAGS)
ifdef BDBDIR
BDB_CPPFLAGS = -I$(BDBDIR)/include
@ -24,7 +23,7 @@ TARGETS = db-benchmark-test-bdb db-benchmark-test-tokudb
default: $(TARGETS)
clean:
rm -rf $(TARGETS) $(BENCHDBS)
rm -rf $(TARGETS) $(BENCHDBS) *.gcno *.gcda *.gcov
db-benchmark-test-tokudb: ../lib/libtdb_cxx.a
db-benchmark-test-tokudb: db-benchmark-test.cpp

View file

@ -8,9 +8,8 @@
BENCHDBS = bench.bdb/ bench.tokudb
OPTFLAGS = -O2
CFLAGS = -Wall -Werror -g
CFLAGS = -Wall -Werror -g $(OPTFLAGS) $(GCOV_FLAGS)
# CFLAGS += -pg
CFLAGS += $(OPTFLAGS)
ifdef BDBDIR
BDB_CPPFLAGS = -I$(BDBDIR)/include
@ -25,7 +24,7 @@ TARGETS = db-benchmark-test-bdb db-benchmark-test-tokudb
default: $(TARGETS)
clean:
rm -rf $(TARGETS) $(BENCHDBS)
rm -rf $(TARGETS) $(BENCHDBS) *.gcno *.gcda *.gcov
db-benchmark-test-tokudb: db-benchmark-test.c
$(CC) $(CFLAGS) -I../include -L../lib -ldb -Wl,-rpath,$(PWD)/../lib $< -o $@ -DDIRSUF=tokudb

View file

@ -6,7 +6,7 @@ BDB_LOAD=$(BDBDIR)/bin/db_load
DIFF=diff -I 'db_pagesize='
CFLAGS = -std=gnu89 -W -Wall -Wno-unused -g
CFLAGS = -std=gnu89 -W -Wall -Wno-unused -g $(OPTFLAGS) $(GCOV_FLAGS)
# vars to compile bins that handle tokudb using libdb.so
# when one uses relative address in an rpath, the library better be located relative