Skip to content

Commit

Permalink
devel/mimalloc: Update to 3.0.1
Browse files Browse the repository at this point in the history
Apply patch to fix build [1]

Obtained from:	microsoft/mimalloc#988 [1]
  • Loading branch information
ehaupt committed Jan 13, 2025
1 parent 1f145c7 commit c990c01
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 8 deletions.
2 changes: 1 addition & 1 deletion devel/mimalloc/Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
PORTNAME= mimalloc
DISTVERSIONPREFIX= v
DISTVERSION= 2.1.8
DISTVERSION= 3.0.1
CATEGORIES= devel

MAINTAINER= [email protected]
Expand Down
6 changes: 3 additions & 3 deletions devel/mimalloc/distinfo
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
TIMESTAMP = 1735990751
SHA256 (microsoft-mimalloc-v2.1.8_GH0.tar.gz) = 4d7e771b51ba0d3c4a5850d3f7f7f82c1b04af318e1351553f46aa3336439540
SIZE (microsoft-mimalloc-v2.1.8_GH0.tar.gz) = 1276091
TIMESTAMP = 1736781220
SHA256 (microsoft-mimalloc-v3.0.1_GH0.tar.gz) = 6a514ae31254b43e06e2a89fe1cbc9c447fdbf26edc6f794f3eb722f36e28261
SIZE (microsoft-mimalloc-v3.0.1_GH0.tar.gz) = 1281782
4 changes: 2 additions & 2 deletions devel/mimalloc/files/patch-CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- CMakeLists.txt.orig 2023-04-03 19:32:28 UTC
--- CMakeLists.txt.orig 2025-01-13 15:16:06 UTC
+++ CMakeLists.txt
@@ -353,8 +353,8 @@ if(MI_TRACK_ASAN)
@@ -513,8 +513,8 @@ string(TOLOWER "${CMAKE_BUILD_TYPE}" CMAKE_BUILD_TYPE_
set(mi_basename "${mi_basename}-asan")
endif()
string(TOLOWER "${CMAKE_BUILD_TYPE}" CMAKE_BUILD_TYPE_LC)
Expand Down
12 changes: 12 additions & 0 deletions devel/mimalloc/files/patch-src_prim_unix_prim.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
--- src/prim/unix/prim.c.orig 2025-01-04 04:21:48 UTC
+++ src/prim/unix/prim.c
@@ -201,7 +201,8 @@ static void* unix_mmap_prim(void* addr, size_t size, s
void* p = NULL;
#if defined(MAP_ALIGNED) // BSD
if (addr == NULL && try_alignment > 1 && (try_alignment % _mi_os_page_size()) == 0) {
- size_t n = mi_bsr(try_alignment);
+ size_t idx;
+ size_t n = mi_bsr(try_alignment, &idx);
if (((size_t)1 << n) == try_alignment && n >= 12 && n <= 30) { // alignment is a power of 2 and 4096 <= alignment <= 1GiB
p = mmap(addr, size, protect_flags, flags | MAP_ALIGNED(n), fd, 0);
if (p==MAP_FAILED || !_mi_is_aligned(p,try_alignment)) {
4 changes: 2 additions & 2 deletions devel/mimalloc/pkg-plist
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ lib/cmake/mimalloc/mimalloc-config.cmake
lib/cmake/mimalloc/mimalloc.cmake
lib/libmimalloc.a
lib/libmimalloc.so
lib/libmimalloc.so.2
lib/libmimalloc.so.2.1
lib/libmimalloc.so.3
lib/libmimalloc.so.3.0
libdata/pkgconfig/mimalloc.pc

0 comments on commit c990c01

Please sign in to comment.