git: 8f813cf05f6a - main - devel/fnc: Update to 0.16

From: Ashish SHUKLA <ashish_at_FreeBSD.org>
Date: Mon, 27 Nov 2023 08:24:16 UTC
The branch main has been updated by ashish:

URL: https://cgit.FreeBSD.org/ports/commit/?id=8f813cf05f6a3bee6f2b89c2009c0580c1e81747

commit 8f813cf05f6a3bee6f2b89c2009c0580c1e81747
Author:     Ashish SHUKLA <ashish@FreeBSD.org>
AuthorDate: 2023-11-27 08:18:56 +0000
Commit:     Ashish SHUKLA <ashish@FreeBSD.org>
CommitDate: 2023-11-27 08:22:07 +0000

    devel/fnc: Update to 0.16
---
 devel/fnc/Makefile               |  6 ++++--
 devel/fnc/distinfo               |  6 +++---
 devel/fnc/files/patch-fnc.bld.mk | 27 ++++++++++++++++++++-------
 3 files changed, 27 insertions(+), 12 deletions(-)

diff --git a/devel/fnc/Makefile b/devel/fnc/Makefile
index 32269cd9a2cb..acff863f8c83 100644
--- a/devel/fnc/Makefile
+++ b/devel/fnc/Makefile
@@ -1,5 +1,5 @@
 PORTNAME=	fnc
-DISTVERSION=	0.15
+DISTVERSION=	0.16
 CATEGORIES=	devel
 MASTER_SITES=	https://fnc.bsdbox.org/tarball/${DISTVERSION}/ \
 		https://distfiles.pirateparty.in/ashish/
@@ -12,6 +12,7 @@ LICENSE=	ISCL
 LICENSE_FILE=	${WRKSRC}/LICENSE
 
 USES=		ncurses
+MAKE_JOBS_UNSAFE=	yes
 
 PLIST_FILES=	bin/fnc \
 		man/man1/fnc.1.gz
@@ -22,7 +23,8 @@ post-extract:
 		${WRKSRC}/fnc.bld.mk
 
 pre-build:
-	${REINPLACE_CMD} -e '/^VERSION/s/%%VERSION%%/${DISTVERSION}$$/' \
+	${REINPLACE_CMD} -e '/^VERSION/s/%%VERSION%%/${DISTVERSION}/' \
+		-e 's,%%PREFIX%%,${PREFIX},' \
 		${WRKSRC}/fnc.bld.mk
 
 .include <bsd.port.mk>
diff --git a/devel/fnc/distinfo b/devel/fnc/distinfo
index f2704bf0d69c..bd869aeed717 100644
--- a/devel/fnc/distinfo
+++ b/devel/fnc/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1682800264
-SHA256 (fnc-0.15.tar.gz) = f2ea7ce387a420e31c3e57c1d8327347f1a0258f6cfec05e6291be62d75abaf5
-SIZE (fnc-0.15.tar.gz) = 3169205
+TIMESTAMP = 1701071597
+SHA256 (fnc-0.16.tar.gz) = e88eb0b5230768a7679542b8a5889ac9b25e3831aed8ffac9985bc9500c85863
+SIZE (fnc-0.16.tar.gz) = 3232489
diff --git a/devel/fnc/files/patch-fnc.bld.mk b/devel/fnc/files/patch-fnc.bld.mk
index f536a9bdf849..d93e2c974d67 100644
--- a/devel/fnc/files/patch-fnc.bld.mk
+++ b/devel/fnc/files/patch-fnc.bld.mk
@@ -1,21 +1,34 @@
---- fnc.bld.mk.orig	2022-03-24 19:30:04 UTC
+--- fnc.bld.mk.orig	2023-11-27 08:16:26 UTC
 +++ fnc.bld.mk
-@@ -5,7 +5,7 @@
+@@ -4,8 +4,8 @@ CC ?=		cc
+ 
  # CONFIGURATION
  CC ?=		cc
- PREFIX ?=	/usr/local
+-PREFIX ?=	/usr/local
 -MANDIR ?=	/share/man
++PREFIX ?=	%%PREFIX%%
 +MANDIR ?=	/man
  VERSION ?=	%%VERSION%%
- 
- # FLAGS NEEDED TO BUILD SQLITE3
-@@ -67,9 +67,9 @@ src/fnc: src/fnc.o src/diff.o lib/libfossil.o lib/sqli
- 	${FNC_LDFLAGS}
+ HASH !=		cut -f 1 manifest.uuid
+ DATE !=		sed '2q;d' manifest | cut -d ' ' -f 2 | tr T ' '
+@@ -42,7 +42,7 @@ FOSSIL_CFLAGS =	${CFLAGS} -Wall -Werror -Wsign-compare
+ # On SOME Linux (e.g., Ubuntu 18.04.6), we have to include wchar curses from
+ # I/.../ncursesw, but linking to -lncursesw (w/ no special -L path) works fine.
+ # FLAGS NEEDED TO BUILD FNC
+-FNC_CFLAGS =	${CFLAGS} -Wall -Werror -Wsign-compare -pedantic -std=c99 \
++FNC_CFLAGS =	${CFLAGS} -Wall -Werror -Wsign-compare -pedantic -std=c11 \
+ 		-I./lib -I./include -I/usr/include/ncursesw \
+ 		-D_XOPEN_SOURCE_EXTENDED -DVERSION=${VERSION} -DHASH=${HASH} \
+ 		-DDATE="${DATE}"
+@@ -89,10 +89,10 @@ install:
+ 	@echo "generated compile_commands.json"
  
  install:
+-	mkdir -p -m 0755 ${PREFIX}/bin
 -	mkdir -p -m 0755 ${PREFIX}${MANDIR}/man1
 -	install -s -m 0755 src/fnc ${PREFIX}/bin/fnc
 -	install -m 0644 src/fnc.1 ${PREFIX}${MANDIR}/man1/fnc.1
++	mkdir -p -m 0755 ${DESTDIR}${PREFIX}/bin
 +	mkdir -p -m 0755 ${DESTDIR}${PREFIX}${MANDIR}/man1
 +	install -s -m 0755 src/fnc ${DESTDIR}${PREFIX}/bin/fnc
 +	install -m 0644 src/fnc.1 ${DESTDIR}${PREFIX}${MANDIR}/man1/fnc.1