git: 67237e5afd19 - main - textproc/augeas: fix build with clang 16

From: Dimitry Andric <dim_at_FreeBSD.org>
Date: Thu, 18 May 2023 11:41:02 UTC
The branch main has been updated by dim:

URL: https://cgit.FreeBSD.org/ports/commit/?id=67237e5afd193f57fb2153072d01d6645eb79b5c

commit 67237e5afd193f57fb2153072d01d6645eb79b5c
Author:     Dimitry Andric <dim@FreeBSD.org>
AuthorDate: 2023-05-08 08:37:41 +0000
Commit:     Dimitry Andric <dim@FreeBSD.org>
CommitDate: 2023-05-18 11:33:25 +0000

    textproc/augeas: fix build with clang 16
    
    Clang 16 has a new error about incompatible integer to pointer
    conversions, which shows up when building textproc/augeas:
    
      augprint.c:1477:24: warning: call to undeclared function 'basename'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
        char *program_name = basename(argv[0]);
                             ^
      augprint.c:1477:9: error: incompatible integer to pointer conversion initializing 'char *' with an expression of type 'int' [-Wint-conversion]
        char *program_name = basename(argv[0]);
              ^              ~~~~~~~~~~~~~~~~~
    
    This is because basename(3) is declared in <libgen.h>, but augprint.c
    does not include it. Upstream has already fixed this, so apply the
    commit until there is a new release.
    
    PR:             271316
    Approved by:    portmgr (build fix blanket)
    MFH:            2023Q2
---
 textproc/augeas/Makefile | 4 ++++
 textproc/augeas/distinfo | 4 +++-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/textproc/augeas/Makefile b/textproc/augeas/Makefile
index ef9107cefc1b..015dc60bc031 100644
--- a/textproc/augeas/Makefile
+++ b/textproc/augeas/Makefile
@@ -1,8 +1,12 @@
 PORTNAME=	augeas
 DISTVERSION=	1.14.0
+PORTREVISION=	1
 CATEGORIES=	textproc
 MASTER_SITES=	https://github.com/hercules-team/augeas/releases/download/release-${DISTVERSION}/
 
+PATCH_SITES=	https://github.com/hercules-team/augeas/commit/
+PATCHFILES+=	7b26cbb74ed634d886ed842e3d5495361d8fd9b1.patch:-p1 # https://github.com/hercules-team/augeas/pull/792
+
 MAINTAINER=	puppet@FreeBSD.org
 COMMENT=	Configuration editing tool
 WWW=		https://augeas.net/
diff --git a/textproc/augeas/distinfo b/textproc/augeas/distinfo
index dd0c8f9c11b3..da7e25700d38 100644
--- a/textproc/augeas/distinfo
+++ b/textproc/augeas/distinfo
@@ -1,3 +1,5 @@
-TIMESTAMP = 1683030743
+TIMESTAMP = 1683741338
 SHA256 (augeas-1.14.0.tar.gz) = 8c101759ca3d504bd1d805e70e2f615fa686af189dd7cf0529f71d855c087df1
 SIZE (augeas-1.14.0.tar.gz) = 2651463
+SHA256 (7b26cbb74ed634d886ed842e3d5495361d8fd9b1.patch) = 08b0dbf7f303cd7cb341e2dff13f9b5df7042c2171dcfc89ed00d1d8f4886983
+SIZE (7b26cbb74ed634d886ed842e3d5495361d8fd9b1.patch) = 1239