|
Mac OS X 10.3 CD-ROM Driver Patch: msg#00103emulators.bochs.devel
Greetings, I needed to make some minor changes to get cdrom.cc to build here on Mac OS X 10.3.1 (darwin 7.0.0) with gcc 3.3. It should build on any system greater than or equal to Mac OS X 10.1. I doubt that there are many people out there running 10.0 these days. Following is the patch: diff -c3p bochs-2.1.pre1-orig/iodev/cdrom.cc bochs-2.1.pre1-new/iodev/cdrom.cc *** bochs-2.1.pre1-orig/iodev/cdrom.cc Tue Sep 30 20:52:53 2003 --- bochs-2.1.pre1-new/iodev/cdrom.cc Wed Nov 19 19:53:51 2003 *************** static kern_return_t FindEjectableCDMedi *** 196,201 **** --- 196,202 ---- mach_port_t *masterPort ) { kern_return_t kernResult; + int foo; CFMutableDictionaryRef classesToMatch; kernResult = IOMasterPort( bootstrap_port, masterPort ); if ( kernResult != KERN_SUCCESS ) *************** static kern_return_t FindEjectableCDMedi *** 212,222 **** // Each IOMedia object has a property with key kIOMediaEjectable // which is true if the media is indeed ejectable. So add property // to CFDictionary for matching. ! CFDictionarySetValue( classesToMatch, ! CFSTR( kIOMediaEjectable ), kCFBooleanTrue ); } ! kernResult = IOServiceGetMatchingServices( *masterPort, ! classesToMatch, mediaIterator ); if ( (kernResult != KERN_SUCCESS) || (*mediaIterator == NULL) ) fprintf( stderr, "No ejectable CD media found.\n kernResult = %d\n", kernResult ); --- 213,221 ---- // Each IOMedia object has a property with key kIOMediaEjectable // which is true if the media is indeed ejectable. So add property // to CFDictionary for matching. ! CFDictionarySetValue( classesToMatch, CFSTR( kIOMediaEjectableKey ), kCFBooleanTrue ); } ! kernResult = IOServiceGetMatchingServices( *masterPort, classesToMatch, mediaIterator ); if ( (kernResult != KERN_SUCCESS) || (*mediaIterator == NULL) ) fprintf( stderr, "No ejectable CD media found.\n kernResult = %d\n", kernResult ); *************** static kern_return_t GetDeviceFilePath( *** 236,245 **** } else { ! CFTypeRef deviceFilePathAsCFString; ! deviceFilePathAsCFString = IORegistryEntryCreateCFProperty( ! nextMedia, CFSTR( kIOBSDName ), ! kCFAllocatorDefault, 0 ); *deviceFilePath = '\0'; if ( deviceFilePathAsCFString ) { --- 235,245 ---- } else { ! CFTypeRef deviceFilePathAsCFString = nil; ! deviceFilePathAsCFString = IORegistryEntryCreateCFProperty( nextMedia, ! CFSTR( kIOBSDNameKey ), ! kCFAllocatorDefault, ! 0 ); *deviceFilePath = '\0'; if ( deviceFilePathAsCFString ) { _____________End Patch Jeshua Lacock __________________________ Programmer/Owner Phone: 760.935.4736 http://OpenOSX.com Fax: 760.935.4845 -_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ ------------------------------------------------------- This SF.net email is sponsored by: SF.net Giveback Program. Does SourceForge.net help you be more productive? Does it help you create better code? SHARE THE LOVE, and help us help YOU! Click Here: http://sourceforge.net/donate/ |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Alphonso Free ebay course tug: 00103, Sandy Becker |
|---|---|
| Next by Date: | Re: imagine more size. ecstasy r bg jujvmul vqxh ai: 00103, Damien Mckee |
| Previous by Thread: | Alphonso Free ebay course tugi: 00103, Sandy Becker |
| Next by Thread: | Re: imagine more size. ecstasy r bg jujvmul vqxh ai: 00103, Damien Mckee |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |