[MacRuby-devel] Macruby.framwork into Bundle

Laurent Sansonetti lsansonetti at apple.com
Fri Apr 3 11:34:10 PDT 2009


Hi Markus,

On Mar 31, 2009, at 11:29 AM, Markus Werner wrote:

> Hello List,
>
>
> I used the tutorial and tried to put the Macruby.framework into my  
> Bundle.
> The executable already contains the right "path" to the framework  
> and I copied the Run Script from "Embeded Mac Ruby Target" to my  
> regular target, so the framework is in the bundle.
> (Why is this an extra target at all ?  No criticism, just  
> curiosity :-) )

The target is needed to change the install name path of your  
executable so that it can look for MacRuby.framework inside the bundle  
and not on the /Library filesystem.

> If I do this thing with a virgin application, the application starts  
> on a mac without macruby installed, but if I use my learnig project "http://github.com/polarix/iterm-auto-bookmark/tree/master 
> ", the applications starts and quit immediately, without any error.

Do you get anything in the console?

Also, what if you try to start it from the command-line?

   $ ./Path/To/Foo.app/Contents/MacOS/Foo

> BTW
> If somthing went wrong, on a call to a method (ruby or object-c  
> object) you alway get a "NoMethodError" even if the method exists.
> The same thing applies to RubyCocoa.
>
> See http://discussions.apple.com/thread.jspa?threadID=1957372&tstart=60 
>  if you like. :-D

This looks like a problem with the appscript code, but maybe there is  
a bug in MacRuby too... I will have a look (this macruby-appscript  
library looks very cool!).

Laurent


More information about the MacRuby-devel mailing list