It looks like you have replaced the default Ruby version with a version of Ruby that doesn't include pathname. on its module search path. Fix your Ruby installation, or point /usr/bin/ruby to the default installation. For me it's the following:
lrwxr-xr-x 1 root wheel 76 30 Jun 2010 /usr/bin/ruby -> ../../System/Library/Frameworks/Ruby.framework/Versions/Current/usr/bin/ruby
To be sure, run the following command and check these directories for a file called pathname.rb:
$ /usr/bin/ruby -e "puts $:"
/Library/Ruby/Site/1.8
/Library/Ruby/Site/1.8/powerpc-darwin10.0
/Library/Ruby/Site/1.8/universal-darwin10.0
/Library/Ruby/Site
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/vendor_ruby/1.8
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/vendor_ruby/1.8/universal-darwin10.0
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/vendor_ruby
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/powerpc-darwin10.0
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/universal-darwin10.0
.
I found pathname.rb in the second group of directories:
find /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby -iname "pathname.rb"
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/pathname.rb