From c3d903c0e929207d42e9dcd31294da12e1c5b6dd Mon Sep 17 00:00:00 2001 From: Martin Dummer Date: Tue, 10 Nov 2026 23:30:28 +0100 Subject: [PATCH] app-admin/passwordsafe: add 1.26.1 Signed-off-by: Martin Dummer Part-of: https://github.com/gentoo/gentoo/pull/47035 Closes: https://github.com/gentoo/gentoo/pull/47035 Signed-off-by: Sam James --- app-admin/passwordsafe/Manifest | 1 + .../files/passwordsafe-1.26.1-CMake.patch | 37 ++++++++++ .../passwordsafe/passwordsafe-1.26.1.ebuild | 70 +++++++++++++++++++ 3 files changed, 108 insertions(+) create mode 100644 app-admin/passwordsafe/files/passwordsafe-1.26.1-CMake.patch create mode 100644 app-admin/passwordsafe/passwordsafe-1.26.1.ebuild diff --git a/app-admin/passwordsafe/Manifest b/app-admin/passwordsafe/Manifest index ecb27c503ab68..19ad3b1dbbbdd 100644 --- a/app-admin/passwordsafe/Manifest +++ b/app-admin/passwordsafe/Manifest @@ -1,3 +1,4 @@ DIST passwordsafe-1.22.0.tar.gz 17674235 BLAKE2B af9adf2040c42a853aad18d2e9bcf7216f0a7f5364c730b2d7bcbcabcc762fc31f82d52d898a326efdb67d86069b6dfa6229101d51e8d82f40338ef7daf6efaa SHA512 ff787b08653a923b6f542754e1d9cadc60fb37892a428ac5206cf05ab5a8f29e66c8c2791c826f40c2f27cabcdd704f54a4fbdd330177b7b1825e3e72698860e DIST passwordsafe-1.23.0.tar.gz 26471858 BLAKE2B a5dd7be4f81a3fccdc155d4d5acf72093b873f10bcad43021ede92e5f1778b38435d921ddd0448ac72c21e77de41b732bdba13463d8d3d5f60aef6eb7dc54a0e SHA512 8fe2ee5603ab2c7287d8bc1ff4a16e79ed7fbdd703d235ac1533e7d236658cba5812e6d8a402ad318188128cb76640d396874889328fa9388fb371cdb7f6a145 DIST passwordsafe-1.26.0.tar.gz 24007676 BLAKE2B bf8bdb6eaec037565de51ddda4301f27cafae805e88ecd63b32cc6a65d6b479c5c0110017a81049fd6fdedc5c2cec4e51639155920e61be6d97fe882bb8fd4c7 SHA512 89a16229139f9c76cc303534801678927734bb04935d98bfecc590b60a5bad76953aeafafa4575c2c9c2b4408d1851444742ed921d642b5655c3a1d90f5f860d +DIST passwordsafe-1.26.1.tar.gz 24515129 BLAKE2B 18c2bbc741477d1de135928cb3914ab4d45223efbabafaf60ecccefa150c2cd72a24ad3e62fb7d2de8c0954702b62bdc402926a359d3e59230dc1bafacbbb791 SHA512 01e2c7b60d5709284e98ce91d220c36a18f097e1791274ec59208376e4e1fd63b9501099709ff6547cc7a5fcd6f597967e48d7542209009d2178dcff8681c4a8 diff --git a/app-admin/passwordsafe/files/passwordsafe-1.26.1-CMake.patch b/app-admin/passwordsafe/files/passwordsafe-1.26.1-CMake.patch new file mode 100644 index 0000000000000..822a182f41bb1 --- /dev/null +++ b/app-admin/passwordsafe/files/passwordsafe-1.26.1-CMake.patch @@ -0,0 +1,37 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -219,12 +219,6 @@ + else () + set(CMAKE_CXX_FLAGS + "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wpedantic -DUNICODE -DWCHAR_INCOMPATIBLE_XMLCH ${CMAKE_WXWINDOWS_CXX_FLAGS}") +- if (${CMAKE_SYSTEM_NAME} MATCHES "Linux") +- # TODO: with the below flag the Mac and BSD cmake-based builds fail with an error such as: +- # clang: error: argument unused during compilation: '-fstack-clash-protection' +- # it's possible check_cxx_compiler_flag is using the wrong compiler for the check? +- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror") +- endif (${CMAKE_SYSTEM_NAME} MATCHES "Linux") + set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -D_DEBUG -DDEBUG") + if (USE_ASAN) + set(CMAKE_CXX_FLAGS_DEBUG +@@ -379,8 +379,9 @@ + COMMAND ${GZIP} ARGS -9 -n -c ${PROJECT_SOURCE_DIR}/docs/pwsafe-cli.1 > pwsafe-cli.1.gz + WORKING_DIRECTORY ${CMAKE_BINARY_DIR}) + ADD_CUSTOM_TARGET(manpage ALL DEPENDS ${CMAKE_BINARY_DIR}/pwsafe.1.gz ${CMAKE_BINARY_DIR}/pwsafe-cli.1.gz) +- install (FILES ${CMAKE_BINARY_DIR}/pwsafe.1.gz ${CMAKE_BINARY_DIR}/pwsafe-cli.1.gz DESTINATION "share/man/man1") +- install (FILES "install/desktop/pwsafe.desktop" DESTINATION "share/applications") ++ install (FILES ${PROJECT_SOURCE_DIR}/docs/pwsafe.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1 RENAME passwordsafe.1) ++ install (FILES ${PROJECT_SOURCE_DIR}/docs/pwsafe-cli.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1 RENAME passwordsafe-cli.1) ++ install (FILES "install/desktop/pwsafe.desktop" DESTINATION "share/applications" RENAME "passwordsafe.desktop") + install (FILES "install/metainfo/org.pwsafe.pwsafe.metainfo.xml" DESTINATION "share/metainfo") + install (FILES "install/graphics/48x48/pwsafe.png" DESTINATION "share/icons/hicolor/48x48/apps/") + install (FILES "install/graphics/128x128/pwsafe.png" DESTINATION "share/icons/hicolor/128x128/apps/") +--- a/CMakeModules/harden/harden-gcc.cmake ++++ b/CMakeModules/harden/harden-gcc.cmake +@@ -42,7 +42,6 @@ + + harden_add_compile_option(-Wformat HARDEN_COMPILE_WFORMAT FALSE) + harden_add_compile_option(-Wformat-security HARDEN_COMPILE_WFORMAT_SECURITY FALSE) +-harden_add_compile_option(-Werror=format-security HARDEN_COMPILE_WERROR_FORMAT_SECURITY FALSE) + harden_add_compile_option(-fstack-clash-protection HARDEN_COMPILE_STACK_CLASH_PROTECTION FALSE) + + option(HARDEN_USE_SAFE_STACK "Enable the SafeStack sanitizer" ON) diff --git a/app-admin/passwordsafe/passwordsafe-1.26.1.ebuild b/app-admin/passwordsafe/passwordsafe-1.26.1.ebuild new file mode 100644 index 0000000000000..7d61bfbdb136c --- /dev/null +++ b/app-admin/passwordsafe/passwordsafe-1.26.1.ebuild @@ -0,0 +1,70 @@ +# Copyright 2021-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +WX_GTK_VER="3.2-gtk3" + +inherit cmake optfeature wxwidgets xdg + +MY_PV="${PV/_beta/BETA}" +DESCRIPTION="Password manager with wxGTK based frontend" +HOMEPAGE="https://pwsafe.org/ https://github.com/pwsafe/pwsafe/" +SRC_URI="https://github.com/pwsafe/pwsafe/archive/${MY_PV}.tar.gz -> ${P}.tar.gz" +S="${WORKDIR}/pwsafe-${MY_PV}" + +LICENSE="Artistic-2" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~x86" +IUSE="qr test +xml yubikey" +RESTRICT="!test? ( test )" + +RDEPEND=" + net-misc/curl + sys-apps/file + sys-apps/util-linux + x11-libs/libX11 + x11-libs/libXt + x11-libs/libXtst + x11-libs/wxGTK:${WX_GTK_VER}=[X] + qr? ( media-gfx/qrencode:= ) + xml? ( dev-libs/xerces-c:= ) + yubikey? ( sys-auth/ykpers )" +DEPEND="${RDEPEND} + x11-base/xorg-proto" +BDEPEND=" + app-arch/zip + dev-lang/perl + sys-devel/gettext + virtual/pkgconfig + test? ( dev-cpp/gtest )" + +PATCHES=( "${FILESDIR}/${P}-CMake.patch" ) + +src_configure() { + setup-wxwidgets + + local mycmakeargs=( + -DNO_QR=$(usex !qr) + -DNO_GTEST=$(usex !test) + -DGTEST_BUILD=OFF + -DXML_XERCESC=$(usex xml) + -DNO_YUBI=$(usex !yubikey) + ) + + cmake_src_configure +} + +src_install() { + cmake_src_install + + pushd "${BUILD_DIR}" || die + dosym pwsafe /usr/bin/${PN} + dosym pwsafe-cli /usr/bin/${PN}-cli +} + +pkg_postinst() { + xdg_desktop_database_update + xdg_icon_cache_update + optfeature "on-screen keyboard for password entry" x11-misc/xvkbd +}