[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

problems with rubycocoa on macosx 10.3.8 w/ ruby 1.8.1

jm

2/21/2005 3:35:00 AM

$ ruby -v
ruby 1.8.1 (2003-12-25) [powerpc-darwin]

Installed rubycocoa-0.4.1-panther.tgz with the following

$ ruby ./install config
$ ruby ./install setup
$ ruby ./install install

tried and ran into problems with

$ ruby sample/HelloWorld.rb
/Users/gg/ulocal//lib/ruby/site_ruby/1.8/osx/cocoa.rb:12:in `require':
No such file to load -- osx/objc/cocoa (LoadError)
from /Users/gg/ulocal//lib/ruby/site_ruby/1.8/osx/cocoa.rb:12
from sample/HelloWorld.rb:14:in `require'
from sample/HelloWorld.rb:14

I found this in
/Library//Frameworks/RubyCocoa.framework/Versions/Current/Resources/
ruby/osx/objc/ and tried putting in a symbolic only to be rewarded with
"undefined superclass `ObjcID' (TypeError)"
Perhaps, surprisingly "open Simple.app" worked from the beginning.

So has anybody got this working? If so, how?

Alternative ideas on working with ruby on cocoa also welcome.

J.



7 Answers

acharlieblue

2/21/2005 8:06:00 AM

0

jm wrote:
> tried and ran into problems with
>
> $ ruby sample/HelloWorld.rb
> /Users/gg/ulocal//lib/ruby/site_ruby/1.8/osx/cocoa.rb:12:in
`require':
> No such file to load -- osx/objc/cocoa (LoadError)
> from
/Users/gg/ulocal//lib/ruby/site_ruby/1.8/osx/cocoa.rb:12
> from sample/HelloWorld.rb:14:in `require'
> from sample/HelloWorld.rb:14
>
> I found this in
> /Library//Frameworks/RubyCocoa.framework/Versions/Current/Resources/
> ruby/osx/objc/ and tried putting in a symbolic only to be rewarded
with
> "undefined superclass `ObjcID' (TypeError)"

Is rubycocoa.bundle properly located in the powerpc-darwin7.2.0 folder?
That's what causes Ruby to link in the RubyCocoa framework, so it seems
to be a problem with that. I don't have the objc folder in my site_ruby
either and RubyCocoa works fine over here.

Also, I found during some of my own troubleshooting that symbolic links
don't always work for RubyCocoa components (and in fact I think I got
that same error when I tried). You'll need to copy the actual resource.

Alexander Kellett

2/21/2005 12:06:00 PM

0

could someone with a clue just make a .dmg? :)
then its likely i'd try ruby-cocoa. but i refuse
to install anything on my mac unless a) its me
that should be making the installer :P or b) there
is a .dmg

i've tried installing manually in the past.
nothing worked with 1.8.x. someone said that
cvs now works. but this is just a tad too clumsy
in my eyes. can't a snapshot version be released
as a .dmg? i'd suffer with a *working* .tgz or
whatever. but nothing i've tried works :(

Alex

On Feb 21, 2005, at 9:09 AM, Charles Steinman wrote:
> jm wrote:
>> tried and ran into problems with
>>
>> $ ruby sample/HelloWorld.rb
>> /Users/gg/ulocal//lib/ruby/site_ruby/1.8/osx/cocoa.rb:12:in
> `require':
>> No such file to load -- osx/objc/cocoa (LoadError)
>> from
> /Users/gg/ulocal//lib/ruby/site_ruby/1.8/osx/cocoa.rb:12
>> from sample/HelloWorld.rb:14:in `require'
>> from sample/HelloWorld.rb:14
>>
>> I found this in
>> /Library//Frameworks/RubyCocoa.framework/Versions/Current/Resources/
>> ruby/osx/objc/ and tried putting in a symbolic only to be rewarded
> with
>> "undefined superclass `ObjcID' (TypeError)"
>
> Is rubycocoa.bundle properly located in the powerpc-darwin7.2.0 folder?
> That's what causes Ruby to link in the RubyCocoa framework, so it seems
> to be a problem with that. I don't have the objc folder in my site_ruby
> either and RubyCocoa works fine over here.
>
> Also, I found during some of my own troubleshooting that symbolic links
> don't always work for RubyCocoa components (and in fact I think I got
> that same error when I tried). You'll need to copy the actual resource.
>



