sys-auth/pam-pgsql: fix build with Clang 16

Closes: https://bugs.gentoo.org/871492
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Sam James 2022-10-03 00:04:46 +01:00
parent 7aade44ba5
commit 5bfa0c9d17
No known key found for this signature in database
GPG Key ID: 738409F520DF9190
2 changed files with 23 additions and 1 deletions

View File

@ -0,0 +1,18 @@
From: Sam James <sam@gentoo.org>
Date: Sun, 2 Oct 2022 23:55:21 +0100
Subject: [PATCH] Fix crypt() implicit function declaration
crypt() is POSIX and setting _XOPEN_SOURCE makes glibc inhibit
defining it w/o _DEFAULT_SOURCE.
Bug: https://bugs.gentoo.org/871492
--- a/src/backend_pgsql.c
+++ b/src/backend_pgsql.c
@@ -8,7 +8,6 @@
* William Grzybowski <william@agencialivre.com.br>
*/
-#define _XOPEN_SOURCE 500
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>

View File

@ -1,4 +1,4 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@ -24,6 +24,10 @@ RDEPEND=">=dev-db/postgresql-8.0:=
virtual/libcrypt:="
DEPEND="${RDEPEND}"
PATCHES=(
"${FILESDIR}"/${PN}-0.7.3.2-Fix-crypt-implicit-function-declaration.patch
)
src_configure() {
econf \
--sysconfdir=/etc/security \