diff options
author | Diego Elio Pettenò <flameeyes@gentoo.org> | 2010-02-12 21:25:02 +0000 |
---|---|---|
committer | Diego Elio Pettenò <flameeyes@gentoo.org> | 2010-02-12 21:25:02 +0000 |
commit | bd1dfe0e33085c6033aca4d6dda9a21dfa78ee63 (patch) | |
tree | 89ddb4862b5617adde11b6ff60cfd4db0ecf1676 /dev-ruby/amazon-ec2 | |
parent | Dropping pango USE flag, bug 301577 (diff) | |
download | gentoo-2-bd1dfe0e33085c6033aca4d6dda9a21dfa78ee63.tar.gz gentoo-2-bd1dfe0e33085c6033aca4d6dda9a21dfa78ee63.tar.bz2 gentoo-2-bd1dfe0e33085c6033aca4d6dda9a21dfa78ee63.zip |
Initial import of amazon-ec2 gem. Pushed the fixes upstream.
(Portage version: 2.2_rc62/cvs/Linux x86_64)
Diffstat (limited to 'dev-ruby/amazon-ec2')
-rw-r--r-- | dev-ruby/amazon-ec2/ChangeLog | 11 | ||||
-rw-r--r-- | dev-ruby/amazon-ec2/amazon-ec2-0.9.3.ebuild | 50 | ||||
-rw-r--r-- | dev-ruby/amazon-ec2/files/amazon-ec2-0.9.3-fixes.patch | 75 | ||||
-rw-r--r-- | dev-ruby/amazon-ec2/metadata.xml | 5 |
4 files changed, 141 insertions, 0 deletions
diff --git a/dev-ruby/amazon-ec2/ChangeLog b/dev-ruby/amazon-ec2/ChangeLog new file mode 100644 index 000000000000..d004e31a955a --- /dev/null +++ b/dev-ruby/amazon-ec2/ChangeLog @@ -0,0 +1,11 @@ +# ChangeLog for dev-ruby/amazon-ec2 +# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/dev-ruby/amazon-ec2/ChangeLog,v 1.1 2010/02/12 21:25:02 flameeyes Exp $ + +*amazon-ec2-0.9.3 (12 Feb 2010) + + 12 Feb 2010; Diego E. Pettenò <flameeyes@gentoo.org> + +amazon-ec2-0.9.3.ebuild, +files/amazon-ec2-0.9.3-fixes.patch, + +metadata.xml: + Initial import of amazon-ec2 gem. Pushed the fixes upstream. + diff --git a/dev-ruby/amazon-ec2/amazon-ec2-0.9.3.ebuild b/dev-ruby/amazon-ec2/amazon-ec2-0.9.3.ebuild new file mode 100644 index 000000000000..9282ec027351 --- /dev/null +++ b/dev-ruby/amazon-ec2/amazon-ec2-0.9.3.ebuild @@ -0,0 +1,50 @@ +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-ruby/amazon-ec2/amazon-ec2-0.9.3.ebuild,v 1.1 2010/02/12 21:25:02 flameeyes Exp $ + +EAPI=2 + +USE_RUBY="ruby18 jruby" + +# dev-ruby/yard can be used instead of rdoc, but since the output only +# differs in style and adds one further dependency, we'll just go with +# rdoc for now. +# +# In case, the configuration would be +# RUBY_FAKEGEM_TASK_DOC="yard" +# RUBY_FAKEGEM_DOCDIR="doc" + +RUBY_FAKEGEM_TASK_DOC="rdoc" +RUBY_FAKEGEM_DOCDIR="rdoc" +RUBY_FAKEGEM_EXTRADOC="README.rdoc README_dev.rdoc ChangeLog" + +RUBY_FAKEGEM_BINWRAP="ec2sh" + +inherit ruby-fakegem eutils + +DESCRIPTION="Library for accessing the Amazon Web Services EC2 and related" +HOMEPAGE="http://github.com/grempe/amazon-ec2" + +LICENSE="Ruby" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="" + +ruby_add_bdepend test "virtual/ruby-test-unit dev-ruby/test-spec dev-ruby/mocha" +ruby_add_rdepend '>=dev-ruby/xml-simple-1.0.12' + +all_ruby_prepare() { + epatch "${FILESDIR}"/${P}-fixes.patch +} + +each_ruby_prepare() { + case ${RUBY} in + *ruby19) + ;; + *) + # Remove the reference to test-unit gem, since it's only + # available on Ruby 1.9. + sed -i -e '/^gem/s:^:#:' test/test_helper.rb || die + ;; + esac +} diff --git a/dev-ruby/amazon-ec2/files/amazon-ec2-0.9.3-fixes.patch b/dev-ruby/amazon-ec2/files/amazon-ec2-0.9.3-fixes.patch new file mode 100644 index 000000000000..95317befa212 --- /dev/null +++ b/dev-ruby/amazon-ec2/files/amazon-ec2-0.9.3-fixes.patch @@ -0,0 +1,75 @@ +diff --git a/Rakefile b/Rakefile +index 2fe03f9..cc608cb 100644 +--- a/Rakefile ++++ b/Rakefile +@@ -1,22 +1,25 @@ + require 'rubygems' + require 'rake' +-require 'yard' + +-require 'jeweler' +-Jeweler::Tasks.new do |gem| +- gem.name = "amazon-ec2" +- gem.summary = %Q{Amazon EC2 Ruby Gem} +- gem.description = %Q{A Ruby library for accessing the Amazon Web Services EC2, ELB, RDS, Cloudwatch, and Autoscaling API's.} +- gem.email = "glenn@rempe.us" +- gem.homepage = "http://github.com/grempe/amazon-ec2" +- gem.authors = ["Glenn Rempe"] +- gem.rdoc_options = ["--title", "amazon-ec2 documentation", "--line-numbers", "--main", "README.rdoc"] +- gem.rubyforge_project = 'amazon-ec2' +- gem.add_dependency('xml-simple', '>= 1.0.12') +- gem.add_development_dependency('mocha', '>= 0.9.8') +- gem.add_development_dependency('test-spec', '>= 0.10.0') +- gem.add_development_dependency('rcov', '>= 0.9.6') +- gem.add_development_dependency('perftools.rb', '>= 0.3.9') ++begin ++ require 'jeweler' ++ Jeweler::Tasks.new do |gem| ++ gem.name = "amazon-ec2" ++ gem.summary = %Q{Amazon EC2 Ruby Gem} ++ gem.description = %Q{A Ruby library for accessing the Amazon Web Services EC2, ELB, RDS, Cloudwatch, and Autoscaling APIs.} ++ gem.email = "glenn@rempe.us" ++ gem.homepage = "http://github.com/grempe/amazon-ec2" ++ gem.authors = ["Glenn Rempe"] ++ gem.rdoc_options = ["--title", "amazon-ec2 documentation", "--line-numbers", "--main", "README.rdoc"] ++ gem.rubyforge_project = 'amazon-ec2' ++ gem.add_dependency('xml-simple', '>= 1.0.12') ++ gem.add_development_dependency('mocha', '>= 0.9.8') ++ gem.add_development_dependency('test-spec', '>= 0.10.0') ++ gem.add_development_dependency('rcov', '>= 0.9.6') ++ gem.add_development_dependency('perftools.rb', '>= 0.3.9') ++ end ++rescue LoadError ++ puts "Jeweler (or a dependency) not available. Install it with: [sudo] gem install jeweler" + end + + require 'rake/testtask' +@@ -57,8 +60,13 @@ Rake::RDocTask.new do |rdoc| + rdoc.rdoc_files.include('lib/**/*.rb') + end + +-YARD::Rake::YardocTask.new do |t| +- #t.files = ['lib/**/*.rb'] ++begin ++ require 'yard' ++ YARD::Rake::YardocTask.new do |t| ++ #t.files = ['lib/**/*.rb'] ++ end ++rescue LoadError ++ puts "YARD (or a dependency) not available. Install it with: [sudo] gem install yard" + end + + desc "Generate a perftools.rb profile" +diff --git a/lib/AWS/EC2.rb b/lib/AWS/EC2.rb +index f8626fa..40895a9 100644 +--- a/lib/AWS/EC2.rb ++++ b/lib/AWS/EC2.rb +@@ -9,7 +9,7 @@ module AWS + if ENV['EC2_URL'] + EC2_URL = ENV['EC2_URL'] + VALID_HOSTS = ['https://ec2.amazonaws.com', 'https://us-east-1.ec2.amazonaws.com', 'https://us-west-1.ec2.amazonaws.com', 'https://eu-west-1.ec2.amazonaws.com'] +- raise ArgumentError, "Invalid EC2_URL environment variable : #{EC2_URL}" unless VALID_HOSTS.include?(EC2_URL) ++ raise ArgumentError, "Invalid EC2_URL environment variable : #{EC2_URL}" unless VALID_HOSTS.include?(EC2_URL.chomp('/')) + DEFAULT_HOST = URI.parse(EC2_URL).host + else + # Default US API endpoint diff --git a/dev-ruby/amazon-ec2/metadata.xml b/dev-ruby/amazon-ec2/metadata.xml new file mode 100644 index 000000000000..852136183369 --- /dev/null +++ b/dev-ruby/amazon-ec2/metadata.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<herd>ruby</herd> +</pkgmetadata> |