[DRE-commits] [ruby-pg] 01/06: Generate gemspec from the source (Closes: #758601)

Cédric Boutillier boutil at moszumanska.debian.org
Thu Aug 21 11:04:52 UTC 2014


This is an automated email from the git hooks/post-receive script.

boutil pushed a commit to branch master
in repository ruby-pg.

commit 57ae1184fd0924204bd54692e4e55d60884cb7e5
Author: Cédric Boutillier <boutil at debian.org>
Date:   Thu Aug 21 12:10:34 2014 +0200

    Generate gemspec from the source (Closes: #758601)
    
      - remove obsolete gemspec file in debian/
      - use upstream Rakefile to generate the gemspecs
---
 debian/changelog       | 10 ++++++++++
 debian/pg-13.2.gemspec | 51 --------------------------------------------------
 debian/rules           |  6 +++++-
 3 files changed, 15 insertions(+), 52 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 5998b79..67d0bfa 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,13 @@
+ruby-pg (0.17.1-2) UNRELEASED; urgency=medium
+
+  * Team upload.
+  * Generate gemspec from the source instead of copying from an external
+    source (Closes: #758601)
+    - remove obsolete gemspec file in debian/
+    - use upstream Rakefile to generate the gemspecs
+
+ -- Cédric Boutillier <boutil at debian.org>  Thu, 21 Aug 2014 11:49:38 +0200
+
 ruby-pg (0.17.1-1) unstable; urgency=low
 
   * New upstream version.
diff --git a/debian/pg-13.2.gemspec b/debian/pg-13.2.gemspec
deleted file mode 100644
index 31cec91..0000000
--- a/debian/pg-13.2.gemspec
+++ /dev/null
@@ -1,51 +0,0 @@
-# -*- encoding: utf-8 -*-
-
-Gem::Specification.new do |s|
-  s.name = "pg"
-  s.version = "0.13.2"
-
-  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
-  s.authors = ["Michael Granger"]
-  s.cert_chain = ["-----BEGIN CERTIFICATE-----\nMIIDLDCCAhSgAwIBAgIBADANBgkqhkiG9w0BAQUFADA8MQwwCgYDVQQDDANnZWQx\nFzAVBgoJkiaJk/IsZAEZFgdfYWVyaWVfMRMwEQYKCZImiZPyLGQBGRYDb3JnMB4X\nDTEwMDkxNjE0NDg1MVoXDTExMDkxNjE0NDg1MVowPDEMMAoGA1UEAwwDZ2VkMRcw\nFQYKCZImiZPyLGQBGRYHX2FlcmllXzETMBEGCgmSJomT8ixkARkWA29yZzCCASIw\nDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBALy//BFxC1f/cPSnwtJBWoFiFrir\nh7RicI+joq/ocVXQqI4TDWPyF/8tqkvt+rD99X9qs2YeR8CU/YiIpLWrQOYST70J\nvDn7Uvhb2muFVqq6+vobeTkILBEO6pionWDG8jSbo3qKm1Rj [...]
-  s.date = "2012-02-22"
-  s.description = "Pg is the Ruby interface to the {PostgreSQL RDBMS}[http://www.postgresql.org/].\n\nIt works with {PostgreSQL 8.3 and later}[http://bit.ly/6AfPhm].\n\nA small example usage:\n\n  #!/usr/bin/env ruby\n  \n  require 'pg'\n  \n  # Output a table of current connections to the DB\n  conn = PG.connect( dbname: 'sales' )\n  conn.exec( \"SELECT * FROM pg_stat_activity\" ) do |result|\n    puts \"     PID | User             | Query\"\n\tresult.each do |row|\n      puts \" %7d |  [...]
-  s.email = ["ged at FaerieMUD.org"]
-  s.extensions = ["ext/extconf.rb"]
-  s.extra_rdoc_files = ["Manifest.txt", "Contributors.rdoc", "History.rdoc", "README-OS_X.rdoc", "README-Windows.rdoc", "README.ja.rdoc", "README.rdoc", "POSTGRES", "LICENSE", "ext/pg.c", "ext/pg_connection.c", "ext/pg_result.c"]
-  s.files = [".gemtest", "BSDL", "ChangeLog", "Contributors.rdoc", "History.rdoc", "LICENSE", "Manifest.txt", "POSTGRES", "README-OS_X.rdoc", "README-Windows.rdoc", "README.ja.rdoc", "README.rdoc", "Rakefile", "Rakefile.cross", "ext/extconf.rb", "ext/pg.c", "ext/pg.h", "ext/pg_connection.c", "ext/pg_result.c", "ext/vc/pg.sln", "ext/vc/pg_18/pg.vcproj", "ext/vc/pg_19/pg_19.vcproj", "lib/pg.rb", "lib/pg/connection.rb", "lib/pg/constants.rb", "lib/pg/exceptions.rb", "lib/pg/result.rb", "sam [...]
-  s.homepage = "https://bitbucket.org/ged/ruby-pg"
-  s.licenses = ["BSD", "Ruby", "GPL"]
-  s.rdoc_options = ["--main", "README.rdoc"]
-  s.require_paths = ["lib"]
-  s.required_ruby_version = Gem::Requirement.new(">= 1.8.7")
-  s.rubyforge_project = "pg"
-  s.rubygems_version = "1.8.23"
-  s.summary = "Pg is the Ruby interface to the {PostgreSQL RDBMS}[http://www.postgresql.org/]"
-
-  if s.respond_to? :specification_version then
-    s.specification_version = 3
-
-    if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
-      s.add_development_dependency(%q<hoe-mercurial>, ["~> 1.3.1"])
-      s.add_development_dependency(%q<hoe-highline>, ["~> 0.0.1"])
-      s.add_development_dependency(%q<rake-compiler>, ["~> 0.7"])
-      s.add_development_dependency(%q<rspec>, ["~> 2.6"])
-      s.add_development_dependency(%q<rdoc>, ["~> 3.10"])
-      s.add_development_dependency(%q<hoe>, ["~> 2.13"])
-    else
-      s.add_dependency(%q<hoe-mercurial>, ["~> 1.3.1"])
-      s.add_dependency(%q<hoe-highline>, ["~> 0.0.1"])
-      s.add_dependency(%q<rake-compiler>, ["~> 0.7"])
-      s.add_dependency(%q<rspec>, ["~> 2.6"])
-      s.add_dependency(%q<rdoc>, ["~> 3.10"])
-      s.add_dependency(%q<hoe>, ["~> 2.13"])
-    end
-  else
-    s.add_dependency(%q<hoe-mercurial>, ["~> 1.3.1"])
-    s.add_dependency(%q<hoe-highline>, ["~> 0.0.1"])
-    s.add_dependency(%q<rake-compiler>, ["~> 0.7"])
-    s.add_dependency(%q<rspec>, ["~> 2.6"])
-    s.add_dependency(%q<rdoc>, ["~> 3.10"])
-    s.add_dependency(%q<hoe>, ["~> 2.13"])
-  end
-end
diff --git a/debian/rules b/debian/rules
index 0ce1fdf..6f0a3d0 100755
--- a/debian/rules
+++ b/debian/rules
@@ -9,12 +9,15 @@
 #export DH_RUBY_IGNORE_TESTS=ruby1.8 ruby1.9.1 require-rubygems
 #
 # If you need to specify the .gemspec (eg there is more than one)
-export DH_RUBY_GEMSPEC=debian/pg-13.2.gemspec
+#export DH_RUBY_GEMSPEC=
 
+UPSTREAM_VERSION := $(shell dpkg-parsechangelog | grep "^Version:" | cut -d\  -f2 | cut -d- -f1)
 %:
 	dh $@ --buildsystem=ruby --with ruby
 
 override_dh_auto_build:
+	# generate the gemspec from Rakefile
+	rake debug_gem > pg-${UPSTREAM_VERSION}.gemspec
 	ruby ext/errorcodes.rb ext/errorcodes.txt ext/errorcodes.def
 	dh_auto_build
 
@@ -27,4 +30,5 @@ override_dh_installchangelogs:
 
 override_dh_clean:
 	rm -rf rdoc ext/errorcodes.def
+	rm -f pg-${UPSTREAM_VERSION}.gemspec
 	dh_clean

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/ruby-pg.git



More information about the Pkg-ruby-extras-commits mailing list