Fix Mac OS X 10.6 compile problem with libsydneyaudio. b=492072 r=cdouble
authorJosh Aas <joshmoz@gmail.com>
Tue, 19 May 2009 13:19:49 -0400
changeset 28591 998d6f6e95b7a463cf16c43059f286125ee17fbb
parent 28590 11a3e4008446c94d306d4246e3eea4d5ad4dc4f4
child 28592 6dd95b1cba8eae736b5eb9368090c36e5d1b29bf
push idunknown
push userunknown
push dateunknown
reviewerscdouble
bugs492072
milestone1.9.2a1pre
Fix Mac OS X 10.6 compile problem with libsydneyaudio. b=492072 r=cdouble
media/libsydneyaudio/README_MOZILLA
media/libsydneyaudio/include-CoreServices.patch
media/libsydneyaudio/src/sydney_audio_mac.c
media/libsydneyaudio/update.sh
--- a/media/libsydneyaudio/README_MOZILLA
+++ b/media/libsydneyaudio/README_MOZILLA
@@ -4,8 +4,11 @@ applied by update.sh and the addition/up
 the Mozilla build system.
 
 http://svn.annodex.net/libsydneyaudio/trunk
 
 The svn revision number used was r3895.
 
 pause-resume.patch is applied to implement and fix issues
 with pausing and resuming audio streams.
+
+include-CoreServices.patch is applied to include CoreServices headers
+on Mac OS X. Fixes a build failure on Mac OS X 10.6. b=492072
new file mode 100644
--- /dev/null
+++ b/media/libsydneyaudio/include-CoreServices.patch
@@ -0,0 +1,21 @@
+diff --git a/media/libsydneyaudio/src/sydney_audio_mac.c b/media/libsydneyaudio/src/sydney_audio_mac.c
+--- a/media/libsydneyaudio/src/sydney_audio_mac.c
++++ b/media/libsydneyaudio/src/sydney_audio_mac.c
+@@ -29,16 +29,17 @@
+  * and other provisions required by the GPL or the LGPL. If you do not delete
+  * the provisions above, a recipient may use your version of this file under
+  * the terms of any one of the MPL, the GPL or the LGPL.
+  *
+  * ***** END LICENSE BLOCK ***** *
+  */
+ 
+ #include <pthread.h>
++#include <CoreServices/CoreServices.h>
+ #include <AudioUnit/AudioUnit.h>
+ #include "sydney_audio.h"
+ 
+ /*
+  * The Mac's audio interface is based on a "pull" I/O model, which means you
+  * can't just provide a data buffer and tell the audio device to play; you must
+  * register a callback and provide data as the device asks for it. To support
+  * sydney audio's "write-to-play" style interface, we have to buffer up the
--- a/media/libsydneyaudio/src/sydney_audio_mac.c
+++ b/media/libsydneyaudio/src/sydney_audio_mac.c
@@ -29,16 +29,17 @@
  * and other provisions required by the GPL or the LGPL. If you do not delete
  * the provisions above, a recipient may use your version of this file under
  * the terms of any one of the MPL, the GPL or the LGPL.
  *
  * ***** END LICENSE BLOCK ***** *
  */
 
 #include <pthread.h>
+#include <CoreServices/CoreServices.h>
 #include <AudioUnit/AudioUnit.h>
 #include "sydney_audio.h"
 
 /*
  * The Mac's audio interface is based on a "pull" I/O model, which means you
  * can't just provide a data buffer and tell the audio device to play; you must
  * register a callback and provide data as the device asks for it. To support
  * sydney audio's "write-to-play" style interface, we have to buffer up the
--- a/media/libsydneyaudio/update.sh
+++ b/media/libsydneyaudio/update.sh
@@ -1,8 +1,9 @@
 # Usage: ./update.sh <oggplay_src_directory>
 #
 # Copies the needed files from a directory containing the original
 # liboggplay source that we need for the Mozilla HTML5 media support.
 cp $1/include/sydney_audio.h include/sydney_audio.h
 cp $1/src/*.c src/
 cp $1/AUTHORS ./AUTHORS
 patch -p4 <pause-resume.patch
+patch -p4 <include-CoreServices.patch