Makefile.am 6.18 KB
Newer Older
1 2
ACLOCAL_AMFLAGS="-Im4"

3
SERVER_LIBS=@SERVER_LIBS@
4
CLIENT_LiBS=@CLIENT_LIBS@
5

6
AM_CPPFLAGS = -I${srcdir}/src -I${srcdir}/include
Rob Latham's avatar
Rob Latham committed
7

8
bin_PROGRAMS = bin/sdskv-server-daemon 	    \
9 10 11
	       bin/sdskv-shutdown

check_PROGRAMS = test/sdskv-open-test              \
12
		 test/sdskv-list-db-test           \
13 14 15 16 17 18 19 20
		 test/sdskv-put-test               \
		 test/sdskv-length-test            \
		 test/sdskv-get-test               \
		 test/sdskv-erase-test             \
		 test/sdskv-list-keys-test         \
		 test/sdskv-list-keyvals-test      \
		 test/sdskv-list-keys-prefix-test  \
		 test/sdskv-custom-cmp-test        \
21
		 test/sdskv-migrate-test           \
Matthieu Dorier's avatar
Matthieu Dorier committed
22
		 test/sdskv-multi-test             \
23
		 test/sdskv-cxx-test               \
24
		 test/sdskv-custom-server-daemon
Matthieu Dorier's avatar
Matthieu Dorier committed
25

26
bin_sdskv_server_daemon_SOURCES = src/sdskv-server-daemon.cc
Matthieu Dorier's avatar
Matthieu Dorier committed
27
bin_sdskv_server_daemon_DEPENDENCIES = lib/libsdskv-server.la
Matthieu Dorier's avatar
Matthieu Dorier committed
28 29
bin_sdskv_server_daemon_LDFLAGS = -Llib -lsdskv-server
bin_sdskv_server_daemon_LDADD = ${LIBS} -lsdskv-server ${SERVER_LIBS}
Matthieu Dorier's avatar
Matthieu Dorier committed
30

31

Matthieu Dorier's avatar
Matthieu Dorier committed
32 33 34 35 36
bin_sdskv_shutdown_SOURCES = src/sdskv-shutdown.c
bin_sdskv_shutdown_DEPENDENCIES = lib/libsdskv-client.la
bin_sdskv_shutdown_LDFLAGS = -Llib -lsdskv-client
bin_sdskv_shutdown_LDADD = ${LIBS} -lsdskv-client

37 38 39 40 41 42 43
#lib_LTLIBRARIES = lib/libkvclient.la \
#                  lib/libkvserver.la \
#                  lib/libkvgroupclient.la \
#                  lib/libkvgroupserver.la \
#		   lib/libsdskv-client.la \
#		   lib/libsdskv-server.la
lib_LTLIBRARIES = lib/libsdskv-client.la \
Matthieu Dorier's avatar
Matthieu Dorier committed
44 45 46
		  lib/libsdskv-server.la

lib_libsdskv_client_la_SOURCES = src/sdskv-client.c
47

48
#lib_libkvclient_la_SOURCES = src/kv-client.c
49

50
#lib_libkvgroupclient_la_SOURCES = src/kvgroup-client.cc
51

52 53
#lib_libkvserver_la_SOURCES = src/kv-server.cc \
#			     src/datastore/datastore.cc
Rob Latham's avatar
Rob Latham committed
54

Matthieu Dorier's avatar
Matthieu Dorier committed
55 56 57
lib_libsdskv_server_la_SOURCES = src/sdskv-server.cc \
				 src/datastore/datastore.cc

Rob Latham's avatar
Rob Latham committed
58
if BUILD_BWTREE
59 60
#lib_libkvserver_la_SOURCES += src/BwTree/src/bwtree.cpp \
#			      src/datastore/bwtree_datastore.cc
Matthieu Dorier's avatar
Matthieu Dorier committed
61 62 63

lib_libsdskv_server_la_SOURCES += src/BwTree/src/bwtree.cpp \
				  src/datastore/bwtree_datastore.cc
64 65 66
endif

if BUILD_BDB
67 68
#lib_libkvserver_la_SOURCES += src/datastore/berkeleydb_datastore.cc
#
Matthieu Dorier's avatar
Matthieu Dorier committed
69
lib_libsdskv_server_la_SOURCES += src/datastore/berkeleydb_datastore.cc
70 71 72
endif

if BUILD_LEVELDB
73
#lib_libkvserver_la_SOURCES += src/datastore/leveldb_datastore.cc
Matthieu Dorier's avatar
Matthieu Dorier committed
74 75

lib_libsdskv_server_la_SOURCES += src/datastore/leveldb_datastore.cc
Rob Latham's avatar
Rob Latham committed
76 77
endif

78
lib_libsdskv_server_la_LIBADD = ${SERVER_LIBS}
79

80 81
include_HEADERS = include/sdskv-client.h \
		  include/sdskv-server.h \
82 83 84 85
		  include/sdskv-common.h \
		  include/sdskv-client.hpp \
		  include/sdskv-server.hpp \
		  include/sdskv-common.hpp
86

87 88
noinst_HEADERS = src/bulk.h \
		 src/sds-keyval.h \
Matthieu Dorier's avatar
Matthieu Dorier committed
89
		 src/sds-keyval-group.h \
90 91
		 src/sdskv-rpc-types.h \
		 src/datastore/datastore.h \
