summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorViolet Purcell <vimproved@inventati.org>2023-06-04 05:12:02 -0400
committerMiroslav Šulc <fordfrog@gentoo.org>2023-06-06 08:24:53 +0200
commit4586446a72d3240d66048b4c66a820fb056b69d2 (patch)
treebb7e7988a22c5ebff21276ced71b6afec90a9709 /media-sound
parentdev-python/zope-deprecation: enable py3.12 (diff)
downloadgentoo-4586446a72d3240d66048b4c66a820fb056b69d2.tar.gz
gentoo-4586446a72d3240d66048b4c66a820fb056b69d2.tar.bz2
gentoo-4586446a72d3240d66048b4c66a820fb056b69d2.zip
media-sound/ardour: Fix build with libc++
Signed-off-by: Violet Purcell <vimproved@inventati.org> Closes: https://github.com/gentoo/gentoo/pull/31301 Signed-off-by: Miroslav Šulc <fordfrog@gentoo.org>
Diffstat (limited to 'media-sound')
-rw-r--r--media-sound/ardour/ardour-7.4-r2.ebuild3
-rw-r--r--media-sound/ardour/ardour-9999.ebuild3
-rw-r--r--media-sound/ardour/files/ardour-6.8-metadata.patch2
-rw-r--r--media-sound/ardour/files/ardour-7.4-libc++.patch39
4 files changed, 45 insertions, 2 deletions
diff --git a/media-sound/ardour/ardour-7.4-r2.ebuild b/media-sound/ardour/ardour-7.4-r2.ebuild
index 7393250c576f..2bfcbebca1ea 100644
--- a/media-sound/ardour/ardour-7.4-r2.ebuild
+++ b/media-sound/ardour/ardour-7.4-r2.ebuild
@@ -73,6 +73,7 @@ DEPEND="${RDEPEND}
PATCHES=(
"${FILESDIR}/${PN}-6.8-metadata.patch"
+ "${FILESDIR}/${PN}-7.4-libc++.patch"
)
pkg_pretend() {
@@ -145,6 +146,8 @@ src_configure() {
# not possible right now --use-external-libs
)
+ [[ "$(tc-get-cxx-stdlib)" = "libc++" ]] && myconf+=( --use-libc++ )
+
waf-utils_src_configure "${myconf[@]}"
}
diff --git a/media-sound/ardour/ardour-9999.ebuild b/media-sound/ardour/ardour-9999.ebuild
index 0d0ba16716f4..93b6a1742f84 100644
--- a/media-sound/ardour/ardour-9999.ebuild
+++ b/media-sound/ardour/ardour-9999.ebuild
@@ -73,6 +73,7 @@ DEPEND="${RDEPEND}
PATCHES=(
"${FILESDIR}/${PN}-6.8-metadata.patch"
+ "${FILESDIR}/${PN}-7.4-libc++.patch"
)
pkg_pretend() {
@@ -145,6 +146,8 @@ src_configure() {
# not possible right now --use-external-libs
)
+ [[ "$(tc-get-cxx-stdlib)" = "libc++" ]] && myconf+=( --use-libc++ )
+
waf-utils_src_configure "${myconf[@]}"
}
diff --git a/media-sound/ardour/files/ardour-6.8-metadata.patch b/media-sound/ardour/files/ardour-6.8-metadata.patch
index fa7b6e121197..ea540b34df5f 100644
--- a/media-sound/ardour/files/ardour-6.8-metadata.patch
+++ b/media-sound/ardour/files/ardour-6.8-metadata.patch
@@ -1,5 +1,3 @@
-diff --git a/gtk2_ardour/wscript b/gtk2_ardour/wscript
-index f5d0533..a68cb3f 100644
--- a/gtk2_ardour/wscript
+++ b/gtk2_ardour/wscript
@@ -943,7 +943,7 @@ def build(bld):
diff --git a/media-sound/ardour/files/ardour-7.4-libc++.patch b/media-sound/ardour/files/ardour-7.4-libc++.patch
new file mode 100644
index 000000000000..85f13ba47dbc
--- /dev/null
+++ b/media-sound/ardour/files/ardour-7.4-libc++.patch
@@ -0,0 +1,39 @@
+From d8e42490b18bd0c8a827d96608e951bf5bc875e4 Mon Sep 17 00:00:00 2001
+From: Violet Purcell <vimproved@inventati.org>
+Date: Sun, 4 Jun 2023 04:56:58 -0400
+Subject: [PATCH] Fix build with libc++ on linux
+
+--- a/libs/vst3/pluginterfaces/base/funknown.cpp
++++ b/libs/vst3/pluginterfaces/base/funknown.cpp
+@@ -44,7 +44,9 @@
+ #endif
+
+ #if SMTG_OS_LINUX
++#ifndef USE_LIBCXX
+ #include <ext/atomicity.h>
++#endif
+ /* UUID */
+ #include <string>
+ #include <boost/uuid/uuid.hpp>
+@@ -83,7 +85,7 @@ int32 PLUGIN_API atomicAdd (int32& var, int32 d)
+ return InterlockedExchangeAdd ((volatile long int*)&var, d) + d;
+ #elif SMTG_OS_MACOS
+ return OSAtomicAdd32Barrier (d, (int32_t*)&var);
+-#elif SMTG_OS_LINUX
++#elif SMTG_OS_LINUX && !defined USE_LIBCXX
+ __gnu_cxx::__atomic_add (&var, d);
+ return var;
+ #else
+--- a/wscript
++++ b/wscript
+@@ -545,6 +545,8 @@ int main() { return 0; }''',
+ if opt.use_libcpp or conf.env['build_host'] in [ 'yosemite', 'el_capitan', 'sierra', 'high_sierra', 'mojave', 'catalina' ]:
+ cxx_flags.append('--stdlib=libc++')
+ linker_flags.append('--stdlib=libc++')
++ if platform == 'linux':
++ cxx_flags.append('-DUSE_LIBCXX')
+
+ if conf.options.cxx11 or conf.env['build_host'] in [ 'mavericks', 'yosemite', 'el_capitan', 'sierra', 'high_sierra', 'mojave', 'catalina' , 'bigsur', 'monterey', 'ventura' ]:
+ conf.check_cxx(cxxflags=["-std=c++11"])
+--
+2.40.1