Re: [MacRuby-devel] [MacRuby] #747: DietRB doesn't play nicely with wirble

2010-07-02 Thread MacRuby
#747: DietRB doesn't play nicely with wirble
---+
 Reporter:  m...@…  |Owner:  eloy.de.en...@…
 Type:  defect |   Status:  closed 
 Priority:  blocker|Milestone: 
Component:  MacRuby|   Resolution:  wontfix
 Keywords: |  
---+
Changes (by eloy.de.en...@…):

  * status:  new => closed
  * resolution:  => wontfix


Comment:

 The current version of DietRB that’s in MacRuby trunk actually does have a
 deprecation module for IRB.conf, so this specific exception shouldn't
 occur.

 Having said that, there are other parts of Wirble that won't work as is,
 but these (afaik) only involve colorizing the output. Which is something
 you don't need for DietRB, as it already comes with a colorization module
 (irb/ext/colorize), based on Wirble’s color scheme.

 In order to easily decide on which irb version you are, I am adding the
 IRB.version method. Once pushed, you could do something like this:

 {{{
 if IRB.version.include?('DietRB')
   require 'irb/ext/colorize'
 else
   require 'wirble'
   Wirble.init
   Wirble.colorize
 end
 }}}

 If you are using other specific parts of Wirble that don't work, please
 create a new ticket.

-- 
Ticket URL: 
MacRuby 

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] [MacRuby] #754: TCP socket is disconnected when used IO#gets and IO#puts.

2010-07-02 Thread MacRuby
#754: TCP socket is disconnected when used IO#gets and IO#puts.
--+-
 Reporter:  watson1...@…  |   Owner:  lsansone...@…
 Type:  defect|  Status:  new  
 Priority:  blocker   |   Milestone:   
Component:  MacRuby   |Keywords:   
--+-

Comment(by watson1...@…):

 It seems behaviors of  MacRuby's IO#gets as follows:

 1. At first time IO#gets calls
* CFDataGetLength(io_struct->buf) is 0 and calls read_internal().
* IO#gets is waited by read_internal() that data is input.
 2. At second times IO#gets calls
* Output data is stored in io_struct->buf with IO#puts immediately
 before.[[BR]]
  So, CFDataGetLength(io_struct->buf) is not 0 and does not call
 read_internal().
* IO#gets is not waited.
* IO#gets gets a 0 byte data from io_struct->buf. Its data seems a nil
 class.
 3. IO#puts and chomp are called for nil, and the exception is generated.

-- 
Ticket URL: 
MacRuby 

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] [MacRuby] #754: TCP socket is disconnected when used IO#gets and IO#puts.

2010-07-02 Thread MacRuby
#754: TCP socket is disconnected when used IO#gets and IO#puts.
--+-
 Reporter:  watson1...@…  |   Owner:  lsansone...@…
 Type:  defect|  Status:  new  
 Priority:  blocker   |   Milestone:   
Component:  MacRuby   |Keywords:   
--+-

Comment(by watson1...@…):

 I attach a patch file.
 I conform only that test script works.
 So, I think that this patch may have a problem.

-- 
Ticket URL: 
MacRuby 

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


[MacRuby-devel] Using the SystemConfiguration framework

2010-07-02 Thread Michael Jackson
How exactly does one go about using the SystemConfiguration framework
in MacRuby?

http://developer.apple.com/mac/library/documentation/Networking/Reference/SysConfig/index.html

When I try "framework 'SystemConfiguration'" it returns true, but none
of the inline C functions are available. From the reading I've done,
it seems that static C libraries like SystemConfiguration should be
loaded via a BridgeSupport file, but I have no idea how to generate
one in this case.

--
Michael Jackson
http://mjijackson.com
@mjijackson
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] Using the SystemConfiguration framework

2010-07-02 Thread Thibault Martin-Lagardette
To use inline C function you need to generate a dylib using gen_bridge_metatada.
If you do `man gen_bridge_metadata`, you'll see:

> If the custom framework has inline functions and you want to be able to call 
> them, here is how you can generate a ``dylib'' file:
> gen_bridge_metadata -f /Path/To/YourFramework.framework -F dylib -o 
> /Path/To/YourFramework.framework/Resources/BridgeSupport/YourFramework.dylib

