Onno van der Straaten
2007-Oct-30 21:10 UTC
"`require'': no such file to load" while running script/console
Hi, I setting up a new server on Linux server running SuSE Linux Entreprise Server 10. While trying to run script/console I get an error that I don''t understand. Any pointers to fix this will be greatly appreciated as really between a rock and a hard place with RoR. Thans and Regards, Onno user@epf:~> ruby -v ruby 1.8.6 (2007-03-13 patchlevel 0) [x86_64-linux] user@epf:~> rails -v Rails 1.2.4 user@epf:~> rails test create create app/controllers ... (lines deleted) create log/test.log user@epf:~> cd test user@epf:~/test> ruby script/console Loading development environment. /usr/lib/ruby/1.8/irb/completion.rb:10:in `require'': no such file to load -- readline (LoadError) from /usr/lib/ruby/1.8/irb/completion.rb:10 from /usr/lib/ruby/1.8/irb/init.rb:252:in `require'' from /usr/lib/ruby/1.8/irb/init.rb:252:in `load_modules'' from /usr/lib/ruby/1.8/irb/init.rb:250:in `each'' from /usr/lib/ruby/1.8/irb/init.rb:250:in `load_modules'' from /usr/lib/ruby/1.8/irb/init.rb:21:in `setup'' from /usr/lib/ruby/1.8/irb.rb:54:in `start'' from /usr/bin/irb:13 user@epf:~/test> --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Frederick Cheung
2007-Oct-30 23:39 UTC
Re: "`require'': no such file to load" while running script/console
Looks like ruby wasn''t compiled with readline support. You should make sure you do have the readline library available and its development headers etc... When you compile ruby you can tell it where to look for the readline stuff. Fred --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Onno van der Straaten
2007-Oct-31 14:00 UTC
Re: "`require'': no such file to load" while running script/console
You are right, it turns out it wasn''t available on that distribution. To be exact, a readline package was installed, but not the one that contained the missing file, which turned out to be readline.h, which I found out by recompiling the readline support: The following shows that some readline package was installed: epf:/home/user/migration/soft # rpm -ivh readline-5.2-7.x86_64.rpm warning: readline-5.2-7.x86_64.rpm: Header V3 DSA signature: NOKEY, key ID 844c4360 Preparing... ########################################### [100%] package readline-5.2-7 is already installed epf:/home/user/migration/soft # The following showed me the exact file that was missing: readline.h user@epf:~/migration/soft/ruby-1.8.6/ext/readline> ruby extconf.rb checking for tgetnum() in -lncurses... yes checking for readline/readline.h... no checking for editline/readline.h... no I was able to locate a RPM containing readline.h using http://rpm.pbone.net: ftp://ftp.gwdg.de/pub/linux/misc/suser-jengelh/SUSE-10.2/x86_64/readline-devel-5.2-7.x86_64.rpm. After installing that I could compile the readline support in Ruby with ruby extconf.rb: ruby extconf.rb (in /ruby-1.8.6/ext/readline) make sudo make install So it turns out that for Rails on Linux server running SuSE Linux Entreprise Server 10 you need to install this manually. Thanks and Regards, Onno --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---