mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-01-03 19:50:55 -05:00
Merge pull request #701 from LocutusOfBorg/zxcvbn
detect system zxcvbn library
This commit is contained in:
commit
0359c1845a
@ -27,6 +27,13 @@ if (NOT GIT_HEAD OR NOT GIT_DESCRIBE)
|
|||||||
set(GIT_DESCRIBE "")
|
set(GIT_DESCRIBE "")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
find_library(ZXCVBN_LIBRARIES zxcvbn)
|
||||||
|
if(NOT ZXCVBN_LIBRARIES)
|
||||||
|
add_library(zxcvbn STATIC zxcvbn/zxcvbn.cpp)
|
||||||
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/zxcvbn)
|
||||||
|
set(ZXCVBN_LIBRARIES zxcvbn)
|
||||||
|
endif(NOT ZXCVBN_LIBRARIES)
|
||||||
|
|
||||||
configure_file(version.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/version.h @ONLY)
|
configure_file(version.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/version.h @ONLY)
|
||||||
|
|
||||||
set(keepassx_SOURCES
|
set(keepassx_SOURCES
|
||||||
@ -203,9 +210,6 @@ else()
|
|||||||
list(APPEND keepassx_SOURCES keys/drivers/YubiKeyStub.cpp)
|
list(APPEND keepassx_SOURCES keys/drivers/YubiKeyStub.cpp)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
add_library(zxcvbn STATIC zxcvbn/zxcvbn.cpp)
|
|
||||||
target_link_libraries(zxcvbn)
|
|
||||||
|
|
||||||
add_library(autotype STATIC ${autotype_SOURCES})
|
add_library(autotype STATIC ${autotype_SOURCES})
|
||||||
target_link_libraries(autotype Qt5::Core Qt5::Widgets)
|
target_link_libraries(autotype Qt5::Core Qt5::Widgets)
|
||||||
|
|
||||||
@ -218,7 +222,7 @@ target_link_libraries(keepassx_core
|
|||||||
${keepasshttp_LIB}
|
${keepasshttp_LIB}
|
||||||
${autotype_LIB}
|
${autotype_LIB}
|
||||||
${YUBIKEY_LIBRARIES}
|
${YUBIKEY_LIBRARIES}
|
||||||
zxcvbn
|
${ZXCVBN_LIBRARIES}
|
||||||
Qt5::Core
|
Qt5::Core
|
||||||
Qt5::Network
|
Qt5::Network
|
||||||
Qt5::Concurrent
|
Qt5::Concurrent
|
||||||
|
@ -38,7 +38,7 @@ target_link_libraries(keepassxc-cli
|
|||||||
${GCRYPT_LIBRARIES}
|
${GCRYPT_LIBRARIES}
|
||||||
${GPGERROR_LIBRARIES}
|
${GPGERROR_LIBRARIES}
|
||||||
${ZLIB_LIBRARIES}
|
${ZLIB_LIBRARIES}
|
||||||
zxcvbn)
|
${ZXCVBN_LIBRARIES})
|
||||||
|
|
||||||
install(TARGETS keepassxc-cli
|
install(TARGETS keepassxc-cli
|
||||||
BUNDLE DESTINATION . COMPONENT Runtime
|
BUNDLE DESTINATION . COMPONENT Runtime
|
||||||
|
@ -20,7 +20,7 @@
|
|||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "zxcvbn/zxcvbn.h"
|
#include <zxcvbn.h>
|
||||||
|
|
||||||
/* For pre-compiled headers under windows */
|
/* For pre-compiled headers under windows */
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
|
@ -19,7 +19,7 @@
|
|||||||
#include "PasswordGenerator.h"
|
#include "PasswordGenerator.h"
|
||||||
|
|
||||||
#include "crypto/Random.h"
|
#include "crypto/Random.h"
|
||||||
#include "zxcvbn/zxcvbn.h"
|
#include <zxcvbn.h>
|
||||||
|
|
||||||
PasswordGenerator::PasswordGenerator()
|
PasswordGenerator::PasswordGenerator()
|
||||||
: m_length(0)
|
: m_length(0)
|
||||||
|
Loading…
Reference in New Issue
Block a user