No such file or directory - /usr/local/lib/ruby/1.8/sparc-solaris2.10/readline.so (LoadError)

I am trying to run console on a Solaris server and I get this error:

-bash-3.00$ script/console
Loading development environment (Rails 2.3.4)
/usr/local/lib/ruby/1.8/sparc-solaris2.10/readline.so: ld.so.1: ruby:
fatal: libedit.so.0: open failed: No such file or directory - /usr/
local/lib/ruby/1.8/sparc-solaris2.10/readline.so (LoadError)
        from /usr/local/lib/ruby/1.8/irb/completion.rb:10
        from /usr/local/lib/ruby/1.8/irb/init.rb:252:in `require'
        from /usr/local/lib/ruby/1.8/irb/init.rb:252:in `load_modules'
        from /usr/local/lib/ruby/1.8/irb/init.rb:250:in `each'
        from /usr/local/lib/ruby/1.8/irb/init.rb:250:in `load_modules'
        from /usr/local/lib/ruby/1.8/irb/init.rb:21:in `setup'
        from /usr/local/lib/ruby/1.8/irb.rb:54:in `start'
        from /usr/local/bin/irb:13
-bash-3.00$

Do you know how to solve this?