92
		 src/datastore/map_datastore.h \
93 94 95 96
		 src/datastore/bwtree_datastore.h \
		 src/datastore/leveldb_datastore.h \
		 src/datastore/berkeleydb_datastore.h \
		 src/datastore/datastore_factory.h \
97
		 src/keyval-internal.h \
Rob Latham's avatar
Rob Latham committed
98
		 src/BwTree/src/bwtree.h \
99 100 101
		 src/BwTree/src/atomic_stack.h\
		 src/BwTree/src/bloom_filter.h \
		 src/BwTree/src/sorted_small_set.h
Rob Latham's avatar
Rob Latham committed
102

103
#lib_libkvgroupserver_la_SOURCES = src/kvgroup-server.cc
104

Matthieu Dorier's avatar
Matthieu Dorier committed
105

106 107
TESTS = test/basic.sh 		\
	test/open-test.sh 	\
108
	test/list-db-test.sh	\
109 110 111
       	test/put-test.sh 	\
	test/length-test.sh 	\
	test/get-test.sh 	\
112
	test/erase-test.sh      \
113
	test/list-keys-test.sh  \
114
	test/list-keyvals-test.sh  \
115
	test/list-keys-prefix-test.sh \
116
	test/migrate-test.sh    \
Matthieu Dorier's avatar
Matthieu Dorier committed
117
	test/custom-cmp-test.sh \
118 119
	test/multi-test.sh \
	test/cxx-test.sh
Matthieu Dorier's avatar
Matthieu Dorier committed
120 121 122 123

TESTS_ENVIRONMENT = TIMEOUT="$(TIMEOUT)" \
		    MKTEMP="$(MKTEMP)"

Matthieu Dorier's avatar
Matthieu Dorier committed
124 125 126 127
test_sdskv_open_test_SOURCES = test/sdskv-open-test.cc
test_sdskv_open_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_open_test_LDFLAGS = -Llib -lsdskv-client

128 129 130 131
test_sdskv_list_db_test_SOURCES = test/sdskv-list-db-test.cc
test_sdskv_list_db_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_list_db_test_LDFLAGS = -Llib -lsdskv-client

Matthieu Dorier's avatar
Matthieu Dorier committed
132 133 134
test_sdskv_put_test_SOURCES = test/sdskv-put-test.cc
test_sdskv_put_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_put_test_LDFLAGS = -Llib -lsdskv-client
135

136 137 138 139
test_sdskv_length_test_SOURCES = test/sdskv-length-test.cc
test_sdskv_length_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_length_test_LDFLAGS = -Llib -lsdskv-client

140 141 142 143
test_sdskv_get_test_SOURCES = test/sdskv-get-test.cc
test_sdskv_get_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_get_test_LDFLAGS = -Llib -lsdskv-client

144 145 146 147
test_sdskv_list_keys_test_SOURCES = test/sdskv-list-keys-test.cc
test_sdskv_list_keys_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_list_keys_test_LDFLAGS = -Llib -lsdskv-client

148 149 150 151
test_sdskv_list_keys_prefix_test_SOURCES = test/sdskv-list-keys-prefix-test.cc
test_sdskv_list_keys_prefix_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_list_keys_prefix_test_LDFLAGS = -Llib -lsdskv-client

152 153 154
test_sdskv_list_keyvals_test_SOURCES = test/sdskv-list-kv-test.cc
test_sdskv_list_keyvals_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_list_keyvals_test_LDFLAGS = -Llib -lsdskv-client
155

Matthieu Dorier's avatar
Matthieu Dorier committed
156 157 158 159
test_sdskv_erase_test_SOURCES = test/sdskv-erase-test.cc
test_sdskv_erase_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_erase_test_LDFLAGS = -Llib -lsdskv-client

160 161 162
test_sdskv_custom_cmp_test_SOURCES = test/sdskv-custom-cmp-test.cc
test_sdskv_custom_cmp_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_custom_cmp_test_LDFLAGS = -Llib -lsdskv-client
163

164
test_sdskv_custom_server_daemon_SOURCES = test/sdskv-custom-server-daemon.cc
165 166 167 168
test_sdskv_custom_server_daemon_DEPENDENCIES = lib/libsdskv-server.la
test_sdskv_custom_server_daemon_LDFLAGS = -Llib -lsdskv-server
test_sdskv_custom_server_daemon_LDADD = ${LIBS} -lsdskv-server ${SERVER_LIBS}

169 170 171 172
test_sdskv_migrate_test_SOURCES = test/sdskv-migrate-test.cc
test_sdskv_migrate_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_migrate_test_LDFLAGS = -Llib -lsdskv-client

Matthieu Dorier's avatar
Matthieu Dorier committed
173 174 175 176
test_sdskv_multi_test_SOURCES = test/sdskv-multi-test.cc
test_sdskv_multi_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_multi_test_LDFLAGS = -Llib -lsdskv-client

177 178 179 180
test_sdskv_cxx_test_SOURCES = test/sdskv-cxx-test.cc
test_sdskv_cxx_test_DEPENDENCIES = lib/libsdskv-client.la
test_sdskv_cxx_test_LDFLAGS = -Llib -lsdskv-client

181
pkgconfigdir = $(libdir)/pkgconfig
182 183
pkgconfig_DATA = maint/sdskv-server.pc \
		 maint/sdskv-client.pc
184

185

186