読者です 読者をやめる 読者になる 読者になる

redmine を入れる時にはまった点

rails をインストール時に、
「File not found: lib」って出たときの対処。

# gem install rails
Successfully installed activesupport-3.0.6
Successfully installed builder-2.1.2
Successfully installed i18n-0.5.0
Successfully installed activemodel-3.0.6
Successfully installed rack-1.2.2
Successfully installed rack-test-0.5.7
Successfully installed rack-mount-0.6.14
Successfully installed tzinfo-0.3.26
Successfully installed abstract-1.0.0
Successfully installed erubis-2.6.6
Successfully installed actionpack-3.0.6
Successfully installed arel-2.0.9
Successfully installed activerecord-3.0.6
Successfully installed activeresource-3.0.6
Successfully installed mime-types-1.16
Successfully installed polyglot-0.3.1
Successfully installed treetop-1.4.9
Successfully installed mail-2.2.15
Successfully installed actionmailer-3.0.6
Successfully installed thor-0.14.6
Successfully installed railties-3.0.6
Successfully installed bundler-1.0.12
Successfully installed rails-3.0.6
23 gems installed
Installing ri documentation for activesupport-3.0.6...
Installing ri documentation for builder-2.1.2...
ERROR:  While generating documentation for builder-2.1.2
... MESSAGE:   Unhandled special: Special: type=17, text="<!-- HI -->"
... RDOC args: --ri --op /var/lib/gems/1.8/doc/builder-2.1.2/ri --title Builder -- Easy XML Building --main README --line-numbers --quiet lib CHANGES Rakefile README doc/releases/builder-1.2.4.rdoc doc/releases/builder-2.0.0.rdoc doc/releases/builder-2.1.1.rdoc --title builder-2.1.2 Documentation
(continuing with the rest of the installation)
Installing ri documentation for i18n-0.5.0...
Installing ri documentation for activemodel-3.0.6...
Installing ri documentation for rack-1.2.2...
Installing ri documentation for rack-test-0.5.7...
Installing ri documentation for rack-mount-0.6.14...
Installing ri documentation for tzinfo-0.3.26...
Installing ri documentation for abstract-1.0.0...
Installing ri documentation for erubis-2.6.6...
Installing ri documentation for actionpack-3.0.6...
Installing ri documentation for arel-2.0.9...
Installing ri documentation for activerecord-3.0.6...
Installing ri documentation for activeresource-3.0.6...
Installing ri documentation for mime-types-1.16...
Installing ri documentation for polyglot-0.3.1...
Installing ri documentation for treetop-1.4.9...
Installing ri documentation for mail-2.2.15...
Installing ri documentation for actionmailer-3.0.6...
Installing ri documentation for thor-0.14.6...
Installing ri documentation for railties-3.0.6...
Installing ri documentation for bundler-1.0.12...
Installing ri documentation for rails-3.0.6...
File not found: lib

と出たので、以下のコマンドをやった。

# gem -v
1.3.7
# gem query -rn rubygems-update

*** REMOTE GEMS ***

rubygems-update (1.7.2)
# gem install rubygems-update
Successfully installed rubygems-update-1.7.2
1 gem installed
Installing ri documentation for rubygems-update-1.7.2...
Installing RDoc documentation for rubygems-update-1.7.2...
# update_rubygems
RubyGems 1.7.2 installed

=== 1.7.2 / 2011-04-05

* 1 Bug Fix:
  * Warn on loading bad spec array values (ntlm-http gem has nil in its cert
    chain)


------------------------------------------------------------------------------

RubyGems installed the following executables:
        /usr/bin/gem1.8

# gem -v
1.7.2


この時、PATHに「/var/lib/gems/1.8/bin」を追加するのを忘れないこと。
じゃないと、update_rubygems が動かない。