diff --git a/lib-src/audacity-patches.txt b/lib-src/audacity-patches.txt index 5ee6adee6..a2dbaff85 100644 --- a/lib-src/audacity-patches.txt +++ b/lib-src/audacity-patches.txt @@ -179,6 +179,8 @@ build system break. Not suitable for upstream, what is needed is more powerful autoconf features to pass the right options to portaudio's configure script, which suffers from the broken-ness of autoconf's subdirectory support +* linkage.patch allows compilation as C++ with correct "C" linkage of one function + portmidi ------- http://portmedia.sourceforge.net/ diff --git a/lib-src/portaudio-v19/linkage.patch b/lib-src/portaudio-v19/linkage.patch new file mode 100644 index 000000000..95e4408e9 --- /dev/null +++ b/lib-src/portaudio-v19/linkage.patch @@ -0,0 +1,27 @@ +diff --git a/lib-src/portaudio-v19/src/os/unix/pa_unix_util.c b/lib-src/portaudio-v19/src/os/unix/pa_unix_util.c +index 18f806c..7f4fd540 100644 +--- a/lib-src/portaudio-v19/src/os/unix/pa_unix_util.c ++++ b/lib-src/portaudio-v19/src/os/unix/pa_unix_util.c +@@ -154,6 +154,10 @@ void PaUtil_InitializeClock( void ) + } + + ++#ifdef __cplusplus ++extern "C" { ++#endif ++ + PaTime PaUtil_GetTime( void ) + { + #ifdef HAVE_MACH_ABSOLUTE_TIME +@@ -169,6 +173,10 @@ PaTime PaUtil_GetTime( void ) + #endif + } + ++#ifdef __cplusplus ++} ++#endif ++ + PaError PaUtil_InitializeThreading( PaUtilThreading *threading ) + { + (void) paUtilErr_; +