]> git-server-git.apps.pok.os.sepia.ceph.com Git - rocksdb.git/commitdiff
Remove -Wno-unused-const-variable
authorIgor Canadi <icanadi@fb.com>
Fri, 4 Apr 2014 23:06:08 +0000 (16:06 -0700)
committerIgor Canadi <icanadi@fb.com>
Fri, 4 Apr 2014 23:15:47 +0000 (16:15 -0700)
Makefile
include/rocksdb/perf_context.h
table/block_based_table_reader.cc

index a578c12c8e1ea313743430cc282edac3fe9f621c..258b951ae945cdfa4303dedb6820aed25bcc6f2e 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -44,7 +44,7 @@ else
        PLATFORM_CCFLAGS += $(JEMALLOC_INCLUDE) -DHAVE_JEMALLOC
 endif
 
-WARNING_FLAGS = -Wall -Werror -Wno-sign-compare -Wno-unused-const-variable
+WARNING_FLAGS = -Wall -Werror -Wno-sign-compare
 CFLAGS += $(WARNING_FLAGS) -I. -I./include $(PLATFORM_CCFLAGS) $(OPT)
 CXXFLAGS += $(WARNING_FLAGS) -I. -I./include $(PLATFORM_CXXFLAGS) $(OPT) -Woverloaded-virtual
 
index 45399ac2d5003ea72dd0e383a0c204830128e532..63eddb61d53dcad2d8210a8080f4958414429dc4 100644 (file)
@@ -64,7 +64,7 @@ struct PerfContext {
   uint64_t write_memtable_time;
 };
 
-#if defined(OS_MACOSX)
+#if defined(IOS_CROSS_COMPILE)
 extern PerfContext perf_context;
 #else
 extern __thread PerfContext perf_context;
index c3adf3ac53c32c5acb79e5427b3b700935a0ec0b..967836811eba69cb98181dbd762ca25eeeb3aff9 100644 (file)
@@ -45,7 +45,9 @@ namespace {
 // The longest the prefix of the cache key used to identify blocks can be.
 // We are using the fact that we know for Posix files the unique ID is three
 // varints.
-const size_t kMaxCacheKeyPrefixSize = kMaxVarint64Length*3+1;
+// For some reason, compiling for iOS complains that this variable is unused
+const size_t kMaxCacheKeyPrefixSize __attribute__((unused)) =
+    kMaxVarint64Length * 3 + 1;
 
 // Read the block identified by "handle" from "file".
 // The only relevant option is options.verify_checksums for now.