diff options
author | DongHun Kwak <dh0128.kwak@samsung.com> | 2020-11-27 14:49:10 +0900 |
---|---|---|
committer | DongHun Kwak <dh0128.kwak@samsung.com> | 2020-11-27 14:49:10 +0900 |
commit | cbc3c6a32d29006dda50336e30b42c25f5ca7454 (patch) | |
tree | f17ed4d8dbc64b4bc08b2bfa230589d3b7c6eaf2 /CMakeLists.txt | |
parent | a997565567d8b30dc3a6f289e72324f8f2085b64 (diff) | |
download | libsolv-cbc3c6a32d29006dda50336e30b42c25f5ca7454.tar.gz libsolv-cbc3c6a32d29006dda50336e30b42c25f5ca7454.tar.bz2 libsolv-cbc3c6a32d29006dda50336e30b42c25f5ca7454.zip |
Imported Upstream version 0.7.11upstream/0.7.11
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 34 |
1 files changed, 21 insertions, 13 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index b7e5d7a..c1ada00 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,6 +17,7 @@ OPTION (ENABLE_RPMPKG "Build with rpm package support?" OFF) OPTION (ENABLE_PUBKEY "Build with pubkey support?" OFF) OPTION (ENABLE_RPMDB_BYRPMHEADER "Build with rpmdb Header support?" OFF) OPTION (ENABLE_RPMDB_LIBRPM "Use librpm to access the rpm database?" OFF) +OPTION (ENABLE_RPMDB_BDB "Use BerkeleyDB to access the rpm database?" OFF) OPTION (ENABLE_RPMPKG_LIBRPM "Use librpm to access rpm header information?" OFF) OPTION (ENABLE_RPMMD "Build with rpmmd repository support?" OFF) OPTION (ENABLE_SUSEREPO "Build with suse repository support?" OFF) @@ -223,19 +224,26 @@ IF (ENABLE_RPMDB OR ENABLE_RPMPKG_LIBRPM) ENDIF (RPMMISC_LIBRARY) ENDIF (RPM5) - # check if rpm contains a bundled berkeley db - CHECK_INCLUDE_FILE(rpm/db.h HAVE_RPM_DB_H) - IF (NOT ENABLE_RPMDB_LIBRPM) - IF (NOT HAVE_RPM_DB_H) - FIND_LIBRARY (DB_LIBRARY NAMES db) - IF (DB_LIBRARY) - SET (RPMDB_LIBRARY ${DB_LIBRARY} ${RPMDB_LIBRARY}) - ENDIF (DB_LIBRARY) - IF (DB_INCLUDE_DIR) - INCLUDE_DIRECTORIES (${DB_INCLUDE_DIR}) - ENDIF (DB_INCLUDE_DIR) - ENDIF (NOT HAVE_RPM_DB_H) - ENDIF (NOT ENABLE_RPMDB_LIBRPM) + IF (ENABLE_RPMDB) + IF (NOT ENABLE_RPMDB_BDB) + SET (ENABLE_RPMDB_LIBRPM ON) + ENDIF (NOT ENABLE_RPMDB_BDB) + + # check if rpm contains a bundled berkeley db + CHECK_INCLUDE_FILE(rpm/db.h HAVE_RPM_DB_H) + IF (NOT ENABLE_RPMDB_LIBRPM) + IF (NOT HAVE_RPM_DB_H) + FIND_LIBRARY (DB_LIBRARY NAMES db) + IF (DB_LIBRARY) + SET (RPMDB_LIBRARY ${DB_LIBRARY} ${RPMDB_LIBRARY}) + ENDIF (DB_LIBRARY) + IF (DB_INCLUDE_DIR) + INCLUDE_DIRECTORIES (${DB_INCLUDE_DIR}) + ENDIF (DB_INCLUDE_DIR) + ENDIF (NOT HAVE_RPM_DB_H) + ENDIF (NOT ENABLE_RPMDB_LIBRPM) + ENDIF (ENABLE_RPMDB) + INCLUDE (CheckLibraryExists) CHECK_LIBRARY_EXISTS(rpmio pgpDigGetParams "" HAVE_PGPDIGGETPARAMS) CHECK_LIBRARY_EXISTS(rpm rpmdbNextIteratorHeaderBlob "" HAVE_RPMDBNEXTITERATORHEADERBLOB) |