2013-04-16 23:57:27 -04:00
|
|
|
.DEFAULT_GOAL=build
|
|
|
|
TOKUROOT=../../
|
2013-04-16 23:57:48 -04:00
|
|
|
INCLUDEDIRS=-I. -I.. -I../../include
|
2013-04-16 23:57:40 -04:00
|
|
|
|
|
|
|
ifeq ($(CYGWIN),)
|
|
|
|
LINK_FILES += $(NEWBRT)
|
|
|
|
else ifneq ($(CC),icc)
|
|
|
|
LINK_FILES += $(NEWBRT)
|
|
|
|
else ifeq ($(DEBUG),0)
|
|
|
|
LINK_FILES += $(IPO_NEWBRT)
|
|
|
|
else ifeq ($(DEBUG),)
|
|
|
|
LINK_FILES += $(IPO_NEWBRT)
|
|
|
|
else
|
|
|
|
LINK_FILES += $(NEWBRT)
|
|
|
|
endif
|
|
|
|
|
2013-04-16 23:57:37 -04:00
|
|
|
include $(TOKUROOT)toku_include/Makefile.include
|
|
|
|
CPPFLAGS+=-D_GNU_SOURCE
|
2013-04-16 23:57:27 -04:00
|
|
|
|
|
|
|
ifeq ($(CC),icc)
|
|
|
|
SKIP_WARNING += $(ICC_NOWARN)1418 #Non static functions do not need prototypes.
|
|
|
|
endif
|
|
|
|
|
2008-05-08 20:30:33 +00:00
|
|
|
# On cygwin do:
|
|
|
|
# make CYGWIN=cygwin check
|
|
|
|
|
|
|
|
# For verbose output do
|
|
|
|
# make VERBOSE=1
|
|
|
|
# For very verbose output do
|
|
|
|
# make VERBOSE=2
|
|
|
|
|
2013-04-16 23:57:47 -04:00
|
|
|
#test1305 is first, since it is the longest test. Thus reducing the makespan on parallel checks
|
2008-05-08 20:30:33 +00:00
|
|
|
# Put these one-per-line so that if we insert a new one the svn diff can understand it better.
|
|
|
|
# Also keep them sorted.
|
2013-04-16 23:57:27 -04:00
|
|
|
REGRESSION_TESTS_RAW = \
|
2013-04-16 23:57:47 -04:00
|
|
|
test1305 \
|
2013-04-16 23:57:18 -04:00
|
|
|
block_allocator_test \
|
2008-07-09 12:00:26 +00:00
|
|
|
bread-test \
|
2008-05-08 20:30:33 +00:00
|
|
|
brt-serialize-test \
|
2013-04-16 23:57:46 -04:00
|
|
|
brt-serialize-sub-block-test \
|
2008-05-08 20:30:33 +00:00
|
|
|
brt-test \
|
|
|
|
brt-test-cursor \
|
|
|
|
brt-test-cursor-2 \
|
|
|
|
brt-test0 \
|
|
|
|
brt-test1 \
|
|
|
|
brt-test2 \
|
|
|
|
brt-test3 \
|
|
|
|
brt-test4 \
|
|
|
|
brt-test5 \
|
2013-04-16 23:57:17 -04:00
|
|
|
cachetable-rwlock-test \
|
2008-05-08 20:30:33 +00:00
|
|
|
cachetable-test \
|
|
|
|
cachetable-test2 \
|
2008-08-22 17:50:05 +00:00
|
|
|
cachetable-put-test \
|
2013-04-16 23:57:18 -04:00
|
|
|
cachetable-getandpin-test \
|
2008-08-22 17:50:05 +00:00
|
|
|
cachetable-unpin-test \
|
|
|
|
cachetable-rename-test \
|
|
|
|
cachetable-fd-test \
|
2008-08-26 14:07:27 +00:00
|
|
|
cachetable-flush-test \
|
2008-08-22 17:50:05 +00:00
|
|
|
cachetable-count-pinned-test \
|
2013-04-16 23:57:17 -04:00
|
|
|
cachetable-debug-test \
|
2013-04-16 23:57:18 -04:00
|
|
|
cachetable-debug-test \
|
2013-04-16 23:57:47 -04:00
|
|
|
cachetable-checkpoint-pending \
|
2013-04-16 23:57:38 -04:00
|
|
|
cachetable-checkpoint-test \
|
|
|
|
cachetable-prefetch-maybegetandpin-test \
|
|
|
|
cachetable-prefetch2-test \
|
|
|
|
cachetable-prefetch-close-test \
|
|
|
|
cachetable-prefetch-close-fail-test \
|
2013-04-16 23:57:41 -04:00
|
|
|
cachetable-prefetch-close-leak-test \
|
2013-04-16 23:57:38 -04:00
|
|
|
cachetable-prefetch-getandpin-test \
|
|
|
|
cachetable-prefetch-getandpin-fail-test \
|
|
|
|
cachetable-prefetch-checkpoint-test \
|
2013-04-16 23:58:54 -04:00
|
|
|
cachetable-reserve-filenum \
|
2008-05-08 20:30:33 +00:00
|
|
|
fifo-test \
|
|
|
|
list-test \
|
2008-05-13 12:14:38 +00:00
|
|
|
keyrange \
|
2008-05-13 12:27:07 +00:00
|
|
|
keyrange-unflat \
|
2008-05-13 20:29:19 +00:00
|
|
|
keyrange-dupsort \
|
|
|
|
keyrange-dupsort-unflat \
|
2013-04-16 23:57:41 -04:00
|
|
|
keytest \
|
2008-05-08 20:30:33 +00:00
|
|
|
log-test \
|
|
|
|
log-test2 \
|
|
|
|
log-test3 \
|
|
|
|
log-test4 \
|
|
|
|
log-test5 \
|
|
|
|
log-test6 \
|
2013-04-16 23:57:32 -04:00
|
|
|
log-test7 \
|
2013-04-16 23:57:58 -04:00
|
|
|
logcursor-timestamp \
|
|
|
|
logcursor-empty-logdir \
|
2013-04-16 23:57:59 -04:00
|
|
|
logcursor-empty-logfile \
|
|
|
|
logcursor-empty-logfile-2 \
|
2008-05-08 21:01:17 +00:00
|
|
|
memtest \
|
2013-04-16 23:57:48 -04:00
|
|
|
minicron-test \
|
2008-06-02 20:52:12 +00:00
|
|
|
omt-cursor-test \
|
2008-05-08 20:30:33 +00:00
|
|
|
omt-test \
|
2013-04-16 23:58:55 -04:00
|
|
|
recovery-cbegin \
|
|
|
|
recovery-cbegin-cend \
|
|
|
|
recovery-cbegin-cend-hello \
|
2013-04-16 23:58:54 -04:00
|
|
|
recovery-empty \
|
2013-04-16 23:58:54 -04:00
|
|
|
recovery-fopen-missing-file \
|
2013-04-16 23:58:54 -04:00
|
|
|
recovery-hello \
|
|
|
|
recovery-no-datadir \
|
|
|
|
recovery-no-log \
|
|
|
|
recovery-no-logdir \
|
2008-06-02 20:52:12 +00:00
|
|
|
shortcut \
|
2013-04-16 23:57:41 -04:00
|
|
|
test1308a \
|
2008-05-08 20:30:33 +00:00
|
|
|
test-assert \
|
|
|
|
test-brt-delete-both \
|
|
|
|
test-brt-overflow \
|
|
|
|
test-del-inorder \
|
|
|
|
test-inc-split \
|
Addresses #1125 Merged nested transactions from temporary merge branch into main.
Current tests fail (not regressions, they fail as of 13461)
* {{{x1.tdbrun}}}
* {{{test_log(2,3,4,5,6,7,8,9,10).recover}}}
* {{{test-recover(1,2,3).tdbrun}}}
* {{{test1324.tdbrun}}}
ULE_DEBUG disabled (defined to 0) Can be re-enabled for test purposes (set to 1).
refs [t:1125]
Merging into the temp branch (tokudb.main_13461+1125)
{{{svn merge --accept=postpone -r 12527:13461 ../tokudb.1125 ./}}}
Merging into main
{{{svn merge --accept=postpone -r13462:13463 ../tokudb.main_13461+1125/ ./}}}
git-svn-id: file:///svn/toku/tokudb@13464 c7de825b-a66e-492c-adef-691d508d4ae1
2013-04-16 23:57:56 -04:00
|
|
|
test-leafentry10 \
|
|
|
|
test-leafentry-nested \
|
2013-04-16 23:57:58 -04:00
|
|
|
test_logcursor \
|
2008-05-08 20:30:33 +00:00
|
|
|
test_oexcl \
|
|
|
|
test_toku_malloc_plain_free \
|
2013-04-16 23:57:38 -04:00
|
|
|
threadpool-test \
|
|
|
|
workqueue-test \
|
2008-07-27 22:16:49 +00:00
|
|
|
x1764-test \
|
2008-05-08 20:30:33 +00:00
|
|
|
ybt-test \
|
|
|
|
# This line intentially kept commented so I can have a \ on the end of the previous line
|
|
|
|
|
|
|
|
# Add in the binaries that must be run in various ways.
|
2013-04-16 23:57:27 -04:00
|
|
|
BINS_RAW = $(REGRESSION_TESTS_RAW) \
|
2008-05-08 20:30:33 +00:00
|
|
|
benchmark-test \
|
2008-07-23 11:24:13 +00:00
|
|
|
cachetable-scan \
|
2008-05-08 20:30:33 +00:00
|
|
|
# This line intentially kept commented so I can have a \ on the end of the previous line
|
2013-04-16 23:57:27 -04:00
|
|
|
# BINS will be defined by adding .exe if appropriate.
|
2008-05-08 20:30:33 +00:00
|
|
|
|
2013-04-16 23:57:33 -04:00
|
|
|
$(BINS): BIN_FROM_C_FLAGS+=$(LIBPORTABILITY)
|
|
|
|
|
2008-05-08 20:30:33 +00:00
|
|
|
CHECKS = \
|
2013-04-16 23:57:27 -04:00
|
|
|
benchmarktest_256 \
|
|
|
|
test-assertA \
|
|
|
|
test-assertB \
|
|
|
|
$(REGRESSION_TESTS) \
|
2008-05-08 20:30:33 +00:00
|
|
|
# This line intentially kept commented so I can have a \ on the previous line
|
2013-04-16 23:57:27 -04:00
|
|
|
#CHECKS will be defined automatically.
|
2013-04-16 23:57:20 -04:00
|
|
|
|
2008-05-08 20:30:33 +00:00
|
|
|
build: $(BINS)
|
2013-04-16 23:57:53 -04:00
|
|
|
check: $(PTHREAD_LOCAL) $(patsubst %,check_%,$(CHECKS))
|
2008-05-08 20:30:33 +00:00
|
|
|
|
2008-05-12 10:58:07 +00:00
|
|
|
check_fail:
|
2013-04-16 23:57:34 -04:00
|
|
|
test 0 = 1 $(SUMMARIZE_CMD)
|
2008-05-12 10:58:07 +00:00
|
|
|
check_ok:
|
2013-04-16 23:57:34 -04:00
|
|
|
test 0 = 0 $(SUMMARIZE_CMD)
|
2008-05-12 10:58:07 +00:00
|
|
|
|
2013-04-16 23:57:41 -04:00
|
|
|
|
2013-04-16 23:57:47 -04:00
|
|
|
ifeq ($(SKIP_1305),1)
|
|
|
|
check_test1305:
|
2013-04-16 23:57:41 -04:00
|
|
|
@echo SKIPPED SLOW TEST $@
|
2013-04-16 23:58:01 -04:00
|
|
|
else
|
|
|
|
# Don't run 1305 under valgrind. It takes way too long.
|
|
|
|
check_test1305: test1305$(BINSUF)
|
|
|
|
./$< $(VERBVERBOSE) $(SUMMARIZE_CMD)
|
2013-04-16 23:57:41 -04:00
|
|
|
endif
|
2013-04-16 23:57:30 -04:00
|
|
|
|
2013-04-16 23:57:53 -04:00
|
|
|
check_benchmarktest_256: benchmark-test$(BINSUF) $(PTHREAD_LOCAL)
|
2013-04-16 23:57:34 -04:00
|
|
|
$(VGRIND) ./$< $(VERBVERBOSE) --valsize 256 --verify 1 $(SUMMARIZE_CMD)
|
2008-05-08 20:30:33 +00:00
|
|
|
|
2013-04-16 23:57:53 -04:00
|
|
|
check_test-assertA: test-assert$(BINSUF) $(PTHREAD_LOCAL)
|
2008-05-08 20:30:33 +00:00
|
|
|
@# no arguments, should err
|
2013-04-16 23:57:34 -04:00
|
|
|
$(VGRIND) ./$< > /dev/null 2>&1 ; test $$? = 1 $(SUMMARIZE_CMD)
|
2013-04-16 23:57:53 -04:00
|
|
|
check_test-assertB: test-assert$(BINSUF) $(PTHREAD_LOCAL)
|
2008-05-08 20:30:33 +00:00
|
|
|
@# one argument, not "ok" should err
|
2008-05-12 10:58:07 +00:00
|
|
|
@rm -f test-assert.out
|
2013-04-16 23:57:34 -04:00
|
|
|
($(VGRIND) ./$< notok) > test-assert.out 2>&1 ; test $$? = 1 && fgrep failed test-assert.out > /dev/null $(SUMMARIZE_CMD)
|
2013-04-16 23:57:53 -04:00
|
|
|
check_test-assertC: test-assert$(BINSUF) $(PTHREAD_LOCAL)
|
2008-05-12 10:58:07 +00:00
|
|
|
|
2013-04-16 23:57:53 -04:00
|
|
|
check_test-assert$(BINSUF): test-assert$(BINSUF) $(PTHREAD_LOCAL)
|
2013-04-16 23:57:27 -04:00
|
|
|
@# one argument, "ok" should not error
|
2013-04-16 23:57:34 -04:00
|
|
|
$(VGRIND) ./$< ok $(SUMMARIZE_CMD)
|
2008-05-12 10:58:07 +00:00
|
|
|
|
2013-04-16 23:57:53 -04:00
|
|
|
check_%: % $(PTHREAD_LOCAL)
|
2013-04-16 23:58:00 -04:00
|
|
|
ifeq ($(VGRIND),)
|
|
|
|
./$< $(VERBVERBOSE) $(SUMMARIZE_CMD)
|
|
|
|
else
|
|
|
|
$(VGRIND) --log-file=$<.check.valgrind ./$< $(VERBVERBOSE); \
|
|
|
|
if [ $$? -eq 0 ] ; then \
|
|
|
|
lines=`cat $<.check.valgrind | wc -l`; \
|
|
|
|
if [ $$lines -ne 0 ] ; then cat $<.check.valgrind; test 0 = 1; fi \
|
2013-04-16 23:58:00 -04:00
|
|
|
else \
|
2013-04-16 23:58:02 -04:00
|
|
|
cat $<.check.valgrind; test 0 = 1; \
|
2013-04-16 23:58:00 -04:00
|
|
|
fi \
|
|
|
|
$(SUMMARIZE_CMD)
|
|
|
|
endif
|
2008-05-12 10:58:07 +00:00
|
|
|
|
2013-04-16 23:57:27 -04:00
|
|
|
benchmark-test.$(OEXT): ../brt.h ../brt-search.h ../../include/db.h
|
2008-05-08 20:30:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
clean:
|
2013-04-16 23:57:34 -04:00
|
|
|
rm -rf log-test7.c.dir_*
|
2013-04-16 23:58:54 -04:00
|
|
|
rm -rf *.dir dir.*
|
2013-04-16 23:57:34 -04:00
|
|
|
rm -f cachetable-fd-test.ctest2.data test_oexcl.c.tmp
|
2013-04-16 23:58:00 -04:00
|
|
|
rm -f *.brt *.clean *.dirty *.tdb *.dat *.data *.out *.check.valgrind
|
2013-04-16 23:57:20 -04:00
|
|
|
|
2013-04-16 23:57:41 -04:00
|
|
|
$(BINS): $(LINK_FILES)
|
|
|
|
$(BINS): test.h
|