mirror of
https://github.com/ceph/ceph
synced 2025-02-21 18:17:42 +00:00
rest-bench: build conditionally
added configure --with-rest-bench, and configure --with-system-libs3 Signed-off-by: Yehuda Sadeh <yehuda@hq.newdream.net>
This commit is contained in:
parent
f60444fbeb
commit
53f642e29a
3
.gitmodules
vendored
3
.gitmodules
vendored
@ -4,3 +4,6 @@
|
||||
[submodule "src/leveldb"]
|
||||
path = src/leveldb
|
||||
url = git://github.com/ceph/leveldb.git
|
||||
[submodule "src/libs3"]
|
||||
path = src/libs3
|
||||
url = git://github.com/ceph/libs3.git
|
||||
|
18
configure.ac
18
configure.ac
@ -308,6 +308,24 @@ AS_IF([test "x$with_system_leveldb" = xcheck],
|
||||
[AC_CHECK_LIB([leveldb], [leveldb_open], [with_system_leveldb=yes], [], [-lsnappy -lpthread])])
|
||||
AM_CONDITIONAL(WITH_SYSTEM_LEVELDB, [ test "$with_system_leveldb" = "yes" ])
|
||||
|
||||
# use system libs3?
|
||||
AC_ARG_WITH([system-libs3],
|
||||
[AS_HELP_STRING([--with-system-libs3], [use system libs3])],
|
||||
,
|
||||
[with_system_libs3=no])
|
||||
AS_IF([test "x$with_system_libs3" = xyes],
|
||||
[AC_CHECK_LIB([s3], [S3_initialize], [true], [AC_MSG_FAILURE([libs3 not found])], [-lpthread])])
|
||||
AS_IF([test "x$with_system_libs3" = xcheck],
|
||||
[AC_SEARCH_LIBS([S3_initialize], [s3], [with_system_libs3=yes], [true], [-lpthread])])
|
||||
AM_CONDITIONAL(WITH_SYSTEM_LIBS3, [ test "$with_system_libs3" = "yes" ])
|
||||
|
||||
# rest-bench?
|
||||
AC_ARG_WITH([rest-bench],
|
||||
[AS_HELP_STRING([--with-rest-bench], [enables rest-bench])],
|
||||
[],
|
||||
[with_rest_bench=no])
|
||||
AM_CONDITIONAL(WITH_REST_BENCH, [ test "$with_rest_bench" = "yes" ])
|
||||
|
||||
# use libaio?
|
||||
AC_ARG_WITH([libaio],
|
||||
[AS_HELP_STRING([--without-libaio], [disable libaio use by journal])],
|
||||
|
@ -1,6 +1,6 @@
|
||||
AUTOMAKE_OPTIONS = gnu
|
||||
SUBDIRS = ocf
|
||||
DIST_SUBDIRS = gtest ocf leveldb
|
||||
SUBDIRS = ocf libs3
|
||||
DIST_SUBDIRS = gtest ocf leveldb libs3
|
||||
CLEANFILES =
|
||||
bin_PROGRAMS =
|
||||
# like bin_PROGRAMS, but these targets are only built for debug builds
|
||||
@ -322,10 +322,23 @@ rados_SOURCES = rados.cc rados_import.cc rados_export.cc rados_sync.cc common/ob
|
||||
rados_LDADD = libglobal.la librados.la $(PTHREAD_LIBS) -lm $(CRYPTO_LIBS) $(EXTRALIBS)
|
||||
bin_PROGRAMS += rados
|
||||
|
||||
if WITH_REST_BENCH
|
||||
|
||||
rest_bench_SOURCES = tools/rest_bench.cc common/obj_bencher.cc
|
||||
rest_bench_LDADD = libglobal.la $(PTHREAD_LIBS) -lm $(CRYPTO_LIBS) $(EXTRALIBS) -ls3
|
||||
rest_bench_LDADD = libglobal.la $(PTHREAD_LIBS) -lm $(CRYPTO_LIBS) $(EXTRALIBS)
|
||||
rest_bench_CXXFLAGS = ${AM_CXXFLAGS}
|
||||
bin_PROGRAMS += rest-bench
|
||||
|
||||
if WITH_SYSTEM_LIBS3
|
||||
rest_bench_LDADD += -ls3
|
||||
else
|
||||
rest_bench_LDADD += libs3/build/lib/libs3.a -lcurl -lxml2
|
||||
rest_bench_CXXFLAGS += -I$(top_srcdir)/src/libs3/inc
|
||||
SUBDIRS += libs3
|
||||
endif
|
||||
|
||||
endif
|
||||
|
||||
scratchtool_SOURCES = scratchtool.c
|
||||
scratchtool_LDADD = librados.la $(PTHREAD_LIBS) -lm $(CRYPTO_LIBS) $(EXTRALIBS)
|
||||
scratchtoolpp_SOURCES = scratchtoolpp.cc
|
||||
@ -1657,7 +1670,6 @@ if WITH_DEBUG
|
||||
bin_PROGRAMS += $(bin_DEBUGPROGRAMS)
|
||||
endif
|
||||
|
||||
|
||||
project.tgz: clean
|
||||
cov-configure -co /usr/bin/gcc
|
||||
cov-configure -co /usr/bin/g++
|
||||
|
1
src/libs3
Submodule
1
src/libs3
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit 7165f83c53b05629bc162765808fabc06f1e7306
|
Loading…
Reference in New Issue
Block a user