summaryrefslogtreecommitdiff
path: root/media-libs/rubberband/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-07-09 15:43:36 +0100
committerV3n3RiX <venerix@koprulu.sector>2022-07-09 15:43:36 +0100
commit2719f73b6813d11d13a9650cdd2ab8ec6e69385d (patch)
tree8c816148bcbd22757d892089c989ae614eae4f5a /media-libs/rubberband/files
parent0f558761aa2dee1017b4751e4017205e015a9560 (diff)
gentoo resync : 09.07.2022
Diffstat (limited to 'media-libs/rubberband/files')
-rw-r--r--media-libs/rubberband/files/rubberband-3.0.0-build.patch165
1 files changed, 165 insertions, 0 deletions
diff --git a/media-libs/rubberband/files/rubberband-3.0.0-build.patch b/media-libs/rubberband/files/rubberband-3.0.0-build.patch
new file mode 100644
index 000000000000..3892f5231716
--- /dev/null
+++ b/media-libs/rubberband/files/rubberband-3.0.0-build.patch
@@ -0,0 +1,165 @@
+diff --git a/meson.build b/meson.build
+index 42f7f7f..b2a342a 100644
+--- a/meson.build
++++ b/meson.build
+@@ -113,19 +113,27 @@ endforeach
+
+ fftw3_dep = dependency('fftw3', version: '>= 3.0.0', required: false)
+ samplerate_dep = dependency('samplerate', version: '>= 0.1.8', required: false)
+-sndfile_dep = dependency('sndfile', version: '>= 1.0.16', required: false)
+-vamp_dep = dependency('vamp-sdk', version: '>= 2.9', required: false)
++if get_option('programs')
++ sndfile_dep = dependency('sndfile', version: '>= 1.0.16', required: false)
++endif
++if get_option('vamp')
++ vamp_dep = dependency('vamp-sdk', version: '>= 2.9', required: false)
++endif
+ boost_unit_test_dep = dependency('boost', modules: ['unit_test_framework'], version: '>= 1.73', required: false)
+ thread_dep = dependency('threads')
+-have_ladspa = cpp.has_header('ladspa.h', args: extra_include_args)
++if get_option('ladspa')
++ have_ladspa = cpp.has_header('ladspa.h', args: extra_include_args)
++endif
+ have_lv2 = cpp.has_header('lv2.h', args: extra_include_args)
+ have_sincos = cpp.has_function('sincos',
+ prefix: '#define _GNU_SOURCE\n#include <math.h>',
+ args: '-lm')
+-have_jni = cpp.has_header('jni.h', args: extra_include_args)
++if get_option('jni')
++ have_jni = cpp.has_header('jni.h', args: extra_include_args)
+
+-javac = find_program('javac', required: false)
+-jar = find_program('jar', required: false)
++ javac = find_program('javac', required: false)
++ jar = find_program('jar', required: false)
++endif
+
+
+ # Check FFT and resampler options and set up dependencies and paths
+@@ -296,37 +304,41 @@ if ipp_needed
+ endif
+ endif # ipp_needed
+
+-if not vamp_dep.found()
+- vamp_dep = cpp.find_library('VampPluginSDK',
+- dirs: get_option('extra_lib_dirs'),
+- has_headers: ['vamp-sdk.h'],
+- header_args: extra_include_args,
+- required: false)
++if get_option('vamp')
+ if not vamp_dep.found()
+- vamp_dep = cpp.find_library('vamp-sdk',
++ vamp_dep = cpp.find_library('VampPluginSDK',
+ dirs: get_option('extra_lib_dirs'),
+ has_headers: ['vamp-sdk.h'],
+ header_args: extra_include_args,
+ required: false)
++ if not vamp_dep.found()
++ vamp_dep = cpp.find_library('vamp-sdk',
++ dirs: get_option('extra_lib_dirs'),
++ has_headers: ['vamp-sdk.h'],
++ header_args: extra_include_args,
++ required: false)
++ endif
+ endif
++ have_vamp = true
+ endif
+-have_vamp = vamp_dep.found()
+-
+-if not sndfile_dep.found()
+- sndfile_dep = cpp.find_library('sndfile',
+- dirs: get_option('extra_lib_dirs'),
+- has_headers: ['sndfile.h'],
+- header_args: extra_include_args,
+- required: false)
++
++if get_option('programs')
+ if not sndfile_dep.found()
+- sndfile_dep = cpp.find_library('sndfile-1',
++ sndfile_dep = cpp.find_library('sndfile',
+ dirs: get_option('extra_lib_dirs'),
+ has_headers: ['sndfile.h'],
+ header_args: extra_include_args,
+ required: false)
++ if not sndfile_dep.found()
++ sndfile_dep = cpp.find_library('sndfile-1',
++ dirs: get_option('extra_lib_dirs'),
++ has_headers: ['sndfile.h'],
++ header_args: extra_include_args,
++ required: false)
++ endif
+ endif
++ have_sndfile = true
+ endif
+-have_sndfile = sndfile_dep.found()
+
+ have_boost_unit_test = boost_unit_test_dep.found()
+
+@@ -535,7 +547,7 @@ if get_option('default_library') != 'shared' and rubberband_additional_static_li
+ )
+ endif
+
+-if have_jni and javac.found() and jar.found()
++if get_option('jni')
+ target_summary += { 'JNI library': [ true, 'Name: ' + rubberband_jni_name ] }
+ message('Will build Java Native Interface')
+ rubberband_jni = shared_library(
+@@ -570,7 +582,7 @@ if have_jni and javac.found() and jar.found()
+ )
+ else
+ target_summary += { 'JNI library': false }
+- if not have_jni
++ if not get_option('jni')
+ message('Not building Java Native Interface: jni.h header not found')
+ else
+ message('Not building Java Native Interface: Java compiler not found')
+@@ -584,7 +596,7 @@ install_headers(
+ subdir: 'rubberband'
+ )
+
+-if have_ladspa
++if get_option('ladspa')
+ target_summary += { 'LADSPA plugin': [ true, 'Name: ' + rubberband_ladspa_name ] }
+ message('Will build LADSPA plugin')
+ rubberband_ladspa = shared_library(
+@@ -651,7 +663,7 @@ else
+ message('Not building LV2 plugin: lv2.h header not found')
+ endif
+
+-if have_vamp
++if get_option('vamp')
+ target_summary += { 'Vamp plugin': [ true, 'Name: ' + rubberband_vamp_name ] }
+ message('Will build Vamp plugin')
+ rubberband_vamp = shared_library(
+@@ -683,7 +695,7 @@ else
+ message('Not building Vamp plugin: Vamp dependency not found')
+ endif
+
+-if have_sndfile
++if get_option('programs')
+ message('Will build command-line utilities')
+ target_summary += { 'Command-line utility (R2)': [ true, 'Name: ' + rubberband_program_name ] }
+ rubberband_program = executable(
+diff --git a/meson_options.txt b/meson_options.txt
+index c820c20..81710de 100644
+--- a/meson_options.txt
++++ b/meson_options.txt
+@@ -26,3 +26,18 @@ option('extra_lib_dirs',
+ value: [],
+ description: 'Additional local library directories to search for dependencies.')
+
++option('jni',
++ type: 'boolean',
++ value: 'false')
++
++option('ladspa',
++ type: 'boolean',
++ value: 'false')
++
++option('programs',
++ type: 'boolean',
++ value: 'false')
++
++option('vamp',
++ type: 'boolean',
++ value: 'false')