Config.gem vs require 'somegem'

I am very confused by the config.gem statement in 2.1

If I put config.gem ‘pdf-writer’ in my environment.rb I get the
following error when I try to instanciate a PDF object in my
controller with the statement pdf = PDF::Writer.new

uninitialized constant CollectionsController::PDF

so I try putting require ‘pdf/writer’ in my environment.rb and the
application fails to load with:

no such file to load – pdf-writer /usr/local/lib/site_ruby/1.8/
rubygems/custom_require.rb:27:in gem_original_require' /usr/local/lib/ site_ruby/1.8/rubygems/custom_require.rb:27:inrequire’ /usr/lib/ruby/
gems/1.8/gems/activesupport-2.1.0/lib/active_support/dependencies.rb:
509:in `require’
etc

The gem is in my vendor directory.
I would like to get to the bottom of this as I have had similar
problems with gems in the past and I dont really understand whether I
still need a ‘require’ when I have the ‘config.gem’

Cheers
George

Same problem for me.

I have installed ‘rubyist-aasm’ for restful_authentication, but when I
insert config.gem ‘rubyist-aasm’, I get an error message.