git: 5e19f4315082 - main - databases/mdbx: Update to 0.12.9

From: Zsolt Udvari <uzsolt_at_FreeBSD.org>
Date: Mon, 26 Aug 2024 17:47:28 UTC
The branch main has been updated by uzsolt:

URL: https://cgit.FreeBSD.org/ports/commit/?id=5e19f4315082b38f1513cd5f577970d280a1596c

commit 5e19f4315082b38f1513cd5f577970d280a1596c
Author:     Mahlon E. Smith <mahlon@martini.nu>
AuthorDate: 2024-08-26 17:33:39 +0000
Commit:     Zsolt Udvari <uzsolt@FreeBSD.org>
CommitDate: 2024-08-26 17:37:51 +0000

    databases/mdbx: Update to 0.12.9
    
    The source tarball compressed by xz, add tar:xz to USES.
    Use cmake instead of gmake.
    Switch to DISTVERSION.
    The second MASTER_SITES overwrite the first MASTER_SITES (github),
    remove it.
    
    PR:             277846
    Approved by:    submitter is maintainer
---
 databases/mdbx/Makefile                | 15 ++++--------
 databases/mdbx/distinfo                |  6 ++---
 databases/mdbx/files/patch-GNUmakefile | 42 ----------------------------------
 databases/mdbx/files/patch-mdbx.h++    | 11 ---------
 4 files changed, 7 insertions(+), 67 deletions(-)

diff --git a/databases/mdbx/Makefile b/databases/mdbx/Makefile
index fcf25c146d0a..0ae66b3b4ea9 100644
--- a/databases/mdbx/Makefile
+++ b/databases/mdbx/Makefile
@@ -1,8 +1,6 @@
 PORTNAME=	mdbx
-PORTVERSION=	0.11.14
-PORTREVISION=	1
+DISTVERSION=	0.12.9
 CATEGORIES=	databases
-MASTER_SITES=	https://github.com/${GH_ACCOUNT}/${GH_PROJECT}/releases/download/${DISTVERSIONPREFIX}${DISTVERSION}/
 MASTER_SITES=	https://libmdbx.dqdkfa.ru/release/
 DISTNAME=	libmdbx-amalgamated-${DISTVERSION}
 
@@ -15,21 +13,16 @@ LICENSE_NAME=	OpenLDAP Public License
 LICENSE_FILE=	${WRKSRC}/LICENSE
 LICENSE_PERMS=	dist-mirror dist-sell pkg-mirror pkg-sell auto-accept
 
-USES=		gmake
+USES=		cmake tar:xz
 USE_LDCONFIG=	yes
 
-MAKEFILE=	GNUmakefile
-MAKE_ARGS=	mdbx tools
-MAKE_ENV=	mandir=${PREFIX}/share/man
-
-CFLAGS+=	-Wall -Werror -Wextra -Wpedantic -ffunction-sections \
-		-fPIC -fvisibility=hidden -std=gnu11 -pthread -Wno-error=attributes
-
 NO_WRKSUBDIR=	yes
 
 PLIST_SUB=	VERSION=${PORTVERSION}
 
 post-install:
+	${CP}  ${BUILD_WRKSRC}/libmdbx-static.a ${STAGEDIR}${PREFIX}/lib/libmdbx.a
+	${MV}  ${STAGEDIR}${PREFIX}/lib/libmdbx.so ${STAGEDIR}${PREFIX}/lib/libmdbx.so.${PORTVERSION}
 	${RLN} libmdbx.so.${PORTVERSION} ${STAGEDIR}${PREFIX}/lib/libmdbx.so
 	${RLN} libmdbx.so.${PORTVERSION} ${STAGEDIR}${PREFIX}/lib/libmdbx.so.0
 
