aboutsummaryrefslogtreecommitdiffstats
path: root/testing/mimalloc1/APKBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'testing/mimalloc1/APKBUILD')
-rw-r--r--testing/mimalloc1/APKBUILD35
1 files changed, 24 insertions, 11 deletions
diff --git a/testing/mimalloc1/APKBUILD b/testing/mimalloc1/APKBUILD
index c69f2ca1020..81bb217ea4f 100644
--- a/testing/mimalloc1/APKBUILD
+++ b/testing/mimalloc1/APKBUILD
@@ -1,22 +1,24 @@
# Contributor: Jakub Jirutka <jakub@jirutka.cz>
+# Contributor: Nicolas Lorin <androw95220@gmail.com>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=mimalloc1
_projname=mimalloc
-pkgver=1.7.2
+pkgver=1.8.2
pkgrel=0
_pkgdesc="A compact general purpose allocator with excellent performance"
pkgdesc="$_pkgdesc (in secure mode)"
url="https://github.com/microsoft/mimalloc"
-# aarch64,arm*: tests fail
# ppc64le: tests segfault in secure mode
-arch="all !aarch64 !armhf !armv7 !ppc64le"
+arch="all !ppc64le"
license="MIT"
-makedepends="cmake"
+makedepends="cmake samurai"
provides="mimalloc=$pkgver-r$pkgrel"
-provider_priority=100 # highest
-subpackages="$pkgname-dev $pkgname-insecure $pkgname-debug"
+subpackages="
+ $pkgname-dev
+ $pkgname-insecure
+ $pkgname-debug
+ "
source="https://github.com/microsoft/mimalloc/archive/v$pkgver/$_projname-$pkgver.tar.gz
- cmake-install-paths.patch
cmake-add-insecure-suffix.patch
"
builddir="$srcdir/$_projname-$pkgver"
@@ -24,6 +26,8 @@ builddir="$srcdir/$_projname-$pkgver"
_buildtypes='debug insecure secure'
build() {
+ # https://github.com/microsoft/mimalloc/issues/597
+ export CFLAGS="$CFLAGS -D__USE_ISOC11"
_build out/debug -DCMAKE_BUILD_TYPE=Debug -DMI_DEBUG_FULL=ON
# This is called "release" build by upstream.
@@ -39,9 +43,10 @@ _build() {
[ "$CBUILD" = "$CHOST" ] \
|| crossopts='-DCMAKE_SYSTEM_NAME=Linux -DCMAKE_HOST_SYSTEM_NAME=Linux'
- CFLAGS=${CFLAGS/-Os/} cmake -B "$outdir" \
+ CFLAGS=${CFLAGS/-Os/} cmake -B "$outdir" -G Ninja \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_VERBOSE_MAKEFILE=ON \
+ -DMI_INSTALL_TOPLEVEL=ON \
$crossopts \
"$@" .
cmake --build "$outdir"
@@ -63,6 +68,7 @@ package() {
cd "$pkgdir"
ln -s libmimalloc-secure.so usr/lib/libmimalloc.so
+ ln -s libmimalloc-secure.so.${pkgver%%.*} usr/lib/libmimalloc.so.${pkgver%%.*}
ln -s libmimalloc-secure.so.${pkgver%.*} usr/lib/libmimalloc.so.${pkgver%.*}
ln -s libmimalloc-secure.a usr/lib/libmimalloc.a
@@ -74,21 +80,28 @@ package() {
rm -f usr/lib/*.o
}
+dev() {
+ provides="mimalloc-dev=$pkgver-r$pkgrel"
+
+ default_dev
+}
+
insecure() {
pkgdesc="$_pkgdesc (in insecure mode)"
+ provides="mimalloc-insecure=$pkgver-r$pkgrel"
amove usr/lib/libmimalloc-insecure.*
}
debug() {
pkgdesc="$_pkgdesc (debug build)"
+ provides="mimalloc-debug=$pkgver-r$pkgrel"
options="!strip"
amove usr/lib/libmimalloc-debug.*
}
sha512sums="
-5d78c5cc00dfff3dd7eb4bb59e8eff32397f5110d1183b4656cb56c40b88e2e648e3b18338119412b95ba9526937b16fce3aa4732f241a61a546e2bcea1efc9d mimalloc-1.7.2.tar.gz
-587b7e3cdd7284f54642a32c8eb777ae6351da0a53919fc8821144991bc6e1fb1c954debb41ada914b3ef02bd1f29655fabee0c3ffdbe013fe573a3864323f56 cmake-install-paths.patch
-a2011dd2d229b048a39751219a4e0e44c5bac11bd0aa615c51e34ca9044e491822d5020d038a78c2c75c3b44657e4c2b6b62721569960834c722bc5eb2297dc2 cmake-add-insecure-suffix.patch
+8648043fc94c2a998bb84464bbfb52cc85e9dcaff604433b9b0940104f314753fdedf1413c9ffb6719d6affaac6ad0d7a1289532387464bce2291a00152443a0 mimalloc-1.8.2.tar.gz
+9cfaa68a6dcf377a52a60e37a1e83f81fc9ba94afb55f10bb089e24561e791c318e7e0860c17944ef2aaa11546a32fa4a3510afe3aefefcc0a393dc2f334ef3d cmake-add-insecure-suffix.patch
"