Vendored Oniguruma gem MissingSourceFile oregexp

  • Thread starter Matthew Forrest
  • Start date
M

Matthew Forrest

Hi All,

Hoping someone can help me with this. I have installed the Oniguruma gem
by compiling from source and then installing the gem based on the
instructions here:

http://www.goodbyehelicopter.com/2008/02/20/install-oniguruma-on-os-x/

My environment is mac osx leopard running ruby 1.8.6 and rails 2.3.4.

I can now run the following irb session successfully:

irb(main):001:0> require 'rubygems'
=> true
irb(main):002:0> require 'oniguruma'
=> true
irb(main):003:0> require 'uv'
=> true
irb(main):006:0> result = Uv.parse( ".thing {background-color: red}",
"xhtml", "css", true, "amy")
=> "<pre class=\"amy\"><span class=\"line-numbers\"> 1 </span> <span
class=\"TagAttribute\"><span class=\"Punctuation\">.</span>thing</span>
<span class=\"Punctuation\">{</span><span
class=\"LibraryClassType\">background-color</span><span
class=\"Punctuation\">:</span> <span
class=\"LibraryConstant\">red</span><span
class=\"Punctuation\">}</span>\n</pre>"
irb(main):007:0>

Then I vendored the gem using rake gems:unpack:dependencies.

Then when starting the server or running a console in dev mode, when
requiring ultraviolet I get the following error:

Loading development environment (Rails 2.3.4)
irb: warn: can't alias context from irb_context.MissingSourceFile: no such file to load -- oregexp
from
/usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in
`gem_original_require'
from
/usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in
`require'
from
/Users/matthewling/work/personal/codiary/trunk/vendor/rails/activesupport/lib/active_support/dependencies.rb:156:in
`require'
from
/Users/matthewling/work/personal/codiary/trunk/vendor/rails/activesupport/lib/active_support/dependencies.rb:521:in
`new_constants_in'
from
/Users/matthewling/work/personal/codiary/trunk/vendor/rails/activesupport/lib/active_support/dependencies.rb:156:in
`require'
from
/Users/matthewling/work/personal/codiary/trunk/vendor/gems/oniguruma-1.1.0/lib/oniguruma.rb:1
from
/usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`gem_original_require'
from
/usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`require'

I can see that oregexp.c is under vendor -> gems -> oniguruma-1.1.0 ->
ext but not quite sure what the custom require is missing to load the
gem.

Has anyone seen this before or some advice if it looks like a standard
or fixable error? It seems to rather be a rails thing, since I can load
the gem from an irb session properly.

Would really appreciate any help ...

Best

Matt
 
N

Nikolai Lugovoi

Then when starting the server or running a console in dev mode, when
requiring ultraviolet I get the following error:

Loading development environment (Rails 2.3.4)
irb: warn: can't alias context from irb_context.
MissingSourceFile: no such file to load -- oregexp

Did you run

rake gems:build

to build native extensions for vendored gems?
 
M

Matthew Forrest

Nikolai said:
Did you run

rake gems:build

to build native extensions for vendored gems?

Hey Nikolai,

Awesome! That was it, that's what I love about this community, friendly
helpful people everywhere ...

Thanks mate!

Matthew
 

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,755
Messages
2,569,536
Members
45,009
Latest member
GidgetGamb

Latest Threads

Top