10225501448 李度 10225101546 陈胤遒 10215501422 高宇菲
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

419 lines
15 KiB

  1. # Copyright 2017 The LevelDB Authors. All rights reserved.
  2. # Use of this source code is governed by a BSD-style license that can be
  3. # found in the LICENSE file. See the AUTHORS file for names of contributors.
  4. cmake_minimum_required(VERSION 3.9)
  5. project(Leveldb VERSION 1.21.0 LANGUAGES C CXX)
  6. # This project can use C11, but will gracefully decay down to C89.
  7. set(CMAKE_C_STANDARD 11)
  8. set(CMAKE_C_STANDARD_REQUIRED OFF)
  9. set(CMAKE_C_EXTENSIONS OFF)
  10. # This project requires C++11.
  11. set(CMAKE_CXX_STANDARD 11)
  12. set(CMAKE_CXX_STANDARD_REQUIRED ON)
  13. set(CMAKE_CXX_EXTENSIONS OFF)
  14. option(LEVELDB_BUILD_TESTS "Build LevelDB's unit tests" ON)
  15. option(LEVELDB_BUILD_BENCHMARKS "Build LevelDB's benchmarks" ON)
  16. option(LEVELDB_INSTALL "Install LevelDB's header and library" ON)
  17. include(TestBigEndian)
  18. test_big_endian(LEVELDB_IS_BIG_ENDIAN)
  19. include(CheckIncludeFile)
  20. check_include_file("unistd.h" HAVE_UNISTD_H)
  21. include(CheckIncludeFileCXX)
  22. check_include_file_cxx("atomic" LEVELDB_ATOMIC_PRESENT)
  23. include(CheckLibraryExists)
  24. check_library_exists(crc32c crc32c_value "" HAVE_CRC32C)
  25. check_library_exists(snappy snappy_compress "" HAVE_SNAPPY)
  26. check_library_exists(tcmalloc malloc "" HAVE_TCMALLOC)
  27. include(CheckSymbolExists)
  28. check_symbol_exists(fdatasync "unistd.h" HAVE_FDATASYNC)
  29. include(CheckCXXSourceCompiles)
  30. # Test whether -Wthread-safety is available. See
  31. # https://clang.llvm.org/docs/ThreadSafetyAnalysis.html
  32. # -Werror is necessary because unknown attributes only generate warnings.
  33. set(OLD_CMAKE_REQUIRED_FLAGS ${CMAKE_REQUIRED_FLAGS})
  34. list(APPEND CMAKE_REQUIRED_FLAGS -Werror -Wthread-safety)
  35. check_cxx_source_compiles("
  36. struct __attribute__((lockable)) Lock {
  37. void Acquire() __attribute__((exclusive_lock_function()));
  38. void Release() __attribute__((unlock_function()));
  39. };
  40. struct ThreadSafeType {
  41. Lock lock_;
  42. int data_ __attribute__((guarded_by(lock_)));
  43. };
  44. int main() { return 0; }
  45. " HAVE_CLANG_THREAD_SAFETY)
  46. set(CMAKE_REQUIRED_FLAGS ${OLD_CMAKE_REQUIRED_FLAGS})
  47. set(LEVELDB_PUBLIC_INCLUDE_DIR "include/leveldb")
  48. set(LEVELDB_PORT_CONFIG_DIR "include/port")
  49. configure_file(
  50. "${PROJECT_SOURCE_DIR}/port/port_config.h.in"
  51. "${PROJECT_BINARY_DIR}/${LEVELDB_PORT_CONFIG_DIR}/port_config.h"
  52. )
  53. include_directories(
  54. "${PROJECT_BINARY_DIR}/include"
  55. "${PROJECT_SOURCE_DIR}"
  56. )
  57. if(BUILD_SHARED_LIBS)
  58. # Only export LEVELDB_EXPORT symbols from the shared library.
  59. add_compile_options(-fvisibility=hidden)
  60. endif(BUILD_SHARED_LIBS)
  61. # POSIX code is specified separately so we can leave it out in the future.
  62. add_library(leveldb_port_posix OBJECT "")
  63. target_sources(leveldb_port_posix
  64. PRIVATE
  65. "${PROJECT_SOURCE_DIR}/port/port_posix.cc"
  66. PUBLIC
  67. # The headers below are dependencies for leveldb, but aren't needed by users
  68. # that link to the installed version of leveldb and rely on its public API.
  69. $<BUILD_INTERFACE:${PROJECT_BINARY_DIR}/${LEVELDB_PORT_CONFIG_DIR}/port_config.h>
  70. $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/port/atomic_pointer.h>
  71. $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/port/port_posix.h>
  72. $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/port/port.h>
  73. )
  74. if(BUILD_SHARED_LIBS)
  75. set_property(TARGET leveldb_port_posix PROPERTY POSITION_INDEPENDENT_CODE ON)
  76. endif(BUILD_SHARED_LIBS)
  77. add_library(leveldb "")
  78. target_sources(leveldb
  79. PRIVATE
  80. "${PROJECT_SOURCE_DIR}/db/builder.cc"
  81. "${PROJECT_SOURCE_DIR}/db/builder.h"
  82. "${PROJECT_SOURCE_DIR}/db/c.cc"
  83. "${PROJECT_SOURCE_DIR}/db/db_impl.cc"
  84. "${PROJECT_SOURCE_DIR}/db/db_impl.h"
  85. "${PROJECT_SOURCE_DIR}/db/db_iter.cc"
  86. "${PROJECT_SOURCE_DIR}/db/db_iter.h"
  87. "${PROJECT_SOURCE_DIR}/db/dbformat.cc"
  88. "${PROJECT_SOURCE_DIR}/db/dbformat.h"
  89. "${PROJECT_SOURCE_DIR}/db/dumpfile.cc"
  90. "${PROJECT_SOURCE_DIR}/db/filename.cc"
  91. "${PROJECT_SOURCE_DIR}/db/filename.h"
  92. "${PROJECT_SOURCE_DIR}/db/log_format.h"
  93. "${PROJECT_SOURCE_DIR}/db/log_reader.cc"
  94. "${PROJECT_SOURCE_DIR}/db/log_reader.h"
  95. "${PROJECT_SOURCE_DIR}/db/log_writer.cc"
  96. "${PROJECT_SOURCE_DIR}/db/log_writer.h"
  97. "${PROJECT_SOURCE_DIR}/db/memtable.cc"
  98. "${PROJECT_SOURCE_DIR}/db/memtable.h"
  99. "${PROJECT_SOURCE_DIR}/db/repair.cc"
  100. "${PROJECT_SOURCE_DIR}/db/skiplist.h"
  101. "${PROJECT_SOURCE_DIR}/db/snapshot.h"
  102. "${PROJECT_SOURCE_DIR}/db/table_cache.cc"
  103. "${PROJECT_SOURCE_DIR}/db/table_cache.h"
  104. "${PROJECT_SOURCE_DIR}/db/version_edit.cc"
  105. "${PROJECT_SOURCE_DIR}/db/version_edit.h"
  106. "${PROJECT_SOURCE_DIR}/db/version_set.cc"
  107. "${PROJECT_SOURCE_DIR}/db/version_set.h"
  108. "${PROJECT_SOURCE_DIR}/db/write_batch_internal.h"
  109. "${PROJECT_SOURCE_DIR}/db/write_batch.cc"
  110. "${PROJECT_SOURCE_DIR}/port/port.h"
  111. "${PROJECT_SOURCE_DIR}/port/thread_annotations.h"
  112. "${PROJECT_SOURCE_DIR}/table/block_builder.cc"
  113. "${PROJECT_SOURCE_DIR}/table/block_builder.h"
  114. "${PROJECT_SOURCE_DIR}/table/block.cc"
  115. "${PROJECT_SOURCE_DIR}/table/block.h"
  116. "${PROJECT_SOURCE_DIR}/table/filter_block.cc"
  117. "${PROJECT_SOURCE_DIR}/table/filter_block.h"
  118. "${PROJECT_SOURCE_DIR}/table/format.cc"
  119. "${PROJECT_SOURCE_DIR}/table/format.h"
  120. "${PROJECT_SOURCE_DIR}/table/iterator_wrapper.h"
  121. "${PROJECT_SOURCE_DIR}/table/iterator.cc"
  122. "${PROJECT_SOURCE_DIR}/table/merger.cc"
  123. "${PROJECT_SOURCE_DIR}/table/merger.h"
  124. "${PROJECT_SOURCE_DIR}/table/table_builder.cc"
  125. "${PROJECT_SOURCE_DIR}/table/table.cc"
  126. "${PROJECT_SOURCE_DIR}/table/two_level_iterator.cc"
  127. "${PROJECT_SOURCE_DIR}/table/two_level_iterator.h"
  128. "${PROJECT_SOURCE_DIR}/util/arena.cc"
  129. "${PROJECT_SOURCE_DIR}/util/arena.h"
  130. "${PROJECT_SOURCE_DIR}/util/bloom.cc"
  131. "${PROJECT_SOURCE_DIR}/util/cache.cc"
  132. "${PROJECT_SOURCE_DIR}/util/coding.cc"
  133. "${PROJECT_SOURCE_DIR}/util/coding.h"
  134. "${PROJECT_SOURCE_DIR}/util/comparator.cc"
  135. "${PROJECT_SOURCE_DIR}/util/crc32c.cc"
  136. "${PROJECT_SOURCE_DIR}/util/crc32c.h"
  137. "${PROJECT_SOURCE_DIR}/util/env_posix.cc"
  138. "${PROJECT_SOURCE_DIR}/util/env.cc"
  139. "${PROJECT_SOURCE_DIR}/util/filter_policy.cc"
  140. "${PROJECT_SOURCE_DIR}/util/hash.cc"
  141. "${PROJECT_SOURCE_DIR}/util/hash.h"
  142. "${PROJECT_SOURCE_DIR}/util/logging.cc"
  143. "${PROJECT_SOURCE_DIR}/util/logging.h"
  144. "${PROJECT_SOURCE_DIR}/util/mutexlock.h"
  145. "${PROJECT_SOURCE_DIR}/util/options.cc"
  146. "${PROJECT_SOURCE_DIR}/util/posix_logger.h"
  147. "${PROJECT_SOURCE_DIR}/util/random.h"
  148. "${PROJECT_SOURCE_DIR}/util/status.cc"
  149. $<TARGET_OBJECTS:leveldb_port_posix>
  150. # Only CMake 3.3+ supports PUBLIC sources in targets exported by "install".
  151. $<$<VERSION_GREATER:CMAKE_VERSION,3.2>:PUBLIC>
  152. "${LEVELDB_PUBLIC_INCLUDE_DIR}/c.h"
  153. "${LEVELDB_PUBLIC_INCLUDE_DIR}/cache.h"
  154. "${LEVELDB_PUBLIC_INCLUDE_DIR}/comparator.h"
  155. "${LEVELDB_PUBLIC_INCLUDE_DIR}/db.h"
  156. "${LEVELDB_PUBLIC_INCLUDE_DIR}/dumpfile.h"
  157. "${LEVELDB_PUBLIC_INCLUDE_DIR}/env.h"
  158. "${LEVELDB_PUBLIC_INCLUDE_DIR}/export.h"
  159. "${LEVELDB_PUBLIC_INCLUDE_DIR}/filter_policy.h"
  160. "${LEVELDB_PUBLIC_INCLUDE_DIR}/iterator.h"
  161. "${LEVELDB_PUBLIC_INCLUDE_DIR}/options.h"
  162. "${LEVELDB_PUBLIC_INCLUDE_DIR}/slice.h"
  163. "${LEVELDB_PUBLIC_INCLUDE_DIR}/status.h"
  164. "${LEVELDB_PUBLIC_INCLUDE_DIR}/table_builder.h"
  165. "${LEVELDB_PUBLIC_INCLUDE_DIR}/table.h"
  166. "${LEVELDB_PUBLIC_INCLUDE_DIR}/write_batch.h"
  167. )
  168. # MemEnv is not part of the interface and could be pulled to a separate library.
  169. target_sources(leveldb
  170. PRIVATE
  171. "${PROJECT_SOURCE_DIR}/helpers/memenv/memenv.cc"
  172. "${PROJECT_SOURCE_DIR}/helpers/memenv/memenv.h"
  173. )
  174. target_include_directories(leveldb
  175. PUBLIC
  176. $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/include>
  177. $<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
  178. )
  179. target_compile_definitions(leveldb
  180. PRIVATE
  181. # Used by include/export.h when building shared libraries.
  182. LEVELDB_COMPILE_LIBRARY
  183. # Used by port/port.h.
  184. LEVELDB_PLATFORM_POSIX=1
  185. )
  186. if(BUILD_SHARED_LIBS)
  187. target_compile_definitions(leveldb
  188. PUBLIC
  189. # Used by include/export.h.
  190. LEVELDB_SHARED_LIBRARY
  191. )
  192. endif(BUILD_SHARED_LIBS)
  193. if(HAVE_CLANG_THREAD_SAFETY)
  194. target_compile_options(leveldb
  195. PUBLIC
  196. -Werror -Wthread-safety)
  197. endif(HAVE_CLANG_THREAD_SAFETY)
  198. # TODO(costan): This is only needed for port_posix.
  199. set(THREADS_PREFER_PTHREAD_FLAG ON)
  200. find_package(Threads REQUIRED)
  201. target_link_libraries(leveldb Threads::Threads)
  202. if(HAVE_CRC32C)
  203. target_link_libraries(leveldb crc32c)
  204. endif(HAVE_CRC32C)
  205. if(HAVE_SNAPPY)
  206. target_link_libraries(leveldb snappy)
  207. endif(HAVE_SNAPPY)
  208. if(HAVE_TCMALLOC)
  209. target_link_libraries(leveldb tcmalloc)
  210. endif(HAVE_TCMALLOC)
  211. add_executable(leveldbutil
  212. "${PROJECT_SOURCE_DIR}/db/leveldbutil.cc"
  213. )
  214. target_link_libraries(leveldbutil leveldb)
  215. if(LEVELDB_BUILD_TESTS)
  216. enable_testing()
  217. function(leveldb_test test_file)
  218. get_filename_component(test_target_name "${test_file}" NAME_WE)
  219. add_executable("${test_target_name}" "")
  220. target_sources("${test_target_name}"
  221. PRIVATE
  222. "${PROJECT_BINARY_DIR}/${LEVELDB_PORT_CONFIG_DIR}/port_config.h"
  223. "${PROJECT_SOURCE_DIR}/util/testharness.cc"
  224. "${PROJECT_SOURCE_DIR}/util/testharness.h"
  225. "${PROJECT_SOURCE_DIR}/util/testutil.cc"
  226. "${PROJECT_SOURCE_DIR}/util/testutil.h"
  227. "${test_file}"
  228. )
  229. if(BUILD_SHARED_LIBS)
  230. # Port functions aren't exposed in the shared library build.
  231. target_sources("${test_target_name}"
  232. PRIVATE
  233. $<TARGET_OBJECTS:leveldb_port_posix>
  234. )
  235. endif(BUILD_SHARED_LIBS)
  236. target_link_libraries("${test_target_name}" leveldb)
  237. target_compile_definitions("${test_target_name}"
  238. PRIVATE
  239. LEVELDB_PLATFORM_POSIX=1
  240. )
  241. add_test(NAME "${test_target_name}" COMMAND "${test_target_name}")
  242. endfunction(leveldb_test)
  243. leveldb_test("${PROJECT_SOURCE_DIR}/db/c_test.c")
  244. leveldb_test("${PROJECT_SOURCE_DIR}/db/fault_injection_test.cc")
  245. leveldb_test("${PROJECT_SOURCE_DIR}/issues/issue178_test.cc")
  246. leveldb_test("${PROJECT_SOURCE_DIR}/issues/issue200_test.cc")
  247. leveldb_test("${PROJECT_SOURCE_DIR}/util/env_test.cc")
  248. if(NOT BUILD_SHARED_LIBS)
  249. leveldb_test("${PROJECT_SOURCE_DIR}/db/autocompact_test.cc")
  250. leveldb_test("${PROJECT_SOURCE_DIR}/db/corruption_test.cc")
  251. leveldb_test("${PROJECT_SOURCE_DIR}/db/db_test.cc")
  252. leveldb_test("${PROJECT_SOURCE_DIR}/db/dbformat_test.cc")
  253. leveldb_test("${PROJECT_SOURCE_DIR}/db/filename_test.cc")
  254. leveldb_test("${PROJECT_SOURCE_DIR}/db/log_test.cc")
  255. leveldb_test("${PROJECT_SOURCE_DIR}/db/recovery_test.cc")
  256. leveldb_test("${PROJECT_SOURCE_DIR}/db/skiplist_test.cc")
  257. leveldb_test("${PROJECT_SOURCE_DIR}/db/version_edit_test.cc")
  258. leveldb_test("${PROJECT_SOURCE_DIR}/db/version_set_test.cc")
  259. leveldb_test("${PROJECT_SOURCE_DIR}/db/write_batch_test.cc")
  260. leveldb_test("${PROJECT_SOURCE_DIR}/helpers/memenv/memenv_test.cc")
  261. leveldb_test("${PROJECT_SOURCE_DIR}/table/filter_block_test.cc")
  262. leveldb_test("${PROJECT_SOURCE_DIR}/table/table_test.cc")
  263. leveldb_test("${PROJECT_SOURCE_DIR}/util/arena_test.cc")
  264. leveldb_test("${PROJECT_SOURCE_DIR}/util/bloom_test.cc")
  265. leveldb_test("${PROJECT_SOURCE_DIR}/util/cache_test.cc")
  266. leveldb_test("${PROJECT_SOURCE_DIR}/util/coding_test.cc")
  267. leveldb_test("${PROJECT_SOURCE_DIR}/util/crc32c_test.cc")
  268. leveldb_test("${PROJECT_SOURCE_DIR}/util/hash_test.cc")
  269. # TODO(costan): This test also uses
  270. # "${PROJECT_SOURCE_DIR}/util/env_posix_test_helper.h"
  271. leveldb_test("${PROJECT_SOURCE_DIR}/util/env_posix_test.cc")
  272. endif(NOT BUILD_SHARED_LIBS)
  273. endif(LEVELDB_BUILD_TESTS)
  274. if(LEVELDB_BUILD_BENCHMARKS)
  275. function(leveldb_benchmark bench_file)
  276. get_filename_component(bench_target_name "${bench_file}" NAME_WE)
  277. add_executable("${bench_target_name}" "")
  278. target_sources("${bench_target_name}"
  279. PRIVATE
  280. "${PROJECT_BINARY_DIR}/${LEVELDB_PORT_CONFIG_DIR}/port_config.h"
  281. "${PROJECT_SOURCE_DIR}/util/histogram.cc"
  282. "${PROJECT_SOURCE_DIR}/util/histogram.h"
  283. "${PROJECT_SOURCE_DIR}/util/testharness.cc"
  284. "${PROJECT_SOURCE_DIR}/util/testharness.h"
  285. "${PROJECT_SOURCE_DIR}/util/testutil.cc"
  286. "${PROJECT_SOURCE_DIR}/util/testutil.h"
  287. "${bench_file}"
  288. )
  289. if(BUILD_SHARED_LIBS)
  290. # Port functions aren't exposed in the shared library build.
  291. target_sources("${bench_target_name}"
  292. PRIVATE
  293. $<TARGET_OBJECTS:leveldb_port_posix>
  294. )
  295. endif(BUILD_SHARED_LIBS)
  296. target_link_libraries("${bench_target_name}" leveldb)
  297. target_compile_definitions("${bench_target_name}"
  298. PRIVATE
  299. LEVELDB_PLATFORM_POSIX=1
  300. )
  301. endfunction(leveldb_benchmark)
  302. if(NOT BUILD_SHARED_LIBS)
  303. leveldb_benchmark("${PROJECT_SOURCE_DIR}/db/db_bench.cc")
  304. endif(NOT BUILD_SHARED_LIBS)
  305. check_library_exists(sqlite3 sqlite3_open "" HAVE_SQLITE3)
  306. if(HAVE_SQLITE3)
  307. leveldb_benchmark("${PROJECT_SOURCE_DIR}/doc/bench/db_bench_sqlite3.cc")
  308. target_link_libraries(db_bench_sqlite3 sqlite3)
  309. endif(HAVE_SQLITE3)
  310. # check_library_exists is insufficient here because the library names have
  311. # different manglings when compiled with clang or gcc, at least when installed
  312. # with Homebrew on Mac.
  313. set(OLD_CMAKE_REQURED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES})
  314. list(APPEND CMAKE_REQUIRED_LIBRARIES kyotocabinet)
  315. check_cxx_source_compiles("
  316. #include <kcpolydb.h>
  317. int main() {
  318. kyotocabinet::TreeDB* db = new kyotocabinet::TreeDB();
  319. delete db;
  320. return 0;
  321. }
  322. " HAVE_KYOTOCABINET)
  323. set(CMAKE_REQUIRED_LIBRARIES ${OLD_CMAKE_REQURED_LIBRARIES})
  324. if(HAVE_KYOTOCABINET)
  325. leveldb_benchmark("${PROJECT_SOURCE_DIR}/doc/bench/db_bench_tree_db.cc")
  326. target_link_libraries(db_bench_tree_db kyotocabinet)
  327. endif(HAVE_KYOTOCABINET)
  328. endif(LEVELDB_BUILD_BENCHMARKS)
  329. if(LEVELDB_INSTALL)
  330. include(GNUInstallDirs)
  331. install(TARGETS leveldb
  332. EXPORT LeveldbTargets
  333. RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
  334. LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
  335. ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
  336. )
  337. install(
  338. FILES
  339. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/c.h"
  340. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/cache.h"
  341. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/comparator.h"
  342. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/db.h"
  343. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/dumpfile.h"
  344. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/env.h"
  345. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/export.h"
  346. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/filter_policy.h"
  347. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/iterator.h"
  348. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/options.h"
  349. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/slice.h"
  350. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/status.h"
  351. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/table_builder.h"
  352. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/table.h"
  353. "${PROJECT_SOURCE_DIR}/${LEVELDB_PUBLIC_INCLUDE_DIR}/write_batch.h"
  354. DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/leveldb
  355. )
  356. include(CMakePackageConfigHelpers)
  357. write_basic_package_version_file(
  358. "${PROJECT_BINARY_DIR}/LeveldbConfigVersion.cmake"
  359. COMPATIBILITY SameMajorVersion
  360. )
  361. install(
  362. EXPORT LeveldbTargets
  363. NAMESPACE Leveldb::
  364. DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/Leveldb"
  365. )
  366. install(
  367. FILES
  368. "${PROJECT_SOURCE_DIR}/cmake/LeveldbConfig.cmake"
  369. "${PROJECT_BINARY_DIR}/LeveldbConfigVersion.cmake"
  370. DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/Leveldb"
  371. )
  372. endif(LEVELDB_INSTALL)