bug 1001001 - stop exporting opus_ symbols from libxul r=rilian, ted
☠☠ backed out by f5a100decfb3 ☠ ☠
authorTrevor Saunders <trev.saunders@gmail.com>
Thu, 24 Apr 2014 13:44:48 -0400
changeset 198663 1bab9339e6d427eb6d5745ccdd2358027c2c4cbf
parent 198662 02eb81ab06cb0abcd849c480363083fa7faa915c
child 198664 db9956f946806e470240236b1c9af7c37276d487
push id3624
push userasasaki@mozilla.com
push dateMon, 09 Jun 2014 21:49:01 +0000
treeherdermozilla-beta@b1a5da15899a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersrilian, ted
bugs1001001
milestone31.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
bug 1001001 - stop exporting opus_ symbols from libxul r=rilian, ted opus doesn't seem to provide a define for being built as a static library, but it allows us to override what it would define OPUS_EXPORT to be. So we can just define OPUS_EXPORT to the empty string and then those symbols will be hidden in libxul just like anything else.
media/libopus/moz.build
--- a/media/libopus/moz.build
+++ b/media/libopus/moz.build
@@ -23,16 +23,21 @@ if CONFIG['CPU_ARCH'] == 'arm' and CONFI
     DEFINES['OPUS_ARM_ASM'] = True
     DEFINES['OPUS_ARM_EXTERNAL_ASM'] = True
     DEFINES['OPUS_ARM_INLINE_ASM'] = True
     DEFINES['OPUS_ARM_INLINE_EDSP'] = True
     DEFINES['OPUS_ARM_MAY_HAVE_EDSP'] = True
     DEFINES['OPUS_ARM_MAY_HAVE_MEDIA'] = True
     DEFINES['OPUS_ARM_MAY_HAVE_NEON'] = True
 
+# We only need to export symbols if we're built into libgkmedias instead of
+# libxul which only happens on windows.
+if CONFIG['GKMEDIAS_SHARED_LIBRARY']:
+    DEFINES['OPUS_EXPORT'] = ''
+
 if CONFIG['MOZ_DEBUG']:
     DEFINES['ENABLE_ASSERTIONS'] = True
 
 if CONFIG['OS_ARCH'] in ('Linux', 'Darwin', 'DragonFly', 'FreeBSD',
                          'NetBSD', 'OpenBSD'):
     DEFINES['HAVE_LRINTF'] = True
 
 if CONFIG['OS_ARCH'] == 'WINNT':