Fix LITE build (#8689)
Summary: Conditional compilation of static functions not used in LITE mode. Pull Request resolved: https://github.com/facebook/rocksdb/pull/8689 Reviewed By: ltamasi Differential Revision: D30476218 Pulled By: mrambacher fbshipit-source-id: 5f3af90982d34818f47d2cb1d36dd5816d0333a5
This commit is contained in:
parent
8c9e689790
commit
c2c92f3013
@ -66,6 +66,7 @@ class TestCustomizable : public Customizable {
|
|||||||
|
|
||||||
const char* Name() const override { return name_.c_str(); }
|
const char* Name() const override { return name_.c_str(); }
|
||||||
static const char* Type() { return "test.custom"; }
|
static const char* Type() { return "test.custom"; }
|
||||||
|
#ifndef ROCKSDB_LITE
|
||||||
static Status CreateFromString(const ConfigOptions& opts,
|
static Status CreateFromString(const ConfigOptions& opts,
|
||||||
const std::string& value,
|
const std::string& value,
|
||||||
std::unique_ptr<TestCustomizable>* result);
|
std::unique_ptr<TestCustomizable>* result);
|
||||||
@ -75,6 +76,7 @@ class TestCustomizable : public Customizable {
|
|||||||
static Status CreateFromString(const ConfigOptions& opts,
|
static Status CreateFromString(const ConfigOptions& opts,
|
||||||
const std::string& value,
|
const std::string& value,
|
||||||
TestCustomizable** result);
|
TestCustomizable** result);
|
||||||
|
#endif // ROCKSDB_LITE
|
||||||
bool IsInstanceOf(const std::string& name) const override {
|
bool IsInstanceOf(const std::string& name) const override {
|
||||||
if (name == kClassName()) {
|
if (name == kClassName()) {
|
||||||
return true;
|
return true;
|
||||||
@ -146,6 +148,7 @@ class BCustomizable : public TestCustomizable {
|
|||||||
BOptions opts_;
|
BOptions opts_;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifndef ROCKSDB_LITE
|
||||||
static bool LoadSharedB(const std::string& id,
|
static bool LoadSharedB(const std::string& id,
|
||||||
std::shared_ptr<TestCustomizable>* result) {
|
std::shared_ptr<TestCustomizable>* result) {
|
||||||
if (id == "B") {
|
if (id == "B") {
|
||||||
@ -159,7 +162,6 @@ static bool LoadSharedB(const std::string& id,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef ROCKSDB_LITE
|
|
||||||
static int A_count = 0;
|
static int A_count = 0;
|
||||||
static int RegisterCustomTestObjects(ObjectLibrary& library,
|
static int RegisterCustomTestObjects(ObjectLibrary& library,
|
||||||
const std::string& /*arg*/) {
|
const std::string& /*arg*/) {
|
||||||
@ -241,6 +243,7 @@ static void GetMapFromProperties(
|
|||||||
#endif // ROCKSDB_LITE
|
#endif // ROCKSDB_LITE
|
||||||
} // namespace
|
} // namespace
|
||||||
|
|
||||||
|
#ifndef ROCKSDB_LITE
|
||||||
Status TestCustomizable::CreateFromString(
|
Status TestCustomizable::CreateFromString(
|
||||||
const ConfigOptions& config_options, const std::string& value,
|
const ConfigOptions& config_options, const std::string& value,
|
||||||
std::shared_ptr<TestCustomizable>* result) {
|
std::shared_ptr<TestCustomizable>* result) {
|
||||||
@ -285,6 +288,7 @@ Status TestCustomizable::CreateFromString(const ConfigOptions& config_options,
|
|||||||
},
|
},
|
||||||
result);
|
result);
|
||||||
}
|
}
|
||||||
|
#endif // ROCKSDB_LITE
|
||||||
|
|
||||||
class CustomizableTest : public testing::Test {
|
class CustomizableTest : public testing::Test {
|
||||||
public:
|
public:
|
||||||
|
Loading…
Reference in New Issue
Block a user