From d9f5bd05009f1f99f7c3bd5c21178cd7346b5528 Mon Sep 17 00:00:00 2001 From: David CARLIER Date: Tue, 30 May 2023 21:25:59 +0100 Subject: [PATCH] pass through enable malloc build for dragonflybsd. (#614) --- CMakeLists.txt | 1 - src/snmalloc/mem/external_alloc.h | 5 +++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index b1358d1..f2d1233 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -452,7 +452,6 @@ if(NOT SNMALLOC_HEADER_ONLY_LIBRARY) if (WIN32 OR (CMAKE_SYSTEM_NAME STREQUAL NetBSD) OR (CMAKE_SYSTEM_NAME STREQUAL OpenBSD) - OR (CMAKE_SYSTEM_NAME STREQUAL DragonFly) OR (CMAKE_SYSTEM_NAME STREQUAL SunOS)) # Windows does not support aligned allocation well enough # for pass through. diff --git a/src/snmalloc/mem/external_alloc.h b/src/snmalloc/mem/external_alloc.h index 4eecfa9..2507197 100644 --- a/src/snmalloc/mem/external_alloc.h +++ b/src/snmalloc/mem/external_alloc.h @@ -45,6 +45,11 @@ namespace snmalloc::external_alloc { using ::malloc_usable_size; } +# elif defined(__DragonFly__) +namespace snmalloc::external_alloc +{ + using ::malloc_usable_size; +} # else # error Define malloc size macro for this platform. # endif