This is my first attempt at building RPM packages for Ruby GEMS. https://gist.github.com/1885411
Requirements:
yum install rpmdevtools
yum install ruby rubygems rubygem-gem2rpm
How to run:
$ ruby make_rpms.rb -t ~/tmp/rpm-gem-packaging/ -n mechanize -r 2.2.1
This will download the gem and dependencies and generate SRPM and RPM files in the following folder:
~/tmp/rpm-gem-packaging/rpmbuild/
NOTE: The status of SUCCESS and FAILURE can be seen in the file:
~/tmp/rpm-gem-packaging/rpmbuild/status.txt
Check for RPM and SRPM files which were generated:
$ cd ~/tmp/rpm-gem-packaging/
$ tree rpmbuild/{RPMS,SRPMS}