RubyCocoa LoadError

G

Gianni C

Hey Rubyists,

I'm trying to use the RubyCocoa framework, but I am getting a
LoadError:

`require': no such file to load -- osx/cocoa (LoadError)

RubyCocoa is installed, and *all* the sample applications work
perfectly. Even when I include the correct path (/Library/Frameworks/
RubyCocoa.framework/Resources/ruby/) I get an even better error:

/Library/Frameworks/RubyCocoa.framework/Resources/ruby/osx/objc/
oc_import.rb:14: warning: already initialized constant FRAMEWORK_PATHS
/Library/Frameworks/RubyCocoa.framework/Resources/ruby/osx/objc/
oc_import.rb:19: warning: already initialized constant SIGN_PATHS
/Library/Frameworks/RubyCocoa.framework/Resources/ruby/osx/objc/
oc_import.rb:26: warning: already initialized constant PRE_SIGN_PATHS
NameError: uninitialized constant OSX::RUBYCOCOA_FRAMEWORK_PATHS
from /Library/Frameworks/RubyCocoa.framework/Resources/ruby/
osx/objc/oc_import.rb:29
from /Library/Frameworks/RubyCocoa.framework/Resources/ruby/
osx/objc/oc_all.rb:9:in `require'
from /Library/Frameworks/RubyCocoa.framework/Resources/ruby/
osx/objc/oc_all.rb:9
from /Library/Frameworks/RubyCocoa.framework/Resources/ruby/
osx/objc/foundation.rb:8:in `require'
from /Library/Frameworks/RubyCocoa.framework/Resources/ruby/
osx/objc/foundation.rb:8
from /Library/Frameworks/RubyCocoa.framework/Resources/ruby/
osx/objc/cocoa.rb:8:in `require'
from /Library/Frameworks/RubyCocoa.framework/Resources/ruby/
osx/objc/cocoa.rb:8
from /Library/Frameworks/RubyCocoa.framework/Resources/ruby/
osx/cocoa.rb:8:in `require'
from /Library/Frameworks/RubyCocoa.framework/Resources/ruby/
osx/cocoa.rb:8
from (irb):4:in `require'
from (irb):4

Here is my require code:

require 'osx/cocoa'
include OSX
OSX.require_framework 'AddressBook'

Any Idea on what my problem is? I'm sure it's just something silly I
have missed. Thanks in advance,

Gianni C
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,226
Members
46,815
Latest member
treekmostly22

Latest Threads

Top