Then you just need to require the generated dylib :-)

It looks like this corresponds to what you want to do? :-)

-- 
Thibault Martin-Lagardette



On Jul 2, 2010, at 14:49, Michael Jackson wrote:

> How exactly does one go about using the SystemConfiguration framework
> in MacRuby?
> 
> http://developer.apple.com/mac/library/documentation/Networking/Reference/SysConfig/index.html
> 
> When I try "framework 'SystemConfiguration'" it returns true, but none
> of the inline C functions are available. From the reading I've done,
> it seems that static C libraries like SystemConfiguration should be
> loaded via a BridgeSupport file, but I have no idea how to generate
> one in this case.
> 
> --
> Michael Jackson
> http://mjijackson.com
> @mjijackson
> ___
> MacRuby-devel mailing list
> [email protected]
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] Using the SystemConfiguration framework

2010-07-02 Thread Michael Jackson
It's complaining that there aren't any inline functions in the
SystemConfiguration framework. This is the command I ran and the
output I received:

$ gen_bridge_metadata -f
/System/Library/Frameworks/SystemConfiguration.framework -F dylib -o
SystemConfiguration.dylib
No inline functions in the given framework/library, no need to generate a dylib.

However, this doesn't make any sense to me. The documentation clearly
lists lots of inline functions. C isn't my best language, so maybe I'm
misunderstanding something...

--
Michael Jackson
http://mjijackson.com
@mjijackson



On Fri, Jul 2, 2010 at 4:23 PM, Thibault Martin-Lagardette
 wrote:
> To use inline C function you need to generate a dylib using 
> gen_bridge_metatada.
> If you do `man gen_bridge_metadata`, you'll see:
>
>> If the custom framework has inline functions and you want to be able to call 
>> them, here is how you can generate a ``dylib'' file:
>>     gen_bridge_metadata -f /Path/To/YourFramework.framework -F dylib -o 
>> /Path/To/YourFramework.framework/Resources/BridgeSupport/YourFramework.dylib
>
> Then you just need to require the generated dylib :-)
>
> It looks like this corresponds to what you want to do? :-)
>
> --
> Thibault Martin-Lagardette
>
>
>
> On Jul 2, 2010, at 14:49, Michael Jackson wrote:
>
>> How exactly does one go about using the SystemConfiguration framework
>> in MacRuby?
>>
>> http://developer.apple.com/mac/library/documentation/Networking/Reference/SysConfig/index.html
>>
>> When I try "framework 'SystemConfiguration'" it returns true, but none
>> of the inline C functions are available. From the reading I've done,
>> it seems that static C libraries like SystemConfiguration should be
>> loaded via a BridgeSupport file, but I have no idea how to generate
>> one in this case.
>>
>> --
>> Michael Jackson
>> http://mjijackson.com
>> @mjijackson
>> ___
>> MacRuby-devel mailing list
>> [email protected]
>> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>
> ___
> MacRuby-devel mailing list
> [email protected]
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] Using the SystemConfiguration framework

2010-07-02 Thread Thibault Martin-Lagardette
Which specific inline function are you trying to use?

-- 
Thibault Martin-Lagardette



On Jul 2, 2010, at 15:44, Michael Jackson wrote:

