tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

moz.build (2183B)


      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 
      7 SOURCES += [
      8     '../test/test_audio.cpp',
      9     '../test/test_callback_ret.cpp',
     10     '../test/test_devices.cpp',
     11     '../test/test_duplex.cpp',
     12     '../test/test_latency.cpp',
     13     '../test/test_logging.cpp',
     14     '../test/test_overload_callback.cpp',
     15     '../test/test_record.cpp',
     16     '../test/test_resampler.cpp',
     17     '../test/test_ring_array.cpp',
     18     '../test/test_ring_buffer.cpp',
     19     '../test/test_sanity.cpp',
     20     '../test/test_tone.cpp',
     21     '../test/test_triple_buffer.cpp',
     22     '../test/test_utils.cpp'
     23 ]
     24 
     25 # Loopback stream is only implemented in the WASAPI backend. It fails in debug.
     26 if CONFIG['OS_ARCH'] == 'WINNT' and not CONFIG['MOZ_DEBUG']:
     27     SOURCES += [  '../test/test_loopback.cpp' ]
     28 
     29 # https://bugzilla.mozilla.org/show_bug.cgi?id=1864888
     30 if CONFIG['OS_ARCH'] != 'Linux':
     31     SOURCES += [ '../test/test_device_changed_callback.cpp' ]
     32 
     33 LOCAL_INCLUDES += [
     34     '../include',
     35     '../src'
     36 ]
     37 
     38 USE_LIBS += [
     39     'cubeb',
     40     'speex'
     41 ]
     42 
     43 if CONFIG['OS_ARCH'] == 'WINNT':
     44     DEFINES['UNICODE'] = True
     45     # On windows, the WASAPI backend needs the resampler we have in
     46     # /media/libspeex_resampler, so we can't get away with just linking cubeb's
     47     # .o
     48     USE_LIBS += [
     49         'cubeb',
     50         'speex',
     51     ]
     52     OS_LIBS += [
     53         'ole32'
     54     ]
     55 else:
     56     # Otherwise, we can just grab all the compiled .o and compile against that,
     57     # linking the appriopriate libraries.
     58     USE_LIBS += [
     59         'cubeb',
     60     ]
     61     # Don't link xul for it introduces dependencies on Android.
     62     if CONFIG['OS_TARGET'] == 'Android':
     63         USE_LIBS += [
     64             'speex',
     65         ]
     66 
     67 if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
     68     OS_LIBS += [
     69         '-framework AudioUnit',
     70         '-framework CoreAudio',
     71     ]
     72 elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'uikit':
     73     OS_LIBS += [
     74       '-framework CoreFoundation',
     75       '-framework AudioToolbox',
     76     ]
     77 
     78 FINAL_LIBRARY = 'xul-gtest'