From 5aa4c91a6fbb99c3066315a7ee9bca71586d8da1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrgen=20Buchm=C3=BCller?= Date: Wed, 28 Oct 2020 11:17:16 +0100 Subject: [PATCH] graphite: fix build for i686-musl --- srcpkgs/graphite/template | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/srcpkgs/graphite/template b/srcpkgs/graphite/template index 344e1997614..15ca2fb1288 100644 --- a/srcpkgs/graphite/template +++ b/srcpkgs/graphite/template @@ -14,6 +14,18 @@ homepage="https://github.com/silnrsi/graphite" distfiles="https://github.com/silnrsi/graphite/releases/download/${version}/graphite2-${version}.tgz" checksum=f99d1c13aa5fa296898a181dff9b82fb25f6cc0933dbaa7a475d8109bd54209d +if [ "$XBPS_TARGET_LIBC" = "musl" ]; then + LDFLAGS+=" -L${XBPS_CROSS_BASE}/usr/lib -lssp_nonshared" +fi + +pre_configure() { + case "$XBPS_TARGET_MACHINE" in + i686-musl) # fails to link against ssp_nonshared with -nodefaultlibs + vsed -i src/CMakeLists.txt -e "s;-nodefaultlibs;;" + ;; + esac +} + graphite-devel_package() { depends="${makedepends} ${sourcepkg}-${version}_${revision}" short_desc+=" - development files"