|
Lines 1-10
Link Here
|
| 1 |
# Allow more config/external/ libs built against system-wide version. |
1 |
# Allow more config/external/ libs built against system-wide version. |
| 2 |
|
2 |
|
| 3 |
diff --git build/moz.configure/old.configure build/moz.configure/old.configure |
3 |
diff --git build/moz.configure/old.configure build/moz.configure/old.configure |
| 4 |
index 42ab554..c91df3d 100644 |
4 |
index d0fe7accffe6..c46bdd023225 100644 |
| 5 |
--- mozilla/build/moz.configure/old.configure |
5 |
--- mozilla/build/moz.configure/old.configure |
| 6 |
+++ mozilla/build/moz.configure/old.configure |
6 |
+++ mozilla/build/moz.configure/old.configure |
| 7 |
@@ -320,7 +320,12 @@ def old_configure_options(*options): |
7 |
@@ -288,7 +288,12 @@ def old_configure_options(*options): |
| 8 |
'--with-system-libvpx', |
8 |
'--with-system-libvpx', |
| 9 |
'--with-system-nspr', |
9 |
'--with-system-nspr', |
| 10 |
'--with-system-nss', |
10 |
'--with-system-nss', |
|
Lines 18-30
index 42ab554..c91df3d 100644
Link Here
|
| 18 |
'--with-thumb', |
18 |
'--with-thumb', |
| 19 |
'--with-thumb-interwork', |
19 |
'--with-thumb-interwork', |
| 20 |
diff --git config/Makefile.in config/Makefile.in |
20 |
diff --git config/Makefile.in config/Makefile.in |
| 21 |
index 5383399..0410004 100644 |
21 |
index a6206bb0ff30..f20987c61754 100644 |
| 22 |
--- mozilla/config/Makefile.in |
22 |
--- mozilla/config/Makefile.in |
| 23 |
+++ mozilla/config/Makefile.in |
23 |
+++ mozilla/config/Makefile.in |
| 24 |
@@ -51,6 +51,11 @@ export:: $(export-preqs) |
24 |
@@ -51,6 +51,11 @@ export:: $(export-preqs) |
|
|
25 |
-DMOZ_SYSTEM_LIBEVENT=$(MOZ_SYSTEM_LIBEVENT) \ |
| 26 |
-DMOZ_SYSTEM_LIBVPX=$(MOZ_SYSTEM_LIBVPX) \ |
| 25 |
-DMOZ_SYSTEM_ICU=$(MOZ_SYSTEM_ICU) \ |
27 |
-DMOZ_SYSTEM_ICU=$(MOZ_SYSTEM_ICU) \ |
| 26 |
-DMOZ_SYSTEM_GRAPHITE2=$(MOZ_SYSTEM_GRAPHITE2) \ |
|
|
| 27 |
-DMOZ_SYSTEM_HARFBUZZ=$(MOZ_SYSTEM_HARFBUZZ) \ |
| 28 |
+ -DMOZ_SYSTEM_OGG=$(MOZ_SYSTEM_OGG) \ |
28 |
+ -DMOZ_SYSTEM_OGG=$(MOZ_SYSTEM_OGG) \ |
| 29 |
+ -DMOZ_SYSTEM_THEORA=$(MOZ_SYSTEM_THEORA) \ |
29 |
+ -DMOZ_SYSTEM_THEORA=$(MOZ_SYSTEM_THEORA) \ |
| 30 |
+ -DMOZ_SYSTEM_VORBIS=$(MOZ_SYSTEM_VORBIS) \ |
30 |
+ -DMOZ_SYSTEM_VORBIS=$(MOZ_SYSTEM_VORBIS) \ |
|
Lines 34-45
index 5383399..0410004 100644
Link Here
|
| 34 |
$(INSTALL) system_wrappers $(DIST) |
34 |
$(INSTALL) system_wrappers $(DIST) |
| 35 |
|
35 |
|
| 36 |
diff --git config/external/moz.build config/external/moz.build |
36 |
diff --git config/external/moz.build config/external/moz.build |
| 37 |
index f67c5c7..eb909ce 100644 |
37 |
index 029ff8504795..2c3a40caa1ba 100644 |
| 38 |
--- mozilla/config/external/moz.build |
38 |
--- mozilla/config/external/moz.build |
| 39 |
+++ mozilla/config/external/moz.build |
39 |
+++ mozilla/config/external/moz.build |
| 40 |
@@ -20,12 +20,21 @@ if CONFIG['MOZ_UPDATER']: |
40 |
@@ -21,12 +21,21 @@ if CONFIG['MOZ_UPDATER']: |
| 41 |
# There's no "native brotli" yet, but probably in the future... |
|
|
| 42 |
external_dirs += ['modules/brotli'] |
41 |
external_dirs += ['modules/brotli'] |
|
|
42 |
external_dirs += ['modules/woff2'] |
| 43 |
|
43 |
|
| 44 |
-if CONFIG['MOZ_VORBIS']: |
44 |
-if CONFIG['MOZ_VORBIS']: |
| 45 |
+if not CONFIG['MOZ_SYSTEM_OGG']: |
45 |
+if not CONFIG['MOZ_SYSTEM_OGG']: |
|
Lines 61-67
index f67c5c7..eb909ce 100644
Link Here
|
| 61 |
if CONFIG['MOZ_WEBM_ENCODER']: |
61 |
if CONFIG['MOZ_WEBM_ENCODER']: |
| 62 |
external_dirs += ['media/libmkv'] |
62 |
external_dirs += ['media/libmkv'] |
| 63 |
|
63 |
|
| 64 |
@@ -51,12 +60,9 @@ external_dirs += [ |
64 |
@@ -52,12 +61,9 @@ external_dirs += [ |
| 65 |
'media/kiss_fft', |
65 |
'media/kiss_fft', |
| 66 |
'media/libcubeb', |
66 |
'media/libcubeb', |
| 67 |
'media/libnestegg', |
67 |
'media/libnestegg', |
|
Lines 71-87
index f67c5c7..eb909ce 100644
Link Here
|
| 71 |
'media/libspeex_resampler', |
71 |
'media/libspeex_resampler', |
| 72 |
'media/libstagefright', |
72 |
'media/libstagefright', |
| 73 |
- 'media/libsoundtouch', |
73 |
- 'media/libsoundtouch', |
|
|
74 |
'media/psshparser' |
| 74 |
] |
75 |
] |
| 75 |
|
76 |
|
| 76 |
DIRS += ['../../' + i for i in external_dirs] |
|
|
| 77 |
diff --git config/system-headers config/system-headers |
77 |
diff --git config/system-headers config/system-headers |
| 78 |
index bef567c..9807c29 100644 |
78 |
index 5ee7f71f9634..13178ac3b3ab 100644 |
| 79 |
--- mozilla/config/system-headers |
79 |
--- mozilla/config/system-headers |
| 80 |
+++ mozilla/config/system-headers |
80 |
+++ mozilla/config/system-headers |
| 81 |
@@ -1364,3 +1363,17 @@ graphite2/Segment.h |
81 |
@@ -1348,3 +1348,17 @@ unicode/utypes.h |
| 82 |
harfbuzz/hb-ot.h |
82 |
libutil.h |
| 83 |
harfbuzz/hb.h |
83 |
unwind.h |
| 84 |
#endif |
84 |
fenv.h |
| 85 |
+#if MOZ_SYSTEM_OGG==1 |
85 |
+#if MOZ_SYSTEM_OGG==1 |
| 86 |
+ogg/ogg.h |
86 |
+ogg/ogg.h |
| 87 |
+ogg/os_types.h |
87 |
+ogg/os_types.h |
|
Lines 96-223
index bef567c..9807c29 100644
Link Here
|
| 96 |
+#if MOZ_SYSTEM_TREMOR==1 |
96 |
+#if MOZ_SYSTEM_TREMOR==1 |
| 97 |
+tremor/ivorbiscodec.h |
97 |
+tremor/ivorbiscodec.h |
| 98 |
+#endif |
98 |
+#endif |
| 99 |
diff --git old-configure.in configure.in |
|
|
| 100 |
index 87db361..7947626 100644 |
| 101 |
--- mozilla/old-configure.in |
| 102 |
+++ mozilla/old-configure.in |
| 103 |
@@ -5401,6 +5401,111 @@ if test -n "$MOZ_OMX_PLUGIN"; then |
| 104 |
fi |
| 105 |
fi |
| 106 |
|
| 107 |
+dnl ======================================================== |
| 108 |
+dnl Check for libogg |
| 109 |
+dnl ======================================================== |
| 110 |
+ |
| 111 |
+MOZ_ARG_WITH_BOOL(system-ogg, |
| 112 |
+[ --with-system-ogg Use system libogg (located with pkgconfig)], |
| 113 |
+MOZ_SYSTEM_OGG=1, |
| 114 |
+MOZ_SYSTEM_OGG=) |
| 115 |
+ |
| 116 |
+if test -n "$MOZ_SYSTEM_OGG"; then |
| 117 |
+ PKG_CHECK_MODULES(MOZ_OGG, ogg >= 1.2.1) |
| 118 |
+ |
| 119 |
+ _SAVE_LIBS=$LIBS |
| 120 |
+ LIBS="$LIBS $MOZ_OGG_LIBS" |
| 121 |
+ AC_CHECK_FUNC(ogg_set_mem_functions, [], |
| 122 |
+ [AC_DEFINE(MOZ_OGG_NO_MEM_REPORTING)]) |
| 123 |
+ LIBS=$_SAVE_LIBS |
| 124 |
+fi |
| 125 |
+ |
| 126 |
+AC_SUBST(MOZ_SYSTEM_OGG) |
| 127 |
+ |
| 128 |
+dnl ======================================================== |
| 129 |
+dnl Check for libvorbis |
| 130 |
+dnl ======================================================== |
| 131 |
+ |
| 132 |
+MOZ_ARG_WITH_BOOL(system-vorbis, |
| 133 |
+[ --with-system-vorbis Use system libvorbis (located with pkgconfig)], |
| 134 |
+MOZ_SYSTEM_VORBIS=1, |
| 135 |
+MOZ_SYSTEM_VORBIS=) |
| 136 |
+ |
| 137 |
+if test -n "$MOZ_SYSTEM_VORBIS"; then |
| 138 |
+ PKG_CHECK_MODULES(MOZ_VORBIS, vorbis vorbisenc >= 1.3.5) |
| 139 |
+fi |
| 140 |
+ |
| 141 |
+AC_SUBST(MOZ_SYSTEM_VORBIS) |
| 142 |
+ |
| 143 |
+dnl ======================================================== |
| 144 |
+dnl Check for integer-only libvorbis aka tremor |
| 145 |
+dnl ======================================================== |
| 146 |
+ |
| 147 |
+MOZ_ARG_WITH_BOOL(system-tremor, |
| 148 |
+[ --with-system-tremor Use system libtremor (located with pkgconfig)], |
| 149 |
+MOZ_SYSTEM_TREMOR=1, |
| 150 |
+MOZ_SYSTEM_TREMOR=) |
| 151 |
+ |
| 152 |
+if test -n "$MOZ_SYSTEM_TREMOR"; then |
| 153 |
+ PKG_CHECK_MODULES(MOZ_TREMOR, vorbisidec >= 1.2.1) |
| 154 |
+fi |
| 155 |
+ |
| 156 |
+AC_SUBST(MOZ_SYSTEM_TREMOR) |
| 157 |
+ |
| 158 |
+dnl ======================================================== |
| 159 |
+dnl Check for libtheora |
| 160 |
+dnl ======================================================== |
| 161 |
+ |
| 162 |
+MOZ_ARG_WITH_BOOL(system-theora, |
| 163 |
+[ --with-system-theora Use system libtheora (located with pkgconfig)], |
| 164 |
+MOZ_SYSTEM_THEORA=1, |
| 165 |
+MOZ_SYSTEM_THEORA=) |
| 166 |
+ |
| 167 |
+if test -n "$MOZ_SYSTEM_THEORA"; then |
| 168 |
+ PKG_CHECK_MODULES(MOZ_THEORA, theora >= 1.2) |
| 169 |
+fi |
| 170 |
+ |
| 171 |
+AC_SUBST(MOZ_SYSTEM_THEORA) |
| 172 |
+ |
| 173 |
+dnl ======================================================== |
| 174 |
+dnl Check for libSoundTouch |
| 175 |
+dnl ======================================================== |
| 176 |
+ |
| 177 |
+MOZ_ARG_WITH_BOOL(system-soundtouch, |
| 178 |
+[ --with-system-soundtouch Use system libSoundTouch (located with pkgconfig)], |
| 179 |
+MOZ_SYSTEM_SOUNDTOUCH=1, |
| 180 |
+MOZ_SYSTEM_SOUNDTOUCH=) |
| 181 |
+ |
| 182 |
+if test -n "$MOZ_SYSTEM_SOUNDTOUCH"; then |
| 183 |
+ PKG_CHECK_MODULES(MOZ_SOUNDTOUCH, soundtouch >= 1.9.0) |
| 184 |
+ |
| 185 |
+ AC_LANG_SAVE |
| 186 |
+ AC_LANG_CPLUSPLUS |
| 187 |
+ _SAVE_CXXFLAGS=$CXXFLAGS |
| 188 |
+ CXXFLAGS="$CXXFLAGS $MOZ_SOUNDTOUCH_CFLAGS" |
| 189 |
+ AC_CACHE_CHECK(for soundtouch sample type, |
| 190 |
+ ac_cv_soundtouch_sample_type, |
| 191 |
+ [AC_TRY_COMPILE([#include <SoundTouch.h> |
| 192 |
+ #ifndef SOUNDTOUCH_INTEGER_SAMPLES |
| 193 |
+ #error soundtouch expects float samples |
| 194 |
+ #endif], |
| 195 |
+ [], |
| 196 |
+ [ac_cv_soundtouch_sample_type=short], |
| 197 |
+ [ac_cv_soundtouch_sample_type=float])]) |
| 198 |
+ CXXFLAGS=$_SAVE_CXXFLAGS |
| 199 |
+ AC_LANG_RESTORE |
| 200 |
+ |
| 201 |
+ if test \( -n "$MOZ_SAMPLE_TYPE_S16" -a "$ac_cv_soundtouch_sample_type" != short \) \ |
| 202 |
+ -o \( -n "$MOZ_SAMPLE_TYPE_FLOAT32" -a "$ac_cv_soundtouch_sample_type" != float \) ; then |
| 203 |
+ AC_MSG_ERROR([SoundTouch library is built with incompatible sample type. Either rebuild the library with/without --enable-integer-samples, chase default Mozilla sample type or remove --with-system-soundtouch.]) |
| 204 |
+ fi |
| 205 |
+fi |
| 206 |
+ |
| 207 |
+if test -n "$MOZ_SYSTEM_SOUNDTOUCH"; then |
| 208 |
+ AC_DEFINE(MOZ_SYSTEM_SOUNDTOUCH) |
| 209 |
+fi |
| 210 |
+AC_SUBST(MOZ_SYSTEM_SOUNDTOUCH) |
| 211 |
+ |
| 212 |
dnl system libvpx Support |
| 213 |
dnl ======================================================== |
| 214 |
MOZ_ARG_WITH_BOOL(system-libvpx, |
| 215 |
diff --git dom/media/AudioStream.cpp dom/media/AudioStream.cpp |
99 |
diff --git dom/media/AudioStream.cpp dom/media/AudioStream.cpp |
| 216 |
index 2127256..1ec09fe 100644 |
100 |
index 93ecda4319af..ff674c64ea07 100644 |
| 217 |
--- mozilla/dom/media/AudioStream.cpp |
101 |
--- mozilla/dom/media/AudioStream.cpp |
| 218 |
+++ mozilla/dom/media/AudioStream.cpp |
102 |
+++ mozilla/dom/media/AudioStream.cpp |
| 219 |
@@ -125,7 +125,9 @@ AudioStream::AudioStream(DataSource& aSo |
103 |
@@ -115,7 +115,9 @@ AudioStream::AudioStream(DataSource& aSource) |
| 220 |
, mOutRate(0) |
104 |
: mMonitor("AudioStream") |
| 221 |
, mChannels(0) |
105 |
, mChannels(0) |
| 222 |
, mOutChannels(0) |
106 |
, mOutChannels(0) |
| 223 |
+#ifndef MOZ_SYSTEM_SOUNDTOUCH |
107 |
+#ifndef MOZ_SYSTEM_SOUNDTOUCH |
|
Lines 226-232
index 2127256..1ec09fe 100644
Link Here
|
| 226 |
, mDumpFile(nullptr) |
110 |
, mDumpFile(nullptr) |
| 227 |
, mState(INITIALIZED) |
111 |
, mState(INITIALIZED) |
| 228 |
, mDataSource(aSource) |
112 |
, mDataSource(aSource) |
| 229 |
@@ -152,9 +154,11 @@ AudioStream::~AudioStream() |
113 |
@@ -130,9 +132,11 @@ AudioStream::~AudioStream() |
| 230 |
if (mDumpFile) { |
114 |
if (mDumpFile) { |
| 231 |
fclose(mDumpFile); |
115 |
fclose(mDumpFile); |
| 232 |
} |
116 |
} |
|
Lines 238-244
index 2127256..1ec09fe 100644
Link Here
|
| 238 |
} |
122 |
} |
| 239 |
|
123 |
|
| 240 |
size_t |
124 |
size_t |
| 241 |
@@ -151,7 +155,11 @@ nsresult AudioStream::EnsureTimeStretche |
125 |
@@ -151,7 +155,11 @@ nsresult AudioStream::EnsureTimeStretcherInitializedUnlocked() |
| 242 |
{ |
126 |
{ |
| 243 |
mMonitor.AssertCurrentThreadOwns(); |
127 |
mMonitor.AssertCurrentThreadOwns(); |
| 244 |
if (!mTimeStretcher) { |
128 |
if (!mTimeStretcher) { |
|
Lines 251-261
index 2127256..1ec09fe 100644
Link Here
|
| 251 |
mTimeStretcher->setChannels(mOutChannels); |
135 |
mTimeStretcher->setChannels(mOutChannels); |
| 252 |
mTimeStretcher->setPitch(1.0); |
136 |
mTimeStretcher->setPitch(1.0); |
| 253 |
diff --git dom/media/AudioStream.h dom/media/AudioStream.h |
137 |
diff --git dom/media/AudioStream.h dom/media/AudioStream.h |
| 254 |
index a552e3e..02b80b1 100644 |
138 |
index 7dc1f60f95cc..67d402a4117f 100644 |
| 255 |
--- mozilla/dom/media/AudioStream.h |
139 |
--- mozilla/dom/media/AudioStream.h |
| 256 |
+++ mozilla/dom/media/AudioStream.h |
140 |
+++ mozilla/dom/media/AudioStream.h |
| 257 |
@@ -15,7 +15,11 @@ |
141 |
@@ -16,7 +16,11 @@ |
| 258 |
#include "mozilla/RefPtr.h" |
142 |
#include "mozilla/TimeStamp.h" |
| 259 |
#include "mozilla/UniquePtr.h" |
143 |
#include "mozilla/UniquePtr.h" |
| 260 |
#include "CubebUtils.h" |
144 |
#include "CubebUtils.h" |
| 261 |
+#ifdef MOZ_SYSTEM_SOUNDTOUCH |
145 |
+#ifdef MOZ_SYSTEM_SOUNDTOUCH |
|
Lines 266-274
index a552e3e..02b80b1 100644
Link Here
|
| 266 |
|
150 |
|
| 267 |
namespace mozilla { |
151 |
namespace mozilla { |
| 268 |
|
152 |
|
| 269 |
@@ -277,7 +277,11 @@ private: |
153 |
@@ -287,7 +291,11 @@ private: |
| 270 |
// Number of frames written to the buffers. |
154 |
uint32_t mChannels; |
| 271 |
int64_t mWritten; |
155 |
uint32_t mOutChannels; |
| 272 |
AudioClock mAudioClock; |
156 |
AudioClock mAudioClock; |
| 273 |
+#ifdef MOZ_SYSTEM_SOUNDTOUCH |
157 |
+#ifdef MOZ_SYSTEM_SOUNDTOUCH |
| 274 |
+ nsAutoPtr<soundtouch::SoundTouch> mTimeStretcher; |
158 |
+ nsAutoPtr<soundtouch::SoundTouch> mTimeStretcher; |
|
Lines 276-288
index a552e3e..02b80b1 100644
Link Here
|
| 276 |
soundtouch::SoundTouch* mTimeStretcher; |
160 |
soundtouch::SoundTouch* mTimeStretcher; |
| 277 |
+#endif |
161 |
+#endif |
| 278 |
|
162 |
|
| 279 |
// Stream start time for stream open delay telemetry. |
163 |
// Output file for dumping audio |
| 280 |
TimeStamp mStartTime; |
164 |
FILE* mDumpFile; |
| 281 |
diff --git dom/media/moz.build dom/media/moz.build |
165 |
diff --git dom/media/moz.build dom/media/moz.build |
| 282 |
index 7526cff..e0a0ca0 100644 |
166 |
index 86b051c58d33..fb6186dce78b 100644 |
| 283 |
--- mozilla/dom/media/moz.build |
167 |
--- mozilla/dom/media/moz.build |
| 284 |
+++ mozilla/dom/media/moz.build |
168 |
+++ mozilla/dom/media/moz.build |
| 285 |
@@ -300,6 +300,21 @@ if CONFIG['MOZ_WEBRTC']: |
169 |
@@ -308,6 +308,21 @@ if CONFIG['MOZ_WEBRTC']: |
| 286 |
|
170 |
|
| 287 |
DEFINES['MOZILLA_INTERNAL_API'] = True |
171 |
DEFINES['MOZILLA_INTERNAL_API'] = True |
| 288 |
|
172 |
|
|
Lines 304-314
index 7526cff..e0a0ca0 100644
Link Here
|
| 304 |
if CONFIG['OS_TARGET'] == 'WINNT': |
188 |
if CONFIG['OS_TARGET'] == 'WINNT': |
| 305 |
DEFINES['WEBRTC_WIN'] = True |
189 |
DEFINES['WEBRTC_WIN'] = True |
| 306 |
else: |
190 |
else: |
|
|
191 |
diff --git dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.cpp dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.cpp |
| 192 |
index 078f6ea5ef60..c600db067539 100644 |
| 193 |
--- mozilla/dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.cpp |
| 194 |
+++ mozilla/dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.cpp |
| 195 |
@@ -11,9 +11,13 @@ |
| 196 |
#include "prmem.h" |
| 197 |
#include "prlink.h" |
| 198 |
|
| 199 |
+#ifdef MOZ_SYSTEM_SOUNDTOUCH |
| 200 |
+#include "nsXPCOMPrivate.h" // for XUL_DLL |
| 201 |
+#else |
| 202 |
// We use a known symbol located in lgpllibs to determine its location. |
| 203 |
// soundtouch happens to be always included in lgpllibs |
| 204 |
#include "soundtouch/SoundTouch.h" |
| 205 |
+#endif |
| 206 |
|
| 207 |
namespace mozilla { |
| 208 |
|
| 209 |
@@ -50,6 +54,12 @@ FFVPXRuntimeLinker::Init() |
| 210 |
|
| 211 |
sLinkStatus = LinkStatus_FAILED; |
| 212 |
|
| 213 |
+#ifdef MOZ_SYSTEM_SOUNDTOUCH |
| 214 |
+ // We retrieve the path of the XUL library as this is where mozavcodec and |
| 215 |
+ // mozavutil libs are located. |
| 216 |
+ char* path = |
| 217 |
+ PR_GetLibraryFilePathname(XUL_DLL, (PRFuncPtr)&FFVPXRuntimeLinker::Init); |
| 218 |
+#else |
| 219 |
// We retrieve the path of the lgpllibs library as this is where mozavcodec |
| 220 |
// and mozavutil libs are located. |
| 221 |
char* lgpllibsname = PR_GetLibraryName(nullptr, "lgpllibs"); |
| 222 |
@@ -60,6 +70,7 @@ FFVPXRuntimeLinker::Init() |
| 223 |
PR_GetLibraryFilePathname(lgpllibsname, |
| 224 |
(PRFuncPtr)&soundtouch::SoundTouch::getVersionId); |
| 225 |
PR_FreeLibraryName(lgpllibsname); |
| 226 |
+#endif |
| 227 |
if (!path) { |
| 228 |
return false; |
| 229 |
} |
| 307 |
diff --git media/libogg/README_MOZILLA media/libogg/README_MOZILLA |
230 |
diff --git media/libogg/README_MOZILLA media/libogg/README_MOZILLA |
| 308 |
index 0833e4d..7ece97b 100644 |
231 |
index 6213fdc7770c..ada799916a17 100644 |
| 309 |
--- mozilla/media/libogg/README_MOZILLA |
232 |
--- mozilla/media/libogg/README_MOZILLA |
| 310 |
+++ mozilla/media/libogg/README_MOZILLA |
233 |
+++ mozilla/media/libogg/README_MOZILLA |
| 311 |
@@ -6,3 +6,6 @@ The svn revision number used was r17287. |
234 |
@@ -6,3 +6,6 @@ package downloaded from xiph.org and copied using the update.sh script. |
| 312 |
The int-types.patch address a bug that config_types.h generated from |
235 |
The int-types.patch address a bug that config_types.h generated from |
| 313 |
Linux platform can't be used on OpenSolaris directly see Mozilla bug |
236 |
Linux platform can't be used on OpenSolaris directly see Mozilla bug |
| 314 |
449754 |
237 |
449754 |
|
Lines 316-322
index 0833e4d..7ece97b 100644
Link Here
|
| 316 |
+The in-tree copy may be omitted during build by --with-system-ogg. |
239 |
+The in-tree copy may be omitted during build by --with-system-ogg. |
| 317 |
+Keep version in old-configure.in in sync on updates. |
240 |
+Keep version in old-configure.in in sync on updates. |
| 318 |
diff --git media/libsoundtouch/README_MOZILLA media/libsoundtouch/README_MOZILLA |
241 |
diff --git media/libsoundtouch/README_MOZILLA media/libsoundtouch/README_MOZILLA |
| 319 |
index bfd4b1a..15b158d 100644 |
242 |
index dc0dbe8f6886..ea73b55e3e39 100644 |
| 320 |
--- mozilla/media/libsoundtouch/README_MOZILLA |
243 |
--- mozilla/media/libsoundtouch/README_MOZILLA |
| 321 |
+++ mozilla/media/libsoundtouch/README_MOZILLA |
244 |
+++ mozilla/media/libsoundtouch/README_MOZILLA |
| 322 |
@@ -6,3 +6,5 @@ The whole library is not used, only the relevant files are imported in the tree, |
245 |
@@ -6,3 +6,5 @@ The whole library is not used, only the relevant files are imported in the tree, |
|
Lines 326-332
index bfd4b1a..15b158d 100644
Link Here
|
| 326 |
+The in-tree copy may be omitted during build by --with-system-soundtouch. |
249 |
+The in-tree copy may be omitted during build by --with-system-soundtouch. |
| 327 |
+Keep version in old-configure.in in sync on updates. |
250 |
+Keep version in old-configure.in in sync on updates. |
| 328 |
diff --git media/libsoundtouch/src/soundtouch_perms.h media/libsoundtouch/src/soundtouch_perms.h |
251 |
diff --git media/libsoundtouch/src/soundtouch_perms.h media/libsoundtouch/src/soundtouch_perms.h |
| 329 |
index 0af2fe6..d80c145 100644 |
252 |
index 0af2fe618311..10973564e7a4 100644 |
| 330 |
--- mozilla/media/libsoundtouch/src/soundtouch_perms.h |
253 |
--- mozilla/media/libsoundtouch/src/soundtouch_perms.h |
| 331 |
+++ mozilla/media/libsoundtouch/src/soundtouch_perms.h |
254 |
+++ mozilla/media/libsoundtouch/src/soundtouch_perms.h |
| 332 |
@@ -12,7 +12,9 @@ |
255 |
@@ -12,7 +12,9 @@ |
|
Lines 340-346
index 0af2fe6..d80c145 100644
Link Here
|
| 340 |
|
263 |
|
| 341 |
#endif // MOZILLA_SOUNDTOUCH_PERMS_H |
264 |
#endif // MOZILLA_SOUNDTOUCH_PERMS_H |
| 342 |
diff --git media/libtheora/README_MOZILLA media/libtheora/README_MOZILLA |
265 |
diff --git media/libtheora/README_MOZILLA media/libtheora/README_MOZILLA |
| 343 |
index d48dbfa..f08a2ed 100644 |
266 |
index d48dbfa6f63d..6f30f250220e 100644 |
| 344 |
--- mozilla/media/libtheora/README_MOZILLA |
267 |
--- mozilla/media/libtheora/README_MOZILLA |
| 345 |
+++ mozilla/media/libtheora/README_MOZILLA |
268 |
+++ mozilla/media/libtheora/README_MOZILLA |
| 346 |
@@ -3,3 +3,6 @@ using the update.sh script. The changes made were those applied by update.sh, |
269 |
@@ -3,3 +3,6 @@ using the update.sh script. The changes made were those applied by update.sh, |
|
Lines 351-360
index d48dbfa..f08a2ed 100644
Link Here
|
| 351 |
+The in-tree copy may be omitted during build by --with-system-theora. |
274 |
+The in-tree copy may be omitted during build by --with-system-theora. |
| 352 |
+Keep version in old-configure.in in sync on updates. |
275 |
+Keep version in old-configure.in in sync on updates. |
| 353 |
diff --git media/libtheora/moz.build media/libtheora/moz.build |
276 |
diff --git media/libtheora/moz.build media/libtheora/moz.build |
| 354 |
index 14265b1..3069e99 100644 |
277 |
index c7f85eebff95..aae7b814adb5 100644 |
| 355 |
--- mozilla/media/libtheora/moz.build |
278 |
--- mozilla/media/libtheora/moz.build |
| 356 |
+++ mozilla/media/libtheora/moz.build |
279 |
+++ mozilla/media/libtheora/moz.build |
| 357 |
@@ -21,6 +21,9 @@ if CONFIG['GKMEDIAS_SHARED_LIBRARY']: |
280 |
@@ -21,6 +21,9 @@ FINAL_LIBRARY = 'gkmedias' |
| 358 |
# The encoder is currently not included. |
281 |
# The encoder is currently not included. |
| 359 |
DEFINES['THEORA_DISABLE_ENCODE'] = True |
282 |
DEFINES['THEORA_DISABLE_ENCODE'] = True |
| 360 |
|
283 |
|
|
Lines 362-371
index 14265b1..3069e99 100644
Link Here
|
| 362 |
+ CFLAGS += CONFIG['MOZ_OGG_CFLAGS'] |
285 |
+ CFLAGS += CONFIG['MOZ_OGG_CFLAGS'] |
| 363 |
+ |
286 |
+ |
| 364 |
# Suppress warnings in third-party code. |
287 |
# Suppress warnings in third-party code. |
| 365 |
if CONFIG['GNU_CC']: |
288 |
if CONFIG['GNU_CC'] or CONFIG['CLANG_CL']: |
| 366 |
CFLAGS += ['-Wno-type-limits'] |
289 |
CFLAGS += ['-Wno-type-limits'] |
| 367 |
diff --git media/libtremor/README_MOZILLA media/libtremor/README_MOZILLA |
290 |
diff --git media/libtremor/README_MOZILLA media/libtremor/README_MOZILLA |
| 368 |
index ee67b53..3f34a09 100644 |
291 |
index ee67b53a05c5..81c971773d55 100644 |
| 369 |
--- mozilla/media/libtremor/README_MOZILLA |
292 |
--- mozilla/media/libtremor/README_MOZILLA |
| 370 |
+++ mozilla/media/libtremor/README_MOZILLA |
293 |
+++ mozilla/media/libtremor/README_MOZILLA |
| 371 |
@@ -5,3 +5,6 @@ Makefile.in files for the Mozilla build system. |
294 |
@@ -5,3 +5,6 @@ Makefile.in files for the Mozilla build system. |
|
Lines 376-395
index ee67b53..3f34a09 100644
Link Here
|
| 376 |
+The in-tree copy may be omitted during build by --with-system-tremor. |
299 |
+The in-tree copy may be omitted during build by --with-system-tremor. |
| 377 |
+Keep version in old-configure.in in sync on updates. |
300 |
+Keep version in old-configure.in in sync on updates. |
| 378 |
diff --git media/libtremor/moz.build media/libtremor/moz.build |
301 |
diff --git media/libtremor/moz.build media/libtremor/moz.build |
| 379 |
index 31831ba..a03d576 100644 |
302 |
index 83afc8e37c64..71ef159da3d7 100644 |
| 380 |
--- mozilla/media/libtremor/moz.build |
303 |
--- mozilla/media/libtremor/moz.build |
| 381 |
+++ mozilla/media/libtremor/moz.build |
304 |
+++ mozilla/media/libtremor/moz.build |
| 382 |
@@ -6,3 +6,5 @@ |
305 |
@@ -9,3 +9,5 @@ with Files('*'): |
| 383 |
|
306 |
|
| 384 |
DIRS += ['include/tremor', 'lib'] |
307 |
DIRS += ['include/tremor', 'lib'] |
| 385 |
|
308 |
|
| 386 |
+if CONFIG['MOZ_SYSTEM_OGG']: |
309 |
+if CONFIG['MOZ_SYSTEM_OGG']: |
| 387 |
+ CFLAGS += CONFIG['MOZ_OGG_CFLAGS'] |
310 |
+ CFLAGS += CONFIG['MOZ_OGG_CFLAGS'] |
| 388 |
diff --git media/libvorbis/README_MOZILLA media/libvorbis/README_MOZILLA |
311 |
diff --git media/libvorbis/README_MOZILLA media/libvorbis/README_MOZILLA |
| 389 |
index 7c7454c..55baedd 100644 |
312 |
index 1211ac074b33..eb31084aed25 100644 |
| 390 |
--- mozilla/media/libvorbis/README_MOZILLA |
313 |
--- mozilla/media/libvorbis/README_MOZILLA |
| 391 |
+++ mozilla/media/libvorbis/README_MOZILLA |
314 |
+++ mozilla/media/libvorbis/README_MOZILLA |
| 392 |
@@ -8,3 +8,6 @@ https://svn.xiph.org/tags/vorbis/libvorbis-1.3.4@19059 |
315 |
@@ -8,3 +8,6 @@ https://svn.xiph.org/tags/vorbis/libvorbis-1.3.5@19464 |
| 393 |
|
316 |
|
| 394 |
Some files are renamed during the copy to prevent clashes with object |
317 |
Some files are renamed during the copy to prevent clashes with object |
| 395 |
file names with other Mozilla libraries. |
318 |
file names with other Mozilla libraries. |
|
Lines 397-417
index 7c7454c..55baedd 100644
Link Here
|
| 397 |
+The in-tree copy may be omitted during build by --with-system-vorbis. |
320 |
+The in-tree copy may be omitted during build by --with-system-vorbis. |
| 398 |
+Keep version in old-configure.in in sync on updates. |
321 |
+Keep version in old-configure.in in sync on updates. |
| 399 |
diff --git media/libvorbis/moz.build media/libvorbis/moz.build |
322 |
diff --git media/libvorbis/moz.build media/libvorbis/moz.build |
| 400 |
index 919b99e..cc776f7 100644 |
323 |
index adf393782cc9..923b76231107 100644 |
| 401 |
--- mozilla/media/libvorbis/moz.build |
324 |
--- mozilla/media/libvorbis/moz.build |
| 402 |
+++ mozilla/media/libvorbis/moz.build |
325 |
+++ mozilla/media/libvorbis/moz.build |
| 403 |
@@ -55,3 +55,6 @@ FINAL_LIBRARY = 'gkmedias' |
326 |
@@ -56,3 +56,6 @@ FINAL_LIBRARY = 'gkmedias' |
| 404 |
# Suppress warnings in third-party code. |
327 |
# Suppress warnings in third-party code. |
| 405 |
if CONFIG['GNU_CC']: |
328 |
if CONFIG['GNU_CC']: |
| 406 |
CFLAGS += ['-Wno-uninitialized'] |
329 |
CFLAGS += ['-Wno-uninitialized'] |
| 407 |
+ |
330 |
+ |
| 408 |
+if CONFIG['MOZ_SYSTEM_OGG']: |
331 |
+if CONFIG['MOZ_SYSTEM_OGG']: |
| 409 |
+ CFLAGS += CONFIG['MOZ_OGG_CFLAGS'] |
332 |
+ CFLAGS += CONFIG['MOZ_OGG_CFLAGS'] |
|
|
333 |
diff --git old-configure.in old-configure.in |
| 334 |
index b614eef85c89..85f9099dba4d 100644 |
| 335 |
--- mozilla/old-configure.in |
| 336 |
+++ mozilla/old-configure.in |
| 337 |
@@ -2941,6 +2941,111 @@ if test -n "$MOZ_OMX_PLUGIN"; then |
| 338 |
fi |
| 339 |
fi |
| 340 |
|
| 341 |
+dnl ======================================================== |
| 342 |
+dnl Check for libogg |
| 343 |
+dnl ======================================================== |
| 344 |
+ |
| 345 |
+MOZ_ARG_WITH_BOOL(system-ogg, |
| 346 |
+[ --with-system-ogg Use system libogg (located with pkgconfig)], |
| 347 |
+MOZ_SYSTEM_OGG=1, |
| 348 |
+MOZ_SYSTEM_OGG=) |
| 349 |
+ |
| 350 |
+if test -n "$MOZ_SYSTEM_OGG"; then |
| 351 |
+ PKG_CHECK_MODULES(MOZ_OGG, ogg >= 1.3.0) |
| 352 |
+ |
| 353 |
+ _SAVE_LIBS=$LIBS |
| 354 |
+ LIBS="$LIBS $MOZ_OGG_LIBS" |
| 355 |
+ AC_CHECK_FUNC(ogg_set_mem_functions, [], |
| 356 |
+ [AC_DEFINE(MOZ_OGG_NO_MEM_REPORTING)]) |
| 357 |
+ LIBS=$_SAVE_LIBS |
| 358 |
+fi |
| 359 |
+ |
| 360 |
+AC_SUBST(MOZ_SYSTEM_OGG) |
| 361 |
+ |
| 362 |
+dnl ======================================================== |
| 363 |
+dnl Check for libvorbis |
| 364 |
+dnl ======================================================== |
| 365 |
+ |
| 366 |
+MOZ_ARG_WITH_BOOL(system-vorbis, |
| 367 |
+[ --with-system-vorbis Use system libvorbis (located with pkgconfig)], |
| 368 |
+MOZ_SYSTEM_VORBIS=1, |
| 369 |
+MOZ_SYSTEM_VORBIS=) |
| 370 |
+ |
| 371 |
+if test -n "$MOZ_SYSTEM_VORBIS"; then |
| 372 |
+ PKG_CHECK_MODULES(MOZ_VORBIS, vorbis vorbisenc >= 1.3.5) |
| 373 |
+fi |
| 374 |
+ |
| 375 |
+AC_SUBST(MOZ_SYSTEM_VORBIS) |
| 376 |
+ |
| 377 |
+dnl ======================================================== |
| 378 |
+dnl Check for integer-only libvorbis aka tremor |
| 379 |
+dnl ======================================================== |
| 380 |
+ |
| 381 |
+MOZ_ARG_WITH_BOOL(system-tremor, |
| 382 |
+[ --with-system-tremor Use system libtremor (located with pkgconfig)], |
| 383 |
+MOZ_SYSTEM_TREMOR=1, |
| 384 |
+MOZ_SYSTEM_TREMOR=) |
| 385 |
+ |
| 386 |
+if test -n "$MOZ_SYSTEM_TREMOR"; then |
| 387 |
+ PKG_CHECK_MODULES(MOZ_TREMOR, vorbisidec >= 1.2.1) |
| 388 |
+fi |
| 389 |
+ |
| 390 |
+AC_SUBST(MOZ_SYSTEM_TREMOR) |
| 391 |
+ |
| 392 |
+dnl ======================================================== |
| 393 |
+dnl Check for libtheora |
| 394 |
+dnl ======================================================== |
| 395 |
+ |
| 396 |
+MOZ_ARG_WITH_BOOL(system-theora, |
| 397 |
+[ --with-system-theora Use system libtheora (located with pkgconfig)], |
| 398 |
+MOZ_SYSTEM_THEORA=1, |
| 399 |
+MOZ_SYSTEM_THEORA=) |
| 400 |
+ |
| 401 |
+if test -n "$MOZ_SYSTEM_THEORA"; then |
| 402 |
+ PKG_CHECK_MODULES(MOZ_THEORA, theora >= 1.2) |
| 403 |
+fi |
| 404 |
+ |
| 405 |
+AC_SUBST(MOZ_SYSTEM_THEORA) |
| 406 |
+ |
| 407 |
+dnl ======================================================== |
| 408 |
+dnl Check for libSoundTouch |
| 409 |
+dnl ======================================================== |
| 410 |
+ |
| 411 |
+MOZ_ARG_WITH_BOOL(system-soundtouch, |
| 412 |
+[ --with-system-soundtouch Use system libSoundTouch (located with pkgconfig)], |
| 413 |
+MOZ_SYSTEM_SOUNDTOUCH=1, |
| 414 |
+MOZ_SYSTEM_SOUNDTOUCH=) |
| 415 |
+ |
| 416 |
+if test -n "$MOZ_SYSTEM_SOUNDTOUCH"; then |
| 417 |
+ PKG_CHECK_MODULES(MOZ_SOUNDTOUCH, soundtouch >= 1.9.0) |
| 418 |
+ |
| 419 |
+ AC_LANG_SAVE |
| 420 |
+ AC_LANG_CPLUSPLUS |
| 421 |
+ _SAVE_CXXFLAGS=$CXXFLAGS |
| 422 |
+ CXXFLAGS="$CXXFLAGS $MOZ_SOUNDTOUCH_CFLAGS" |
| 423 |
+ AC_CACHE_CHECK(for soundtouch sample type, |
| 424 |
+ ac_cv_soundtouch_sample_type, |
| 425 |
+ [AC_TRY_COMPILE([#include <SoundTouch.h> |
| 426 |
+ #ifndef SOUNDTOUCH_INTEGER_SAMPLES |
| 427 |
+ #error soundtouch expects float samples |
| 428 |
+ #endif], |
| 429 |
+ [], |
| 430 |
+ [ac_cv_soundtouch_sample_type=short], |
| 431 |
+ [ac_cv_soundtouch_sample_type=float])]) |
| 432 |
+ CXXFLAGS=$_SAVE_CXXFLAGS |
| 433 |
+ AC_LANG_RESTORE |
| 434 |
+ |
| 435 |
+ if test \( -n "$MOZ_SAMPLE_TYPE_S16" -a "$ac_cv_soundtouch_sample_type" != short \) \ |
| 436 |
+ -o \( -n "$MOZ_SAMPLE_TYPE_FLOAT32" -a "$ac_cv_soundtouch_sample_type" != float \) ; then |
| 437 |
+ AC_MSG_ERROR([SoundTouch library is built with incompatible sample type. Either rebuild the library with/without --enable-integer-samples, chase default Mozilla sample type or remove --with-system-soundtouch.]) |
| 438 |
+ fi |
| 439 |
+fi |
| 440 |
+ |
| 441 |
+if test -n "$MOZ_SYSTEM_SOUNDTOUCH"; then |
| 442 |
+ AC_DEFINE(MOZ_SYSTEM_SOUNDTOUCH) |
| 443 |
+fi |
| 444 |
+AC_SUBST(MOZ_SYSTEM_SOUNDTOUCH) |
| 445 |
+ |
| 446 |
dnl system libvpx Support |
| 447 |
dnl ======================================================== |
| 448 |
MOZ_ARG_WITH_BOOL(system-libvpx, |
| 410 |
diff --git toolkit/library/moz.build toolkit/library/moz.build |
449 |
diff --git toolkit/library/moz.build toolkit/library/moz.build |
| 411 |
index d42137a..695e75a8 100644 |
450 |
index 079a575adec3..514d901195de 100644 |
| 412 |
--- mozilla/toolkit/library/moz.build |
451 |
--- mozilla/toolkit/library/moz.build |
| 413 |
+++ mozilla/toolkit/library/moz.build |
452 |
+++ mozilla/toolkit/library/moz.build |
| 414 |
@@ -178,6 +178,21 @@ if CONFIG['MOZ_SYSTEM_PNG']: |
453 |
@@ -237,6 +237,21 @@ if CONFIG['MOZ_SYSTEM_HARFBUZZ']: |
| 415 |
if CONFIG['MOZ_SYSTEM_HUNSPELL']: |
454 |
if CONFIG['MOZ_SYSTEM_HUNSPELL']: |
| 416 |
OS_LIBS += CONFIG['MOZ_HUNSPELL_LIBS'] |
455 |
OS_LIBS += CONFIG['MOZ_HUNSPELL_LIBS'] |
| 417 |
|
456 |
|
|
Lines 434-453
index d42137a..695e75a8 100644
Link Here
|
| 434 |
OS_LIBS += CONFIG['MOZ_LIBEVENT_LIBS'] |
473 |
OS_LIBS += CONFIG['MOZ_LIBEVENT_LIBS'] |
| 435 |
|
474 |
|
| 436 |
diff --git xpcom/build/XPCOMInit.cpp xpcom/build/XPCOMInit.cpp |
475 |
diff --git xpcom/build/XPCOMInit.cpp xpcom/build/XPCOMInit.cpp |
| 437 |
index 2cf281e..6d7af0e 100644 |
476 |
index c083ab4bc4f3..62b917043a2c 100644 |
| 438 |
--- mozilla/xpcom/build/XPCOMInit.cpp |
477 |
--- mozilla/xpcom/build/XPCOMInit.cpp |
| 439 |
+++ mozilla/xpcom/build/XPCOMInit.cpp |
478 |
+++ mozilla/xpcom/build/XPCOMInit.cpp |
| 440 |
@@ -138,7 +138,9 @@ extern nsresult nsStringInputStreamConstructor(nsISupports*, REFNSIID, void**); |
479 |
@@ -154,7 +154,9 @@ extern nsresult nsStringInputStreamConstructor(nsISupports*, REFNSIID, void**); |
| 441 |
#include "mozilla/VisualEventTracer.h" |
480 |
|
| 442 |
#endif |
481 |
#include "mozilla/ipc/GeckoChildProcessHost.h" |
| 443 |
|
482 |
|
| 444 |
+#ifndef MOZ_OGG_NO_MEM_REPORTING |
483 |
+#ifndef MOZ_OGG_NO_MEM_REPORTING |
| 445 |
#include "ogg/ogg.h" |
484 |
#include "ogg/ogg.h" |
| 446 |
+#endif |
485 |
+#endif |
| 447 |
#if defined(MOZ_VPX) && !defined(MOZ_VPX_NO_MEM_REPORTING) |
486 |
#if defined(MOZ_VPX) && !defined(MOZ_VPX_NO_MEM_REPORTING) |
| 448 |
#include "vpx_mem/vpx_mem.h" |
487 |
#if defined(HAVE_STDINT_H) |
| 449 |
#endif |
488 |
// mozilla-config.h defines HAVE_STDINT_H, and then it's defined *again* in |
| 450 |
@@ -651,11 +653,13 @@ NS_InitXPCOM2(nsIServiceManager** aResult, |
489 |
@@ -664,11 +666,13 @@ NS_InitXPCOM2(nsIServiceManager** aResult, |
| 451 |
// this oddness. |
490 |
// this oddness. |
| 452 |
mozilla::SetICUMemoryFunctions(); |
491 |
mozilla::SetICUMemoryFunctions(); |
| 453 |
|
492 |
|