summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorAllen Winter <allen.winter@kdab.com>2022-01-16 09:35:17 -0500
committerAllen Winter <allen.winter@kdab.com>2022-01-16 09:37:32 -0500
commit905cbb44d02c8e8f922099432cc6b6a1beeddd88 (patch)
tree6e221e30ca4d295b8f19fbfad0e47b23a5d960c4 /CMakeLists.txt
parentd7e46baed224ca54e448fd506c9271e7da21b28f (diff)
downloadlibical-git-905cbb44d02c8e8f922099432cc6b6a1beeddd88.tar.gz
buildsystem - replace our ancient FindBDB with more modern FindBerkeleyDB
Copied from https://github.com/sum01/FindBerkeleyDB This file has an "unlicense"
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt12
1 files changed, 8 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 9553cbf5..8f9df2be 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -235,19 +235,23 @@ if(ICU_FOUND)
endif()
# compile in Berkeley DB support
-find_package(BDB)
-set_package_properties(BDB PROPERTIES
+find_package(BerkeleyDB)
+set_package_properties(BerkeleyDB PROPERTIES
TYPE OPTIONAL
PURPOSE "For Berkeley DB storage support"
)
add_feature_info(
"Berkeley DB storage support"
- BDB_FOUND
+ BerkeleyDB_FOUND
"build in support for Berkeley DB storage"
)
-if(BDB_FOUND)
+if(BerkeleyDB_FOUND)
set(HAVE_BDB True)
add_definitions(-DDB_DBM_HSEARCH=0) #set to 1 if hsearch support is needed
+ #for compatibility to our old FindBDB
+ set(BDB_FOUND True)
+ set(BDB_INCLUDE_DIR ${BerkeleyDB_INCLUDE_DIRS})
+ set(BDB_LIBRARY ${BerkeleyDB_LIBRARIES})
endif()
# MSVC specific definitions