I sent this to the wrong email address a while back. I don't recall it
coming up since then, so I'm resending it just in case it is still an
outstanding issue.

 $ rdoc --ri -M -a --op='doc/ri'  lib

                           peer.rb: mm................
                          class.rb: c.
                            oni.rb:
                         remote.rb: cmc..
                            oni.rb:
Generating RI...
/usr/lib/ruby/1.8/rdoc/ri/ri_cache.rb:31:in `open': No such file or
directory - doc/ri (Errno::ENOENT)
       from /usr/lib/ruby/1.8/rdoc/ri/ri_cache.rb:31:in `foreach'
       from /usr/lib/ruby/1.8/rdoc/ri/ri_cache.rb:31:in `load_from'
       from /usr/lib/ruby/1.8/rdoc/ri/ri_cache.rb:182:in `initialize'
       from /usr/lib/ruby/1.8/rdoc/ri/ri_cache.rb:181:in `each'
       from /usr/lib/ruby/1.8/rdoc/ri/ri_cache.rb:181:in `initialize'
       from /usr/lib/ruby/1.8/rdoc/generators/ri_generator.rb:238:in `new'
       from /usr/lib/ruby/1.8/rdoc/generators/ri_generator.rb:238:in
`update_or_replace'
       from /usr/lib/ruby/1.8/rdoc/generators/ri_generator.rb:130:in
`generate_class_info'
       from /usr/lib/ruby/1.8/rdoc/generators/ri_generator.rb:90:in
`process_class'
       from /usr/lib/ruby/1.8/rdoc/generators/ri_generator.rb:85:in `generate'
       from /usr/lib/ruby/1.8/rdoc/generators/ri_generator.rb:84:in `each'
       from /usr/lib/ruby/1.8/rdoc/generators/ri_generator.rb:84:in `generate'
       from /usr/lib/ruby/1.8/rdoc/rdoc.rb:284:in `document'
       from /usr/bin/rdoc:63

It's the -M options causing the error when no doc/ri directory exists.
Odd thing is, it does create the doc/ri directory.

Maybe this has already been addressed, but just case.

T.