wscript: check if rubberband can be foud
authorPaul Brossier <piem@piem.org>
Fri, 16 Sep 2016 22:57:17 +0000 (00:57 +0200)
committerPaul Brossier <piem@piem.org>
Fri, 16 Sep 2016 22:57:17 +0000 (00:57 +0200)
wscript

diff --git a/wscript b/wscript
index 8697c91..d0352ed 100644 (file)
--- a/wscript
+++ b/wscript
@@ -68,6 +68,9 @@ def options(ctx):
     add_option_enable_disable(ctx, 'samplerate', default = None,
             help_str = 'compile with samplerate (auto)',
             help_disable_str = 'disable samplerate')
+    add_option_enable_disable(ctx, 'rubberband', default = None,
+            help_str = 'compile with rubberband (auto)',
+            help_disable_str = 'disable rubberband')
     add_option_enable_disable(ctx, 'memcpy', default = True,
             help_str = 'use memcpy hacks (default)',
             help_disable_str = 'do not use memcpy hacks')
@@ -259,6 +262,12 @@ def configure(ctx):
                 args = '--cflags --libs',
                 mandatory = ctx.options.enable_samplerate)
 
+    # check for librubberband
+    if (ctx.options.enable_rubberband != False):
+        ctx.check_cfg(package = 'rubberband', atleast_version = '1.8.1',
+                args = '--cflags --libs',
+                mandatory = ctx.options.enable_rubberband)
+
     # check for jack
     if (ctx.options.enable_jack != False):
         ctx.check_cfg(package = 'jack',