NOTE: Gem::Specification#default_executable= is deprecated with no replacement. It will be removed on or after 2011-10-01.
after doing a:
sudo gem update --system
I just ran the following manually,
gem -v 2>&1 |grep called
and then for each gem returned ran the command,
$ sudo gem pristine rcov -- -build-arg
The sudo part may not be required, I was using an upgraded basic install from Apple.
Example:
~ $ gem -v 2>&1 |grep called
Gem::Specification#has_rdoc= called from /Library/Ruby/Gems/1.8/specifications/actionmailer-2.3.5.gemspec:14.
$ sudo gem pristine actionmailer -- -build-arg
...
Restored actionmailer-3.0.7
#!/usr/bin/env bash
#
brew install gnu-sed
sudo gem pristine --all --no-extensions
gems=$(gem -v 2>&1 | grep called | gsed -r -e 's#^.*specifications/##' -e 's/-[0-9].*$//')
for gem in $gems
do
echo Fixing $gem...
sudo gem pristine $gem -- -build-arg
done
install a specific version of a gem
gem install rake --version=0.8.7
Thanks to the postings at:
http://stackoverflow.com/questions/5949521/how-do-i-fix-rubygems-recent-deprecation-warning