Ry,
I made the following changes to get ebb compiling on Ruby 1.9.
Specifically, the version I have running at my end is version 1.9.1p0
(2009-01-30 revision 21907) [i686-linux].
1. I have added conditional include for TRAP_BEG and TRAP_END
macros (that were used to save errno) and “rubysig.h”. These have been
marked obsolete in version 1.9 and are not required in it.
2. The gem was getting built successfully but the .rb files were
missing in it. I have included .rb files in the gem specification.
After successful installation, I got another error while accessing an
application deployed on ebb.
/usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/
active_support/dependencies.rb:105:in `rescue in const_missing':
uninitialized constant Rack::Adapter::Rails::CGIWrapper::Thin
(NameError)
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/
active_support/dependencies.rb:94:in `const_missing'
from /usr/local/lib/ruby/gems/1.9.1/gems/ebb-0.3.3/lib/rack/adapter/
rails.rb:123:in `header'
from /usr/local/lib/ruby/gems/1.9.1/gems/actionpack-2.3.2/lib/
action_controller/cgi_process.rb:55:in `dispatch_cgi'
from /usr/local/lib/ruby/gems/1.9.1/gems/actionpack-2.3.2/lib/
action_controller/dispatcher.rb:102:in `dispatch_cgi'
from /usr/local/lib/ruby/gems/1.9.1/gems/actionpack-2.3.2/lib/
action_controller/dispatcher.rb:28:in `dispatch'
from /usr/local/lib/ruby/gems/1.9.1/gems/ebb-0.3.3/lib/rack/adapter/
rails.rb:57:in `serve_rails'
from /usr/local/lib/ruby/gems/1.9.1/gems/ebb-0.3.3/lib/rack/adapter/
rails.rb:77:in `call'
from /usr/local/lib/ruby/gems/1.9.1/gems/ebb-0.3.3/lib/ebb.rb:88:in
`block in process'
from /usr/local/lib/ruby/gems/1.9.1/gems/ebb-0.3.3/lib/ebb.rb:87:in
`catch'
from /usr/local/lib/ruby/gems/1.9.1/gems/ebb-0.3.3/lib/ebb.rb:87:in
`process'
from /usr/local/lib/ruby/gems/1.9.1/gems/ebb-0.3.3/lib/ebb.rb:75:in
`start_server'
from /usr/local/lib/ruby/gems/1.9.1/gems/ebb-0.3.3/lib/ebb/runner.rb:
120:in `run'
from /usr/local/lib/ruby/gems/1.9.1/gems/ebb-0.3.3/bin/ebb_rails:5:in
`<top (required)>'
from /usr/local/bin/ebb_rails:19:in `load'
from /usr/local/bin/ebb_rails:19:in `<main>'
This looked like an issue of using "Thin.ruby_18?" (Line 123 of rack/
adapter/rails.rb), used to check the ruby version. Replacing this with
"RUBY_VERSION =~ /^1\.8/" resolved out the issue.
After making all the above changes, ebb now runs successfully on both
Ruby 1.8 and 1.9. I have committed all the changes in my fork and sent
you a pull request. Please do have a look on it.
http://github.com/dharmarth/ebb/tree/master
Rui,
You can refer my fork till these changes appear in the main
repository.
Thanks,
Dharmarth
Impetus Technologies