1# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*- 2# vim: set filetype=python: 3# This Source Code Form is subject to the terms of the Mozilla Public 4# License, v. 2.0. If a copy of the MPL was not distributed with this 5# file, You can obtain one at http://mozilla.org/MPL/2.0/. 6 7EXPORTS.soundtouch += [ 8 'FIFOSamplePipe.h', 9 'SoundTouch.h', 10 'soundtouch_config.h', 11 'SoundTouchFactory.h', 12 'STTypes.h', 13] 14 15UNIFIED_SOURCES += [ 16 'AAFilter.cpp', 17 'cpu_detect_x86.cpp', 18 'FIFOSampleBuffer.cpp', 19 'FIRFilter.cpp', 20 'InterpolateCubic.cpp', 21 'InterpolateLinear.cpp', 22 'InterpolateShannon.cpp', 23 'RateTransposer.cpp', 24 'SoundTouch.cpp', 25 'SoundTouchFactory.cpp', 26 'TDStretch.cpp', 27] 28 29if CONFIG['INTEL_ARCHITECTURE']: 30 if CONFIG['MOZ_SAMPLE_TYPE_FLOAT32']: 31 SOURCES += ['sse_optimized.cpp'] 32 SOURCES['sse_optimized.cpp'].flags += CONFIG['SSE2_FLAGS'] 33 else: 34 SOURCES += ['mmx_optimized.cpp'] 35 SOURCES['mmx_optimized.cpp'].flags += CONFIG['MMX_FLAGS'] 36 37if CONFIG['OS_ARCH'] != 'WINNT': 38 # GCC/Clang require permissions to be explicitly set for the soundtouch 39 # header. 40 CXXFLAGS += ['-include', SRCDIR + '/soundtouch_perms.h'] 41else: 42 # Windows need alloca renamed to _alloca 43 DEFINES['alloca'] = '_alloca' 44 45# We allow warnings for third-party code that can be updated from upstream. 46ALLOW_COMPILER_WARNINGS = True 47 48FINAL_LIBRARY = 'lgpllibs' 49 50# Use abort() instead of exception in SoundTouch. 51DEFINES['ST_NO_EXCEPTION_HANDLING'] = 1 52