mirror of
https://github.com/ceph/ceph
synced 2025-02-21 01:47:25 +00:00
Merge pull request #18888 from tchaikov/wip-osx
common,test,cmake: various changes to re-enable build on osx Reviewed-by: Sage Weil <sage@redhat.com> Reviewed-by: Willem Jan Withagen <wjw@digiware.nl> Reviewed-by: Casey Bodley <cbodley@redhat.com>
This commit is contained in:
commit
75baa10d19
@ -23,7 +23,11 @@
|
||||
#include <dlfcn.h>
|
||||
|
||||
#define PLUGIN_PREFIX "libceph_"
|
||||
#ifdef __APPLE__
|
||||
#define PLUGIN_SUFFIX ".dylib"
|
||||
#else
|
||||
#define PLUGIN_SUFFIX ".so"
|
||||
#endif
|
||||
#define PLUGIN_INIT_FUNCTION "__ceph_plugin_init"
|
||||
#define PLUGIN_VERSION_FUNCTION "__ceph_plugin_version"
|
||||
|
||||
|
@ -15,6 +15,9 @@
|
||||
#include <sys/stat.h>
|
||||
#include <dirent.h>
|
||||
#include "include/uuid.h"
|
||||
#include "blkdev.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
#ifdef __linux__
|
||||
#include <linux/fs.h>
|
||||
|
@ -6,6 +6,8 @@ set(snappy_sources
|
||||
|
||||
add_library(ceph_snappy SHARED ${snappy_sources})
|
||||
add_dependencies(ceph_snappy ${CMAKE_SOURCE_DIR}/src/ceph_ver.h)
|
||||
target_include_directories(ceph_snappy SYSTEM PRIVATE
|
||||
"${SNAPPY_INCLUDE_DIR}")
|
||||
target_link_libraries(ceph_snappy ${SNAPPY_LIBRARIES})
|
||||
set_target_properties(ceph_snappy PROPERTIES
|
||||
VERSION 2.0.0
|
||||
|
@ -386,7 +386,7 @@ TEST(CompressionPlugin, all)
|
||||
CompressionPlugin *factory = dynamic_cast<CompressionPlugin*>(reg->get_with_load("compressor", "invalid"));
|
||||
EXPECT_FALSE(factory);
|
||||
factory = dynamic_cast<CompressionPlugin*>(reg->get_with_load("compressor", "example"));
|
||||
EXPECT_TRUE(factory);
|
||||
ASSERT_TRUE(factory);
|
||||
stringstream ss;
|
||||
EXPECT_EQ(0, factory->factory(&compressor, &ss));
|
||||
EXPECT_TRUE(compressor.get());
|
||||
|
@ -549,7 +549,7 @@ public:
|
||||
int read_percent;
|
||||
int num_objs;
|
||||
size_t min_obj_len;
|
||||
uint64_t max_obj_len;
|
||||
size_t max_obj_len;
|
||||
size_t min_op_len;
|
||||
size_t max_op_len;
|
||||
size_t max_ops;
|
||||
|
Loading…
Reference in New Issue
Block a user