aboutsummaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorMemphiz <memphis@machzwo.de>2012-10-21 21:41:07 +0200
committerMemphiz <memphis@machzwo.de>2012-10-21 22:34:24 +0200
commitba4a73b496698cfab974a6dec17d2d05f5e5245a (patch)
tree6293d0623d93de3be54e4b897600b4d6a86c2073 /tools
parent2289464baba9ea9359e84ce6ba377893a0f0c49e (diff)
[osx] - fix dvd detection - libcdio for sdk 10.6 (our old autoconf gives only "darwin" for $host_os - without version - so we just allow all in libcdio's configure)
Diffstat (limited to 'tools')
-rw-r--r--tools/darwin/depends/libcdio/Makefile5
-rw-r--r--tools/darwin/depends/libcdio/osx-10.6.patch55
-rw-r--r--tools/darwin/depends/libcdio/osx-10.7.patch12
3 files changed, 72 insertions, 0 deletions
diff --git a/tools/darwin/depends/libcdio/Makefile b/tools/darwin/depends/libcdio/Makefile
index 32455db1f6..c9ca4a96e0 100644
--- a/tools/darwin/depends/libcdio/Makefile
+++ b/tools/darwin/depends/libcdio/Makefile
@@ -20,12 +20,17 @@ $(SOURCE): $(TARBALLS_LOCATION)/$(ARCHIVE)
rm -rf $(SOURCE)
$(ARCHIVE_TOOL) $(ARCHIVE_TOOL_FLAGS) $(TARBALLS_LOCATION)/$(ARCHIVE)
echo $(SOURCE) > .gitignore
+ cd $(SOURCE); patch -p1 < ../osx-10.6.patch
+ cd $(SOURCE); patch -p1 < ../osx-10.7.patch
cd $(SOURCE); autoconf
cd $(SOURCE); $(CONFIGURE)
$(LIBDYLIB): $(SOURCE)
make -j $(MAKE_JOBS) -C $(SOURCE)
+.del:
+ echo nothing
+
.installed:
make -C $(SOURCE) install
cp $(SOURCE)/include/cdio/cdtext.h $(PREFIX)/include/cdio/
diff --git a/tools/darwin/depends/libcdio/osx-10.6.patch b/tools/darwin/depends/libcdio/osx-10.6.patch
new file mode 100644
index 0000000000..18768caadf
--- /dev/null
+++ b/tools/darwin/depends/libcdio/osx-10.6.patch
@@ -0,0 +1,55 @@
+MacBook% diff -rwu libcdio-0.83.orig libcdio-0.83
+diff -rwu libcdio-0.83.orig/configure libcdio-0.83/configure
+--- a/configure-ac 2011-10-27 13:23:40.000000000 +1100
++++ b/configure.ac 2012-04-09 19:11:50.000000000 +1000
+@@ -350,7 +350,7 @@
+ ## AC_DEFINE([HAVE_AIX_CDROM], [1],
+ ## [Define 1 if you have AIX CD-ROM support])
+ ;;
+- darwin6*|darwin7*|darwin8*|darwin9*)
++ darwin6*|darwin7*|darwin8*|darwin9*|darwin10*|darwin*)
+ AC_CHECK_HEADERS(IOKit/IOKitLib.h CoreFoundation/CFBase.h,
+ [have_iokit_h="yes"])
+ if test "x$have_iokit_h" = "xyes" ; then
+diff -rwu libcdio-0.83.orig/lib/driver/osx.c libcdio-0.83/lib/driver/osx.c
+--- libcdio-0.83.orig/lib/driver/osx.c 2011-10-21 10:16:20.000000000 +1100
++++ libcdio-0.83/lib/driver/osx.c 2012-04-26 14:23:02.000000000 +1000
+@@ -56,7 +56,7 @@
+
+ #include <mach/mach.h>
+ #include <Carbon/Carbon.h>
+-#include <IOKit/scsi-commands/SCSITaskLib.h>
++#include <IOKit/scsi/SCSITaskLib.h>
+ #include <IOKit/IOCFPlugIn.h>
+ #include <mach/mach_error.h>
+
+@@ -75,7 +75,7 @@
+ #include <CoreFoundation/CoreFoundation.h>
+ #include <IOKit/IOKitLib.h>
+ #include <IOKit/IOBSD.h>
+-#include <IOKit/scsi-commands/IOSCSIMultimediaCommandsDevice.h>
++#include <IOKit/scsi/IOSCSIMultimediaCommandsDevice.h>
+ #include <IOKit/storage/IOCDTypes.h>
+ #include <IOKit/storage/IODVDTypes.h>
+ #include <IOKit/storage/IOMedia.h>
+@@ -1826,6 +1827,11 @@
+
+ do
+ {
++ /* Skip other removable media, like USB flash memory keys: */
++ if (!IOObjectConformsTo(next_media, kIODVDMediaClass) &&
++ !IOObjectConformsTo(next_media, kIOCDMediaClass))
++ continue;
++
+ str_bsd_path = IORegistryEntryCreateCFProperty( next_media,
+ CFSTR( kIOBSDNameKey ),
+ kCFAllocatorDefault,
+@@ -1856,6 +1862,7 @@
+ } while( ( next_media = IOIteratorNext( media_iterator ) ) != 0 );
+ }
+ IOObjectRelease( media_iterator );
++ cdio_warn ("cdio_get_default_device() - No mounted CDs or DVDs - returning NULL");
+ return NULL;
+ #endif /* HAVE_DARWIN_CDROM */
+ }
+
diff --git a/tools/darwin/depends/libcdio/osx-10.7.patch b/tools/darwin/depends/libcdio/osx-10.7.patch
new file mode 100644
index 0000000000..b216d47fe0
--- /dev/null
+++ b/tools/darwin/depends/libcdio/osx-10.7.patch
@@ -0,0 +1,12 @@
+diff --git a/lib/driver/gnu_linux.c b/lib/driver/gnu_linux.c
+index 6e4b050..65e4023 100644
+--- a/lib/driver/gnu_linux.c
++++ b/lib/driver/gnu_linux.c
+@@ -36,7 +36,6 @@
+ #include <cdio/mmc_cmds.h>
+ #include <cdio/audio.h>
+ #include <cdio/cdtext.h>
+-#include "cdtext_private.h"
+ #include "cdio_assert.h"
+ #include "cdio_private.h"
+