Showing the changes to python (1 of 1 file). Show all
Unified · Split
| @@ -52,7 +52,7 @@ def add_local_aubio_lib(ext): · 51 unmodified lines | ||
| 52 | 52 | ext.library_dirs += [os.path.join('build', 'src')] |
| 53 | 53 | ext.libraries += ['aubio'] |
| 54 | 54 | |
| 55 | −def add_local_aubio_sources(ext): | |
| 55 | +def add_local_aubio_sources(ext, usedouble = False): | |
| 56 | 56 | """ build aubio inside python module instead of linking against libaubio """ |
| 57 | 57 | print("Warning: libaubio was not built with waf, adding src/") |
| 58 | 58 | # create an empty header, macros will be passed on the command line |
| @@ -73,9 +73,15 @@ def add_local_aubio_sources(ext): · 14 unmodified lines | ||
| 73 | 73 | print("Info: looking for *optional* additional packages") |
| 74 | 74 | packages = ['libavcodec', 'libavformat', 'libavutil', 'libavresample', |
| 75 | 75 | 'jack', |
| 76 | − 'sndfile', 'samplerate', | |
| 76 | + 'jack', | |
| 77 | + 'sndfile', | |
| 77 | 78 | #'fftw3f', |
| 78 | 79 | ] |
| 80 | + # samplerate only works with float | |
| 81 | + if usedouble == False: | |
| 82 | + packages += ['samplerate'] | |
| 83 | + else: | |
| 84 | + print("Info: not adding libsamplerate in double precision mode") | |
| 79 | 85 | add_packages(packages, ext=ext) |
| 80 | 86 | if 'avcodec' in ext.libraries \ |
| 81 | 87 | and 'avformat' in ext.libraries \ |