> It's complaining that there aren't any inline functions in the
> SystemConfiguration framework. This is the command I ran and the
> output I received:
> 
> $ gen_bridge_metadata -f
> /System/Library/Frameworks/SystemConfiguration.framework -F dylib -o
> SystemConfiguration.dylib
> No inline functions in the given framework/library, no need to generate a 
> dylib.
> 
> However, this doesn't make any sense to me. The documentation clearly
> lists lots of inline functions. C isn't my best language, so maybe I'm
> misunderstanding something...
> 
> --
> Michael Jackson
> http://mjijackson.com
> @mjijackson
> 
> 
> 
> On Fri, Jul 2, 2010 at 4:23 PM, Thibault Martin-Lagardette
>  wrote:
>> To use inline C function you need to generate a dylib using 
>> gen_bridge_metatada.
>> If you do `man gen_bridge_metadata`, you'll see:
>> 
>>> If the custom framework has inline functions and you want to be able to 
>>> call them, here is how you can generate a ``dylib'' file:
>>> gen_bridge_metadata -f /Path/To/YourFramework.framework -F dylib -o 
>>> /Path/To/YourFramework.framework/Resources/BridgeSupport/YourFramework.dylib
>> 
>> Then you just need to require the generated dylib :-)
>> 
>> It looks like this corresponds to what you want to do? :-)
>> 
>> --
>> Thibault Martin-Lagardette
>> 
>> 
>> 
>> On Jul 2, 2010, at 14:49, Michael Jackson wrote:
>> 
>>> How exactly does one go about using the SystemConfiguration framework
>>> in MacRuby?
>>> 
>>> http://developer.apple.com/mac/library/documentation/Networking/Reference/SysConfig/index.html
>>> 
>>> When I try "framework 'SystemConfiguration'" it returns true, but none
>>> of the inline C functions are available. From the reading I've done,
>>> it seems that static C libraries like SystemConfiguration should be
>>> loaded via a BridgeSupport file, but I have no idea how to generate
>>> one in this case.
>>> 
>>> --
>>> Michael Jackson
>>> http://mjijackson.com
>>> @mjijackson
>>> ___
>>> MacRuby-devel mailing list
>>> [email protected]
>>> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>> 
>> ___
>> MacRuby-devel mailing list
>> [email protected]
>> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>> 
> ___
> MacRuby-devel mailing list
> [email protected]
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] Using the SystemConfiguration framework

2010-07-02 Thread Michael Jackson
Not sure yet. The whole framework is a bit of a mess from my point of
view. I need to be able to tinker a bit in order to figure out how to
use it. ;)

I'd probably start with the SCNetworkConfiguration and SCDynamicStore API's.

--
Michael Jackson
http://mjijackson.com
@mjijackson



On Fri, Jul 2, 2010 at 5:09 PM, Thibault Martin-Lagardette
 wrote:
> Which specific inline function are you trying to use?
>
> --
> Thibault Martin-Lagardette
>
>
>
> On Jul 2, 2010, at 15:44, Michael Jackson wrote:
>
>> It's complaining that there aren't any inline functions in the
>> SystemConfiguration framework. This is the command I ran and the
>> output I received:
>>
>> $ gen_bridge_metadata -f
>> /System/Library/Frameworks/SystemConfiguration.framework -F dylib -o
>> SystemConfiguration.dylib
>> No inline functions in the given framework/library, no need to generate a 
>> dylib.
>>
>> However, this doesn't make any sense to me. The documentation clearly
>> lists lots of inline functions. C isn't my best language, so maybe I'm
>> misunderstanding something...
>>
>> --
>> Michael Jackson
>> http://mjijackson.com
>> @mjijackson
>>
>>
>>
>> On Fri, Jul 2, 2010 at 4:23 PM, Thibault Martin-Lagardette
>>  wrote:
>>> To use inline C function you need to generate a dylib using 
>>> gen_bridge_metatada.
>>> If you do `man gen_bridge_metadata`, you'll see:
>>>
 If the custom framework has inline functions and you want to be able to 
 call them, here is how you can generate a ``dylib'' file:
     gen_bridge_metadata -f /Path/To/YourFramework.framework -F dylib -o 
 /Path/To/YourFramework.framework/Resources/BridgeSupport/YourFramework.dylib
>>>
>>> Then you just need to require the generated dylib :-)
>>>
>>> It looks like this corresponds to what you want to do? :-)
>>>
>>> --
>>> Thibault Martin-Lagardette
>>>
>>>
>>>
>>> On Jul 2, 2010, at 14:49, Michael Jackson wrote:
>>>
 How exactly does one go about using the SystemConfiguration framework
 in MacRuby?

 http://developer.apple.com/mac/library/documentation/Networking/Reference/SysConfig/index.html

 When I try "framework 'SystemConfiguration'" it returns true, but none
 of the inline C functions are available. From the reading I've done,
 it seems that static C libraries like SystemConfiguration should be
 loaded via a BridgeSupport file, but I have no idea how to generate
 one in this case.

 --
 Michael Jackson
 http://mjijackson.com
 @mjijackson
 ___
 MacRuby-devel mailing list
 [email protected]
 http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>>>