diff --git a/databases/mdbx/distinfo b/databases/mdbx/distinfo
index cfb8f8d1e751..b1cb70e83e6a 100644
--- a/databases/mdbx/distinfo
+++ b/databases/mdbx/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1676493467
-SHA256 (libmdbx-amalgamated-0.11.14.tar.gz) = 95327d7b59c6ea76ee4830f288d280dd4e90e6af2905b66e80671a14dafd3e0c
-SIZE (libmdbx-amalgamated-0.11.14.tar.gz) = 698366
+TIMESTAMP = 1710889018
+SHA256 (libmdbx-amalgamated-0.12.9.tar.xz) = 6ccc5277bfb13ce744fb6d2128de0b11c8f58c81c1fe06179ceaac5c28125a6e
+SIZE (libmdbx-amalgamated-0.12.9.tar.xz) = 394500
diff --git a/databases/mdbx/files/patch-GNUmakefile b/databases/mdbx/files/patch-GNUmakefile
deleted file mode 100644
index 575d96a0d47a..000000000000
--- a/databases/mdbx/files/patch-GNUmakefile
+++ /dev/null
@@ -1,42 +0,0 @@
---- GNUmakefile.orig	2022-08-02 10:17:33 UTC
-+++ GNUmakefile
-@@ -9,7 +9,7 @@
- # Basic internal definitios. For a customizable variables and options see below.
- #
- $(info // The GNU Make $(MAKE_VERSION))
--SHELL         := $(shell env bash -c 'echo $$BASH')
-+SHELL         := sh
- MAKE_VERx3    := $(shell printf "%3s%3s%3s" $(subst ., ,$(MAKE_VERSION)))
- make_lt_3_81  := $(shell expr "$(MAKE_VERx3)" "<" "  3 81")
- ifneq ($(make_lt_3_81),0)
-@@ -117,7 +117,7 @@ define uname2libs
-   esac
- endef
- 
--SO_SUFFIX  := $(shell $(uname2sosuffix))
-+SO_SUFFIX  := so.0.11.14
- HEADERS    := mdbx.h mdbx.h++
- LIBRARIES  := libmdbx.a libmdbx.$(SO_SUFFIX)
- TOOLS      := mdbx_stat mdbx_copy mdbx_dump mdbx_load mdbx_chk mdbx_drop
-@@ -284,16 +284,11 @@ mdbx_%.static-lto: mdbx_%.c config.h mdbx.c mdbx.h
- 
- install: $(LIBRARIES) $(TOOLS) $(HEADERS)
- 	@echo '  INSTALLING...'
--	$(QUIET)mkdir -p $(DESTDIR)$(prefix)/bin$(suffix) && \
--		$(INSTALL) -p $(EXE_INSTALL_FLAGS) $(TOOLS) $(DESTDIR)$(prefix)/bin$(suffix)/ && \
--	mkdir -p $(DESTDIR)$(prefix)/lib$(suffix)/ && \
--		$(INSTALL) -p $(EXE_INSTALL_FLAGS) $(filter-out libmdbx.a,$(LIBRARIES)) $(DESTDIR)$(prefix)/lib$(suffix)/ && \
--	mkdir -p $(DESTDIR)$(prefix)/lib$(suffix)/ && \
--		$(INSTALL) -p libmdbx.a $(DESTDIR)$(prefix)/lib$(suffix)/ && \
--	mkdir -p $(DESTDIR)$(prefix)/include/ && \
--		$(INSTALL) -p -m 444 $(HEADERS) $(DESTDIR)$(prefix)/include/ && \
--	mkdir -p $(DESTDIR)$(mandir)/man1/ && \
--		$(INSTALL) -p -m 444 $(addprefix $(MAN_SRCDIR), $(MANPAGES)) $(DESTDIR)$(mandir)/man1/
-+	install -p -s $(TOOLS) $(DESTDIR)$(prefix)/bin$(suffix) && \
-+	install -p -s $(filter-out libmdbx.a,$(LIBRARIES)) $(DESTDIR)$(prefix)/lib$(suffix) && \
-+	install -p libmdbx.a $(DESTDIR)$(prefix)/lib$(suffix) && \
-+	install -p -m 444 $(HEADERS) $(DESTDIR)$(prefix)/include && \
-+	install -p -m 444 $(addprefix $(MAN_SRCDIR), $(MANPAGES)) $(DESTDIR)$(mandir)/man1
- 
- install-strip: EXE_INSTALL_FLAGS = -s
- install-strip: install
diff --git a/databases/mdbx/files/patch-mdbx.h++ b/databases/mdbx/files/patch-mdbx.h++
deleted file mode 100644
index 51538c655c60..000000000000
--- a/databases/mdbx/files/patch-mdbx.h++
+++ /dev/null
@@ -1,11 +0,0 @@
---- mdbx.h++.orig	2022-08-02 10:17:33 UTC
-+++ mdbx.h++
-@@ -23,6 +23,8 @@
- 
- #pragma once
- 
-+#define _LIBCPP_NO_EXPERIMENTAL_DEPRECATION_WARNING_FILESYSTEM
-+
- /* Workaround for modern libstdc++ with CLANG < 4.x */
- #if defined(__SIZEOF_INT128__) && !defined(__GLIBCXX_TYPE_INT_N_0) &&          \
-     defined(__clang__) && __clang_major__ < 4