git: f9b30321622f - main - devel/boost-libs: Fix broken function program_location_impl

From: Yuri Victorovich <yuri_at_FreeBSD.org>
Date: Fri, 27 Jun 2025 18:33:16 UTC
The branch main has been updated by yuri:

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

commit f9b30321622f332bb2a6b1986dc44a068218c9b8
Author:     Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2025-06-27 14:49:19 +0000
Commit:     Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2025-06-27 18:33:14 +0000

    devel/boost-libs: Fix broken function program_location_impl
    
    ... in include/boost/dll/detail/posix/program_location_impl.hpp
    
    This function is FreeBSD-specific.
    
    Fixed error:
    error: use of undeclared identifier 'buf'
    
    Approved by:    office@FreeBSD.org (maintainer's timeout; 14 days)
    
    PR:             287514
---
 devel/boost-libs/Makefile                                     |  2 +-
 .../patch-boost_dll_detail_posix_program__location__impl.hpp  | 11 +++++++++++
 2 files changed, 12 insertions(+), 1 deletion(-)

diff --git a/devel/boost-libs/Makefile b/devel/boost-libs/Makefile
index bd26f416fc1b..819a0fef24d3 100644
--- a/devel/boost-libs/Makefile
+++ b/devel/boost-libs/Makefile
@@ -1,5 +1,5 @@
 PORTNAME=	boost-libs
-PORTREVISION?=	0
+PORTREVISION?=	1
 
 COMMENT=	Free portable C++ libraries (without Boost.Python)
 WWW=		https://www.boost.org/
diff --git a/devel/boost-libs/files/patch-boost_dll_detail_posix_program__location__impl.hpp b/devel/boost-libs/files/patch-boost_dll_detail_posix_program__location__impl.hpp
new file mode 100644
index 000000000000..4afbd9cc2be5
--- /dev/null
+++ b/devel/boost-libs/files/patch-boost_dll_detail_posix_program__location__impl.hpp
@@ -0,0 +1,11 @@
+--- boost/dll/detail/posix/program_location_impl.hpp.orig	2025-06-14 19:35:17 UTC
++++ boost/dll/detail/posix/program_location_impl.hpp
+@@ -70,7 +70,7 @@ namespace boost { namespace dll { namespace detail {
+         mib[2] = KERN_PROC_PATHNAME;
+         mib[3] = -1;
+         char path[1024];
+-        size_t size = sizeof(buf);
++        size_t size = sizeof(path);
+         if (sysctl(mib, 4, path, &size, nullptr, 0) == 0)
+             return boost::dll::fs::path(path);
+