>>> ___
>>> MacRuby-devel mailing list
>>> [email protected]
>>> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>>>
>> ___
>> MacRuby-devel mailing list
>> [email protected]
>> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>
> ___
> MacRuby-devel mailing list
> [email protected]
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] Using the SystemConfiguration framework

2010-07-02 Thread John Labovitz
Depending on what you need to do, you should check out IXSCNotificationManager, 
an ObjC wrapper around parts of SC.  I've used it a few times and it's quite 
helpful, and obviously an better impedance match to MacRuby code.  It's 
mentioned & linked here:

http://www.cocoadev.com/index.pl?NotificationOnNewNetwork

--John



On 2 Jul 2010, at 8:03 PM, Michael Jackson wrote:

> Not sure yet. The whole framework is a bit of a mess from my point of
> view. I need to be able to tinker a bit in order to figure out how to
> use it. ;)
> 
> I'd probably start with the SCNetworkConfiguration and SCDynamicStore API's.
> 
> --
> Michael Jackson
> http://mjijackson.com
> @mjijackson
> 
> 
> 
> On Fri, Jul 2, 2010 at 5:09 PM, Thibault Martin-Lagardette
>  wrote:
>> Which specific inline function are you trying to use?
>> 
>> --
>> Thibault Martin-Lagardette
>> 
>> 
>> 
>> On Jul 2, 2010, at 15:44, Michael Jackson wrote:
>> 
>>> It's complaining that there aren't any inline functions in the
>>> SystemConfiguration framework. This is the command I ran and the
>>> output I received:
>>> 
>>> $ gen_bridge_metadata -f
>>> /System/Library/Frameworks/SystemConfiguration.framework -F dylib -o
>>> SystemConfiguration.dylib
>>> No inline functions in the given framework/library, no need to generate a 
>>> dylib.
>>> 
>>> However, this doesn't make any sense to me. The documentation clearly
>>> lists lots of inline functions. C isn't my best language, so maybe I'm
>>> misunderstanding something...
>>> 
>>> --
>>> Michael Jackson
>>> http://mjijackson.com
>>> @mjijackson
>>> 
>>> 
>>> 
>>> On Fri, Jul 2, 2010 at 4:23 PM, Thibault Martin-Lagardette
>>>  wrote:
 To use inline C function you need to generate a dylib using 
 gen_bridge_metatada.
 If you do `man gen_bridge_metadata`, you'll see:
 
> If the custom framework has inline functions and you want to be able to 
> call them, here is how you can generate a ``dylib'' file:
> gen_bridge_metadata -f /Path/To/YourFramework.framework -F dylib -o 
> /Path/To/YourFramework.framework/Resources/BridgeSupport/YourFramework.dylib
 
 Then you just need to require the generated dylib :-)
 
 It looks like this corresponds to what you want to do? :-)
 
 --
 Thibault Martin-Lagardette
 
 
 
 On Jul 2, 2010, at 14:49, Michael Jackson wrote:
 
> How exactly does one go about using the SystemConfiguration framework
> in MacRuby?
> 
> http://developer.apple.com/mac/library/documentation/Networking/Reference/SysConfig/index.html
> 
> When I try "framework 'SystemConfiguration'" it returns true, but none
> of the inline C functions are available. From the reading I've done,
> it seems that static C libraries like SystemConfiguration should be
> loaded via a BridgeSupport file, but I have no idea how to generate
> one in this case.
> 
> --
> Michael Jackson
> http://mjijackson.com
> @mjijackson
> ___
> MacRuby-devel mailing list
> [email protected]
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
 
 ___
 MacRuby-devel mailing list
 [email protected]
 http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
 
>>> ___
>>> MacRuby-devel mailing list
>>> [email protected]
>>> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>> 
>> ___
>> MacRuby-devel mailing list
>> [email protected]
>> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>> 
> ___
> MacRuby-devel mailing list
> [email protected]
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel