app-admin/passwordsafe: fix build with GCC 12

Closes: https://bugs.gentoo.org/854144
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Sam James
2022-06-30 21:32:25 +00:00
parent 5a76bbcc1f
commit 1cb089fd5c
2 changed files with 17 additions and 0 deletions

View File

@@ -0,0 +1,13 @@
https://bugs.gentoo.org/854144
--- a/src/os/unix/pws_time.h
+++ b/src/os/unix/pws_time.h
@@ -10,9 +10,7 @@
#include "../typedefs.h"
#include <stdint.h>
-#ifdef __FreeBSD__
#include <time.h>
-#endif
#ifndef __TIME64_T_TYPE
#define __TIME64_T_TYPE uint64_t

View File

@@ -37,6 +37,10 @@ BDEPEND="
S="${WORKDIR}/pwsafe-${MY_PV}"
PATCHES=(
"${FILESDIR}"/${PN}-1.15.0-gcc12-time.patch
)
pkg_pretend() {
einfo "Checking for -std=c++11 support in compiler"
test-flags-CXX -std=c++11 > /dev/null || die