Richard Dale

2/21/2005 1:16:00 PM

0

Alexander Kellett wrote:

> could someone with a clue just make a .dmg? :)
> then its likely i'd try ruby-cocoa. but i refuse
> to install anything on my mac unless a) its me
> that should be making the installer :P or b) there
> is a .dmg
Well a .dmg of QtRuby would be pretty useful, if you know how to do one.
It's a bit of a pain to build on Mac OS X too.

-- Richard

Alexander Kellett

2/21/2005 2:10:00 PM

0

On Feb 21, 2005, at 2:19 PM, Richard Dale wrote:
> Alexander Kellett wrote:
>
>> could someone with a clue just make a .dmg? :)
>> then its likely i'd try ruby-cocoa. but i refuse
>> to install anything on my mac unless a) its me
>> that should be making the installer :P or b) there
>> is a .dmg
> Well a .dmg of QtRuby would be pretty useful, if you know how to do
> one.
> It's a bit of a pain to build on Mac OS X too.

agreed. wanted to postpone until qt4 though on which
we can have a .dmg, an .exe, and .ebuild/.deb/etc.
first fully portable, easy to install, and useful
toolkit with a gui designer :)

Alex



Laurent Sansonetti

2/21/2005 4:27:00 PM

0

Hi,

On Mon, 21 Feb 2005 21:05:46 +0900, Alexander Kellett
<ruby-lists@lypanov.net> wrote:
> could someone with a clue just make a .dmg? :)

See hdiutil(1). It is pretty easy.

Cheers

Laurent


Sam Roberts

2/21/2005 4:59:00 PM

0

Quoteing laurent.sansonetti@gmail.com, on Tue, Feb 22, 2005 at 01:26:33AM +0900:
> Hi,
>
> On Mon, 21 Feb 2005 21:05:46 +0900, Alexander Kellett
> <ruby-lists@lypanov.net> wrote:
> > could someone with a clue just make a .dmg? :)
>
> See hdiutil(1). It is pretty easy.

Making a .dmg is easy, building ruby cocoa can be hard, and making a
dmg that will install ruby-cocoa onto an OS X system so that it is
useable by ruby is hard.

Cheers,
Sam



jm

2/21/2005 10:53:00 PM

0

Thanks to all those who made suggestions.

rubycocoa.bundle was located under
.../ruby/site_ruby/1.8/powerpc-darwin and looked correct to otool. So I
installed from cvs directly and this seems to have worked. At least
HelloWorld.rb works.

Like many out there I would welcome qtruby working on macosx. I gave it
a quick try (qtruby-1.0.6) and ran into the same problems as I did the
last time (got stuck in a configure loop again). This would actually be
more suited to my needs as it is cross platform. While it is true that
GNUstep is cross platform and can be used as a substitute for Cocoa on
other platforms most people are more likely to have QT installed
already; Especially in the case of linux users. For me at least it's a
question of audience.

Thanks again. Now to waste, er, constructively spend the rest of the
day learning cocoa.

Jeff.


On 22/02/2005, at 3:58 AM, Sam Roberts wrote:

> Quoteing laurent.sansonetti@gmail.com, on Tue, Feb 22, 2005 at
> 01:26:33AM +0900:
>> Hi,
>>
>> On Mon, 21 Feb 2005 21:05:46 +0900, Alexander Kellett
>> <ruby-lists@lypanov.net> wrote:
>>> could someone with a clue just make a .dmg? :)
>>
>> See hdiutil(1). It is pretty easy.
>
> Making a .dmg is easy, building ruby cocoa can be hard, and making a
> .dmg that will install ruby-cocoa onto an OS X system so that it is
> useable by ruby is hard.
>
> Cheers,
> Sam
>
>