1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-12 18:59:50 +03:00

main/valgrind: build with -O2 on s390x and ppc64le

Without this valgrind memcheck seems to report false positives on
ppc64le and sometimes segfault on s390x.
This commit is contained in:
Sertonix 2025-05-29 17:12:27 +02:00 committed by Natanael Copa
parent 4ce7cdbd8a
commit e8a87dcf09

View file

@ -1,7 +1,7 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=valgrind
pkgver=3.25.1
pkgrel=1
pkgrel=2
pkgdesc="Tool to help find memory-management problems in programs"
url="https://valgrind.org/"
# armv6 not supported upstream
@ -20,6 +20,11 @@ source="https://sourceware.org/pub/valgrind/valgrind-$pkgver.tar.bz2
"
build() {
case "$CARCH" in
# FIXME gcc -Os breaks valgrind memcheck
s390x|ppc*) export CFLAGS="$CFLAGS -O2" ;;
esac
export CFLAGS="${CFLAGS/-fno-plt} -fno-stack-protector -no-pie -U_FORTIFY_SOURCE"
./configure \
--build=$CBUILD \