[DRE-maint] Bug#871718: ruby-pathname2 1.8.0-1 fails automatic ruby autopkgtests

Steve Langasek steve.langasek at canonical.com
Thu Aug 10 21:55:23 UTC 2017


Package: ruby-pathname2
Followup-For: Bug #871718
User: ubuntu-devel at lists.ubuntu.com
Usertags: origin-ubuntu artful ubuntu-patch

Hi again,

So I took another look at the source tree and noticed that
debian/pathname2.gemspec existed in parallel to the upstream one, and
contained a fix for this issue.  Moving this to be a patch against upstream
instead of a separate file under debian (which is invisible to
gem2deb-test-runner in the current implementation) is sufficient to fix this
test failure.

I have uploaded the attached patch to Ubuntu to fix this issue.

Thanks,
-- 
Steve Langasek                   Give me a lever long enough and a Free OS
Debian Developer                   to set it on, and I can move the world.
Ubuntu Developer                                    http://www.debian.org/
slangasek at ubuntu.com                                     vorlon at debian.org
-------------- next part --------------
diff -Nru ruby-pathname2-1.8.0/debian/files ruby-pathname2-1.8.0/debian/files
--- ruby-pathname2-1.8.0/debian/files	1969-12-31 16:00:00.000000000 -0800
+++ ruby-pathname2-1.8.0/debian/files	2017-08-10 14:51:45.000000000 -0700
@@ -0,0 +1 @@
+ruby-pathname2_1.8.0-1ubuntu1_source.buildinfo ruby optional
diff -Nru ruby-pathname2-1.8.0/debian/patches/gemspec-dep.patch ruby-pathname2-1.8.0/debian/patches/gemspec-dep.patch
--- ruby-pathname2-1.8.0/debian/patches/gemspec-dep.patch	1969-12-31 16:00:00.000000000 -0800
+++ ruby-pathname2-1.8.0/debian/patches/gemspec-dep.patch	2017-08-10 14:51:39.000000000 -0700
@@ -0,0 +1,17 @@
+Description: Fix missing dependency on rake
+ This was previously fixed in debian/pathname2.gemspec, but that didn't allow
+ gem2deb-test-runner to properly detect this in the source.  Patch the
+ upstream spec instead of creating duplicate files in the test tree, as this
+ should go upstream anyway.
+Author: Steve Langasek <steve.langasek at ubuntu.com>
+Bug-Debian: https://bugs.debian.org/871718
+Last-Update: 2017-08-10
+
+--- ruby-pathname2-1.8.0.orig/pathname2.gemspec
++++ ruby-pathname2-1.8.0/pathname2.gemspec
+@@ -1,4 +1,5 @@
+ require 'rubygems'
++require 'rake'
+ 
+ Gem::Specification.new do |spec|
+   spec.name        = 'pathname2'
diff -Nru ruby-pathname2-1.8.0/debian/patches/series ruby-pathname2-1.8.0/debian/patches/series
--- ruby-pathname2-1.8.0/debian/patches/series	2016-11-10 01:36:36.000000000 -0800
+++ ruby-pathname2-1.8.0/debian/patches/series	2017-08-10 14:49:06.000000000 -0700
@@ -1 +1,2 @@
 #fix-test
+gemspec-dep.patch
diff -Nru ruby-pathname2-1.8.0/debian/pathname2.gemspec ruby-pathname2-1.8.0/debian/pathname2.gemspec
--- ruby-pathname2-1.8.0/debian/pathname2.gemspec	2016-11-10 01:36:36.000000000 -0800
+++ ruby-pathname2-1.8.0/debian/pathname2.gemspec	1969-12-31 16:00:00.000000000 -0800
@@ -1,38 +0,0 @@
-require 'rubygems'
-require 'rake'
-
-Gem::Specification.new do |spec|
-  spec.name        = 'pathname2'
-  spec.version     = '1.8.0'
-  spec.author      = 'Daniel J. Berger'
-  spec.license     = 'Apache 2.0'
-  spec.email       = 'djberg96 at gmail.com'
-  spec.homepage    = 'https://github.com/djberg96/pathname2'
-  spec.summary     = 'An alternate implementation of the Pathname class'
-  spec.files       = Dir['**/*'].reject{ |f| f.include?('git') }
-  spec.cert_chain  = ['certs/djberg96_pub.pem']
-
-  spec.extra_rdoc_files  = ['README', 'CHANGES', 'MANIFEST']
-
-  spec.add_dependency('facade')
-  spec.add_development_dependency('test-unit')
-  spec.add_development_dependency('rake')
-
-  if File::ALT_SEPARATOR
-    spec.add_dependency('ffi')
-    spec.test_files = FileList['test/windows/*.rb', 'test/test_version.rb']
-    spec.platform = Gem::Platform.new(['universal', 'mingw32'])
-  else
-    spec.test_files = FileList['test/test_pathname.rb', 'test/test_version.rb']
-  end
-
-  spec.description = <<-EOF
-    The pathname2 library provides an implementation of the Pathname
-    class different from the one that ships as part of the Ruby standard
-    library. It is a subclass of String, though several methods have been
-    overridden to better fit a path context. In addition, it supports file
-    URL's as paths, provides additional methods for Windows paths, and
-    handles UNC paths on Windows properly. See the README file for more
-    details.
-  EOF
-end
diff -Nru ruby-pathname2-1.8.0/debian/rules ruby-pathname2-1.8.0/debian/rules
--- ruby-pathname2-1.8.0/debian/rules	2016-11-10 01:46:36.000000000 -0800
+++ ruby-pathname2-1.8.0/debian/rules	2017-08-10 14:43:41.000000000 -0700
@@ -9,7 +9,7 @@
 #export DH_RUBY_IGNORE_TESTS=ruby2.1 ruby2.2
 #
 # If you need to specify the .gemspec (eg there is more than one)
-export DH_RUBY_GEMSPEC=debian/pathname2.gemspec
+#export DH_RUBY_GEMSPEC=gem.gemspec
 #
 # Uncomment to check dependencies during build:
 # export GEM2DEB_TEST_RUNNER = --check-dependencies


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