mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2026-05-16 18:17:15 +02:00
42 lines
1.3 KiB
Diff
42 lines
1.3 KiB
Diff
Updated: 20 Feb 2021 by Nicolas Lorin <androw95220@gmail.com>
|
|
|
|
From: Jakub Jirutka <jakub@jirutka.cz>
|
|
Date: Thu, 19 Aug 2021 23:08:13 +0200
|
|
Subject: Add suffix "-insecure" to library with MI_SECURE=OFF
|
|
|
|
We want to make the secure variant the default one.
|
|
|
|
--- a/CMakeLists.txt.orig
|
|
+++ b/CMakeLists.txt
|
|
@@ -126,12 +126,6 @@
|
|
message(STATUS "For example: 'cmake --build . --config=Release")
|
|
endif()
|
|
|
|
-if(NOT MI_SECURE AND NOT MI_SECURE_FULL AND "${CMAKE_BINARY_DIR}" MATCHES ".*(S|s)ecure$")
|
|
- message(STATUS "Default to secure build")
|
|
- set(MI_SECURE "ON")
|
|
-endif()
|
|
-
|
|
-
|
|
# Determine architecture
|
|
set(MI_OPT_ARCH_FLAGS "")
|
|
set(MI_ARCH "unknown")
|
|
@@ -602,6 +596,8 @@
|
|
set(mi_libname "mimalloc")
|
|
if(MI_SECURE)
|
|
set(mi_libname "${mi_libname}-secure")
|
|
+else()
|
|
+ set(mi_libname "${mi_libname}-insecure")
|
|
endif()
|
|
if(MI_TRACK_VALGRIND)
|
|
set(mi_libname "${mi_libname}-valgrind")
|
|
@@ -614,7 +610,7 @@
|
|
if(CMAKE_BUILD_TYPE_LC MATCHES "^(release|relwithdebinfo|minsizerel|none)$")
|
|
list(APPEND mi_defines MI_BUILD_RELEASE)
|
|
else()
|
|
- set(mi_libname "${mi_libname}-${CMAKE_BUILD_TYPE_LC}") #append build type (e.g. -debug) if not a release version
|
|
+ set(mi_libname "mimalloc-${CMAKE_BUILD_TYPE_LC}") #append build type (e.g. -debug) if not a release version
|
|
endif()
|
|
|
|
if(MI_BUILD_SHARED)
|