Has anyone tried wrapping user-land IOKit, e.g. #include <IOKit/IOKitLib.h> #include <IOKit/scsi/SCSITaskLib.h> #include <IOKit/usb/IOUSBLib.h> #include <IOKit/storage/IOMedia.h> I'd love to use MacRuby to prototype user-land USB drivers. --- http://wagerlabs.com | @wagerlabs | http://www.linkedin.com/in/joelreymont
On Jan 17, 2011, at 6:18 AM, Joel Reymont wrote:
Has anyone tried wrapping user-land IOKit, e.g.
#include <IOKit/IOKitLib.h> #include <IOKit/scsi/SCSITaskLib.h> #include <IOKit/usb/IOUSBLib.h> #include <IOKit/storage/IOMedia.h>
I'd love to use MacRuby to prototype user-land USB drivers.
+1 This would be way cool... cr
On Jan 17, 2011, at 9:42 PM, Chuck Remes wrote:
I'd love to use MacRuby to prototype user-land USB drivers.
+1
This would be way cool...
The problem here is that you cannot just run gen_bridge_metadata on IOKit.framework. You need to selectively include or exclude a bunch of subdirectories under IOKit/Headers and I don't think gen_bridge_metadata allows for it at the moment. ls /System/Library/Frameworks/IOKit.framework/Headers DV IOReturn.h kext IOBSD.h IOSharedLock.h ndrvsupport IOCFBundle.h IOTypes.h network IOCFPlugIn.h OSMessageNotification.h ppc IOCFSerialize.h audio ps IOCFURLAccess.h avc pwr_mgt IOCFUnserialize.h firewire sbp2 IODataQueueClient.h graphics scsi IODataQueueShared.h hid serial IOKitKeys.h hidsystem storage IOKitLib.h i2c stream IOKitServer.h i386 usb IOMessage.h iokitmig.h --- http://wagerlabs.com | @wagerlabs | http://www.linkedin.com/in/joelreymont
Hi Joel, IOKit.framework should be wrapped in the latest BridgeSupport preview release. If you install it, you should be able to talk to the IOKit APIs from MacRuby, in theory. In practice, I don't think anyone ever tried that yet, so you may hit bugs :) Let us know if you find something wrong. In case you get something simple working, it would be nice to bundle it as sample code, as it might interest other people! Laurent On Jan 17, 2011, at 4:18 AM, Joel Reymont wrote:
Has anyone tried wrapping user-land IOKit, e.g.
#include <IOKit/IOKitLib.h> #include <IOKit/scsi/SCSITaskLib.h> #include <IOKit/usb/IOUSBLib.h> #include <IOKit/storage/IOMedia.h>
I'd love to use MacRuby to prototype user-land USB drivers.
--- http://wagerlabs.com | @wagerlabs | http://www.linkedin.com/in/joelreymont
_______________________________________________ MacRuby-devel mailing list MacRuby-devel@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
On Jan 17, 2011, at 9:48 PM, Laurent Sansonetti wrote:
IOKit.framework should be wrapped in the latest BridgeSupport preview release.
Is this V2?
If you install it, you should be able to talk to the IOKit APIs from MacRuby, in theory.
Where is the bridge support file? --- http://wagerlabs.com | @wagerlabs | http://www.linkedin.com/in/joelreymont
On Jan 17, 2011, at 9:48 PM, Laurent Sansonetti wrote:
IOKit.framework should be wrapped in the latest BridgeSupport preview release. If you install it, you should be able to talk to the IOKit APIs from MacRuby, in theory.
Doesn't seem to work! macirb irb(main):001:0> framework 'IOKit' => true irb(main):002:0> IOMasterPort NameError: uninitialized constant IOMasterPort irb(main):003:0> IOServiceMatching NameError: uninitialized constant IOServiceMatching --- http://wagerlabs.com | @wagerlabs | http://www.linkedin.com/in/joelreymont
Looks like I talked too fast, there isn't any BridgeSupport file for IOKit, even in Preview 2. I will look into it, as I'm planning to roll out a new version soon. Laurent On Jan 17, 2011, at 1:53 PM, Joel Reymont wrote:
On Jan 17, 2011, at 9:48 PM, Laurent Sansonetti wrote:
IOKit.framework should be wrapped in the latest BridgeSupport preview release. If you install it, you should be able to talk to the IOKit APIs from MacRuby, in theory.
Doesn't seem to work!
macirb irb(main):001:0> framework 'IOKit' => true
irb(main):002:0> IOMasterPort NameError: uninitialized constant IOMasterPort
irb(main):003:0> IOServiceMatching NameError: uninitialized constant IOServiceMatching
--- http://wagerlabs.com | @wagerlabs | http://www.linkedin.com/in/joelreymont
_______________________________________________ MacRuby-devel mailing list MacRuby-devel@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
On Jan 17, 2011, at 11:24 PM, Laurent Sansonetti wrote:
Looks like I talked too fast, there isn't any BridgeSupport file for IOKit, even in Preview 2. I will look into it, as I'm planning to roll out a new version soon.
What can I do to help? Assume that I have some time to spare. --- http://wagerlabs.com | @wagerlabs | http://www.linkedin.com/in/joelreymont
participants (3)
-
Chuck Remes
-
Joel Reymont
-
Laurent Sansonetti