git: 060b82b8c6a7 - main - biology/vsearch: Add patch for FreeBSD 16
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 20 Dec 2025 16:29:42 UTC
The branch main has been updated by jwb:
URL: https://cgit.FreeBSD.org/ports/commit/?id=060b82b8c6a7884c543403fbe7f244238c8b205d
commit 060b82b8c6a7884c543403fbe7f244238c8b205d
Author: Jason W. Bacon <jwb@FreeBSD.org>
AuthorDate: 2025-12-20 16:28:21 +0000
Commit: Jason W. Bacon <jwb@FreeBSD.org>
CommitDate: 2025-12-20 16:28:21 +0000
biology/vsearch: Add patch for FreeBSD 16
Resolve collision with symbol "memalignment"
Reported by: pkg-fallout
---
biology/vsearch/files/patch-src_arch.cc | 32 ++++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)
diff --git a/biology/vsearch/files/patch-src_arch.cc b/biology/vsearch/files/patch-src_arch.cc
new file mode 100644
index 000000000000..bf8d2e77dda7
--- /dev/null
+++ b/biology/vsearch/files/patch-src_arch.cc
@@ -0,0 +1,32 @@
+--- src/arch.cc.orig 2025-12-20 13:37:07 UTC
++++ src/arch.cc
+@@ -67,7 +67,7 @@
+ #include <cstdlib> // std::realloc, std::free
+
+
+-constexpr auto memalignment = 16;
++constexpr auto vsearch_memalignment = 16;
+
+
+ auto arch_get_memused() -> uint64_t
+@@ -223,9 +223,9 @@ auto xmalloc(std::size_t size) -> void *
+ size = std::max(size, minimal_allocation);
+ void * ptr = nullptr;
+ #ifdef _WIN32
+- ptr = _aligned_malloc(size, memalignment);
++ ptr = _aligned_malloc(size, vsearch_memalignment);
+ #else
+- if (posix_memalign(&ptr, memalignment, size) != 0)
++ if (posix_memalign(&ptr, vsearch_memalignment, size) != 0)
+ {
+ ptr = nullptr;
+ }
+@@ -243,7 +243,7 @@ auto xrealloc(void * ptr, std::size_t size) -> void *
+ static constexpr auto minimal_allocation = std::size_t{1};
+ size = std::max(size, minimal_allocation);
+ #ifdef _WIN32
+- void * new_ptr = _aligned_realloc(ptr, size, memalignment);
++ void * new_ptr = _aligned_realloc(ptr, size, vsearch_memalignment);
+ #else
+ void * new_ptr = realloc(ptr, size);
+ #endif