On Tue, Feb 17, 2009 at 3:13 AM, Roelf Toxopeus <[email protected]> wrote: > > From CMF code: > > lacking System.framework framework System.framework > System.framework > > 0 machofunc _mach_task_self ( -- machtask ) > > Might not be working anymore but I have done this in gforth with: > > include fflib.fs > > library sys /system/library/frameworks/system.framework/system > sys mach_task_self (int) mach_task_self
With the new C interface, it's even easier: s" IOKit" add-lib c-function mach_task_self mach_task_self -- n c-function CFRelease CFRelease a -- void c-function IOServiceOpen IOServiceOpen n n n a -- n c-function IOServiceClose IOServiceClose n -- n c-function IOServiceMatching IOServiceMatching a -- a c-function IOServiceGetMatchingServices IOServiceGetMatchingServices n a a -- n c-function IOIteratorNext IOIteratorNext n -- n c-function IOObjectRelease IOObjectRelease n -- n c-function IOConnectCallScalarMethod IOConnectCallScalarMethod n n a n a a -- n I should have just tried it. ;) Thanks! DaR --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
