diff --git a/srcpkgs/passwordsafe/patches/use-gtest-from-package.patch b/srcpkgs/passwordsafe/patches/use-gtest-from-package.patch new file mode 100644 index 0000000000..240d3fd0e3 --- /dev/null +++ b/srcpkgs/passwordsafe/patches/use-gtest-from-package.patch @@ -0,0 +1,37 @@ +--- CMakeLists.txt.ORIG 2021-02-25 23:45:37.917034534 +0100 ++++ CMakeLists.txt 2021-02-26 00:05:34.138397928 +0100 +@@ -255,34 +255,6 @@ + endif (USE_ASAN) + endif (MSVC) + +-if (NOT NO_GTEST) +- # Download and unpack googletest at configure time +- # See https://crascit.com/2015/07/25/cmake-gtest/ +- configure_file(Misc/CMakeLists.gtest.txt.in googletest-download/CMakeLists.txt) +- execute_process(COMMAND "${CMAKE_COMMAND}" -G "${CMAKE_GENERATOR}" . +- WORKING_DIRECTORY "${CMAKE_BINARY_DIR}/googletest-download" ) +- execute_process(COMMAND "${CMAKE_COMMAND}" --build . +- WORKING_DIRECTORY "${CMAKE_BINARY_DIR}/googletest-download" ) +- +- # Prevent GoogleTest from overriding our compiler/linker options +- # when building with Visual Studio +- set(gtest_force_shared_crt ON CACHE BOOL "" FORCE) +- # Set some other gtest configurations: +- set(BUILD_GMOCK OFF CACHE BOOL "" FORCE) +- set(BUILD_GTEST ON CACHE BOOL "" FORCE) +- set(INSTALL_GTEST OFF CACHE BOOL "" FORCE) +- +- # Add googletest directly to our build. This adds +- # the following targets: gtest, gtest_main, gmock +- # and gmock_main +- add_subdirectory("${CMAKE_BINARY_DIR}/googletest-src" +- "${CMAKE_BINARY_DIR}/googletest-build") +- +- include_directories("${gtest_SOURCE_DIR}/include" +-# "${gmock_SOURCE_DIR}/include" +- ) +-endif(NOT NO_GTEST) +- + if (WIN32 AND NOT WX_WINDOWS) + set(VERSION_IN "${PROJECT_SOURCE_DIR}/src/ui/Windows/version.in") + else (WIN32 AND NOT WX_WINDOWS) diff --git a/srcpkgs/passwordsafe/template b/srcpkgs/passwordsafe/template index 435612f3ae..2cd6ee12a1 100644 --- a/srcpkgs/passwordsafe/template +++ b/srcpkgs/passwordsafe/template @@ -1,22 +1,27 @@ # Template file for 'passwordsafe' pkgname=passwordsafe -version=1.12.0 +version=1.13.0 revision=1 wrksrc="pwsafe-${version}" build_style=cmake build_helper=cmake-wxWidgets-gtk3 -# testing disabled: want to build gtest from source (package gtest-devel useless) -configure_args="-DNO_GTEST=ON" # build process uses perl to generate core_st.cpp and zip to generate help files hostmakedepends="perl zip pkg-config gettext" makedepends="wxWidgets-gtk3-devel libXt-devel libXtst-devel libxerces-c-devel libuuid-devel libykpers-devel qrencode-devel libressl-devel libcurl-devel file-devel" +checkdepends="gtest-devel" short_desc="Simple & Secure Password Management" maintainer="Rui Abreu Ferreira " license="Artistic-2.0" homepage="https://pwsafe.org" distfiles="https://github.com/pwsafe/pwsafe/archive/${version}.tar.gz" -checksum=8d331019170f2920a28ccda08ae420c78e016f41d3ccedb7b4dba1f5f7f25bcb +checksum=8962edf57b7f901d9ed23496c8ec387a4f186855976e8ac98f2dd55560c82ebe + +if [ "$XBPS_CHECK_PKGS" ]; then + configure_args+=" -DNO_GTEST=OFF" +else + configure_args+=" -DNO_GTEST=ON" +fi pre_configure() { # ykpers-1 includes are hardcoded, add cross base