csound: fix musl

This commit is contained in:
John Zimmermann 2019-02-03 03:12:11 +01:00
parent d29ebfd069
commit 1cb5c25d33
2 changed files with 34 additions and 2 deletions

View file

@ -0,0 +1,32 @@
From d122dd83cba94a9b8857564816ab48556b609180 Mon Sep 17 00:00:00 2001
From: John Zimmermann <johnz@posteo.net>
Date: Sun, 3 Feb 2019 03:04:05 +0100
Subject: [PATCH] Allow to link against libexecinfo on linux systems
Some C-libraries like the Musl libc don't provide execinfo themself so
it is required to use a third party library to use execinfo there.
---
CMakeLists.txt | 7 +++++++
1 file changed, 7 insertions(+)
diff --git CMakeLists.txt CMakeLists.txt
index c6cd95a02..2fb129d5f 100644
--- CMakeLists.txt
+++ CMakeLists.txt
@@ -1284,6 +1284,13 @@ if(LINUX)
list(APPEND libcsound_LIBS ${LIBRT_LIBRARY})
message(STATUS " ADDING LIBRT LIBRARY: ${LIBRT_LIBRARY}.")
endif()
+
+ find_library(LIBEXECINFO_LIBRARY execinfo)
+
+ if(LIBEXECINFO_LIBRARY)
+ list(APPEND libcsound_LIBS ${LIBEXECINFO_LIBRARY})
+ message(STATUS " ADDING LIBEXECINFO LIBRARY: ${LIBEXECINFO_LIBRARY}.")
+ endif()
endif()
if(APPLE AND NOT IOS)
--
2.20.1

View file

@ -22,8 +22,8 @@ nocross=yes
CXXFLAGS="-Wno-error"
case "$XBPS_TARGET_MACHINE" in
*-musl) broken="not yet supported";;
case $XBPS_TARGET_MACHINE in
*-musl) makedepends+=" libexecinfo-devel";;
esac
post_install() {