diff -Nru gem2deb-0.33.1/debian/changelog gem2deb-0.34/debian/changelog --- gem2deb-0.33.1/debian/changelog 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/debian/changelog 2017-07-01 14:30:17.000000000 +0000 @@ -1,3 +1,22 @@ +gem2deb (0.34) unstable; urgency=medium + + [ Dominic Cleal ] + * dh-make-ruby: support concurrent dh-make-ruby processes without one of + them botching "gem to package" mapping cache (Closes: #862409) + + [ Balasankar C ] + * Change template copyright to Expat (Closes: #786521) + + [ Antonio Terceiro ] + * Fix most Ruby warning in the code. They were exposed by rake 12.0.0, which + runs tests with warnings enabled by default. + * dh-make-ruby: + - Bump Standards-Version in produced packages to 4.0.0 + * debian/control: + - Bump Standards-Version to 4.0.0; no changes needed + + -- Antonio Terceiro Sat, 01 Jul 2017 11:30:17 -0300 + gem2deb (0.33.1) unstable; urgency=medium * Gem2Deb::GemInstaller: diff -Nru gem2deb-0.33.1/debian/control gem2deb-0.34/debian/control --- gem2deb-0.33.1/debian/control 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/debian/control 2017-07-01 14:30:17.000000000 +0000 @@ -22,7 +22,7 @@ ruby-setup , ruby-shoulda-context , ruby-test-unit -Standards-Version: 3.9.8 +Standards-Version: 4.0.0 Vcs-Git: https://anonscm.debian.org/git/pkg-ruby-extras/gem2deb.git Vcs-Browser: https://anonscm.debian.org/cgit/pkg-ruby-extras/gem2deb.git Testsuite: autopkgtest diff -Nru gem2deb-0.33.1/lib/gem2deb/dh_make_ruby/template/debian/control gem2deb-0.34/lib/gem2deb/dh_make_ruby/template/debian/control --- gem2deb-0.33.1/lib/gem2deb/dh_make_ruby/template/debian/control 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/lib/gem2deb/dh_make_ruby/template/debian/control 2017-07-01 14:30:17.000000000 +0000 @@ -5,7 +5,7 @@ Uploaders: <%= maintainer['DEBFULLNAME'] %> <<%= maintainer['DEBEMAIL'] %>> Build-Depends: debhelper (>= 9~), gem2deb, <%= (extra_build_dependencies + binary_package.dependencies).map { |d| ", #{d}" }.join %> -Standards-Version: 3.9.8 +Standards-Version: 4.0.0 Vcs-Git: https://anonscm.debian.org/git/pkg-ruby-extras/<%= source_package_name %>.git Vcs-Browser: https://anonscm.debian.org/cgit/pkg-ruby-extras/<%= source_package_name %>.git Homepage: <%= homepage ? homepage : 'FIXME'%> diff -Nru gem2deb-0.33.1/lib/gem2deb/dh_make_ruby/template/debian/copyright gem2deb-0.34/lib/gem2deb/dh_make_ruby/template/debian/copyright --- gem2deb-0.33.1/lib/gem2deb/dh_make_ruby/template/debian/copyright 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/lib/gem2deb/dh_make_ruby/template/debian/copyright 2017-07-01 14:30:17.000000000 +0000 @@ -5,31 +5,28 @@ Files: * Copyright: -License: GPL-2+ (FIXME) +License: Expat (FIXME) Files: debian/* Copyright: <%= Date.today.year %> <%= maintainer['DEBFULLNAME'] %> <<%= maintainer['DEBEMAIL'] %>> -License: GPL-2+ (FIXME) +License: Expat (FIXME) Comment: the Debian packaging is licensed under the same terms as the original package. -License: GPL-2+ (FIXME) - This program is free software; you can redistribute it - and/or modify it under the terms of the GNU General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later - version. +License: Expat + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: . - This program is distributed in the hope that it will be - useful, but WITHOUT ANY WARRANTY; without even the implied - warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR - PURPOSE. See the GNU General Public License for more - details. + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. . - You should have received a copy of the GNU General Public - License along with this package; if not, write to the Free - Software Foundation, Inc., 51 Franklin St, Fifth Floor, - Boston, MA 02110-1301 USA - . - On Debian systems, the full text of the GNU General Public - License version 2 can be found in the file - `/usr/share/common-licenses/GPL-2'. + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. diff -Nru gem2deb-0.33.1/lib/gem2deb/dh_make_ruby.rb gem2deb-0.34/lib/gem2deb/dh_make_ruby.rb --- gem2deb-0.33.1/lib/gem2deb/dh_make_ruby.rb 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/lib/gem2deb/dh_make_ruby.rb 2017-07-01 14:30:17.000000000 +0000 @@ -144,11 +144,11 @@ end if update - new_cache = cache + '.new' + new_cache = cache + ".new.#{$$}" if system('apt-file search /usr/share/rubygems-integration/ > ' + new_cache) if File.stat(new_cache).size > 0 system('sed', '-i', '-e', 's#/.*/##; s/-[0-9.]\+.gemspec//', new_cache) - FileUtils.mv(cache + '.new', cache) + FileUtils.mv(new_cache, cache) else puts 'E: dh-make-ruby needs an up-to-date apt-file cache in order to map gem names' puts 'E: to package names but apt-file has an invalid cache. Please run ' diff -Nru gem2deb-0.33.1/lib/gem2deb/metadata.rb gem2deb-0.34/lib/gem2deb/metadata.rb --- gem2deb-0.33.1/lib/gem2deb/metadata.rb 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/lib/gem2deb/metadata.rb 2017-07-01 14:30:17.000000000 +0000 @@ -27,6 +27,7 @@ attr_reader :root def initialize(root) + @gemspec = nil @source_dir = File.expand_path(root) @root = root Dir.chdir(source_dir) do diff -Nru gem2deb-0.33.1/lib/gem2deb/version.rb gem2deb-0.34/lib/gem2deb/version.rb --- gem2deb-0.33.1/lib/gem2deb/version.rb 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/lib/gem2deb/version.rb 2017-07-01 14:30:17.000000000 +0000 @@ -1,3 +1,3 @@ module Gem2Deb - VERSION = '0.33.1' + VERSION = '0.34' end diff -Nru gem2deb-0.33.1/test/integration/gem2deb_test.rb gem2deb-0.34/test/integration/gem2deb_test.rb --- gem2deb-0.33.1/test/integration/gem2deb_test.rb 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/test/integration/gem2deb_test.rb 2017-07-01 14:30:17.000000000 +0000 @@ -24,7 +24,7 @@ should 'generate a non-lintian-clean copyright file' do changes_file = File.join(self.class.tmpdir, "ruby-simplegem_*.changes") - assert_match /E: ruby-simplegem: helper-templates-in-copyright/, `lintian #{changes_file}` + assert_match %r/E: ruby-simplegem: helper-templates-in-copyright/, `lintian #{changes_file}` end should 'install executables for altbindir' do diff -Nru gem2deb-0.33.1/test/test_helper.rb gem2deb-0.34/test/test_helper.rb --- gem2deb-0.33.1/test/test_helper.rb 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/test/test_helper.rb 2017-07-01 14:30:17.000000000 +0000 @@ -14,8 +14,10 @@ Gem2Deb.verbose = false Gem2Deb.testing = true -Gem2DebTestCase = Test::Unit::TestCase -class Gem2DebTestCase +$__gem2deb_tests_cleanup_installed = false +$environment_setup = false + +class Gem2DebTestCase < Test::Unit::TestCase SUPPORTED_VERSION_NUMBERS = Gem2Deb::RUBY_CONFIG_VERSION.values.sort SUPPORTED_API_NUMBERS = Gem2Deb::RUBY_API_VERSION.values.sort @@ -49,7 +51,7 @@ one_time_setup_blocks << block end def one_time_setup? - @one_time_setup + @one_time_setup ||= nil end def one_time_setup! unless one_time_setup? @@ -157,7 +159,7 @@ # make sure that everything that comes from gem2deb has precedence over # system-wide installed versions. def self.run_command(cmd) - if !@environment_setup && !ENV['ADTTMP'] + if !$environment_setup && !ENV['ADTTMP'] # setup Perl lib for debhelper7 perl5lib = File.join(GEM2DEB_ROOT_SOURCE_DIR, 'debhelper7') @@ -166,7 +168,7 @@ ENV['PATH'] = [File.join(GEM2DEB_ROOT_SOURCE_DIR, 'bin'), File.join(GEM2DEB_ROOT_SOURCE_DIR, 'test', 'bin'), ENV['PATH']].join(':') ENV['RUBYLIB'] = File.join(GEM2DEB_ROOT_SOURCE_DIR, 'lib') - @environment_setup = true + $environment_setup = true end @run_command_id ||= -1 diff -Nru gem2deb-0.33.1/test/unit/dh_make_ruby_test.rb gem2deb-0.34/test/unit/dh_make_ruby_test.rb --- gem2deb-0.33.1/test/unit/dh_make_ruby_test.rb 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/test/unit/dh_make_ruby_test.rb 2017-07-01 14:30:17.000000000 +0000 @@ -130,10 +130,10 @@ assert_equal 'Fancy_Package', $__fancy_package_dh_make_ruby.gem_name end should 'use actual upstream name in debian/watch' do - assert_match /gemwatch\/Fancy_Package/, File.read(File.join(tmpdir, 'ruby-fancy-package-0.0.1/debian/watch')) + assert_match %r/gemwatch\/Fancy_Package/, File.read(File.join(tmpdir, 'ruby-fancy-package-0.0.1/debian/watch')) end should 'use actual upstream name in debian/copyright' do - assert_match /Upstream-Name: Fancy_Package/, File.read(File.join(tmpdir, 'ruby-fancy-package-0.0.1/debian/copyright')) + assert_match %r/Upstream-Name: Fancy_Package/, File.read(File.join(tmpdir, 'ruby-fancy-package-0.0.1/debian/copyright')) end end diff -Nru gem2deb-0.33.1/test/unit/dh_ruby_test.rb gem2deb-0.34/test/unit/dh_ruby_test.rb --- gem2deb-0.33.1/test/unit/dh_ruby_test.rb 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/test/unit/dh_ruby_test.rb 2017-07-01 14:30:17.000000000 +0000 @@ -39,7 +39,7 @@ end should "link #{target_so} against libruby#{version_number}" do installed_so = installed_file_path(SIMPLE_EXTENSION_DIRNAME, "ruby-simpleextension", target_so) - assert_match /libruby-?#{version_number}/, `ldd #{installed_so}` + assert_match %r/libruby-?#{version_number}/, `ldd #{installed_so}` end end end @@ -150,7 +150,7 @@ @dh_ruby = Gem2Deb::DhRuby.new end should 'be debian/${binary_package} by default' do - assert_match /debian\/ruby-foo$/, @dh_ruby.send(:destdir_for, 'ruby-foo', 'debian/tmp') + assert_match %r/debian\/ruby-foo$/, @dh_ruby.send(:destdir_for, 'ruby-foo', 'debian/tmp') end should 'install to debian/tmp when DH_RUBY_USE_DH_AUTO_INSTALL_DESTDIR is set' do saved_env = ENV['DH_RUBY_USE_DH_AUTO_INSTALL_DESTDIR'] diff -Nru gem2deb-0.33.1/test/unit/installer_test.rb gem2deb-0.34/test/unit/installer_test.rb --- gem2deb-0.33.1/test/unit/installer_test.rb 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/test/unit/installer_test.rb 2017-07-01 14:30:17.000000000 +0000 @@ -93,7 +93,7 @@ should 'add a shebang when there is none' do lines = File.readlines(self.class.tmpdir + '/rewrite_shebangs/usr/bin/no-shebang') assert_match %r{/usr/bin/ruby}, lines[0] - assert_match /puts/, lines[1] + assert_match %r/puts/, lines[1] end should 'not rewrite shebangs non-Ruby scripts' do lines = File.readlines(self.class.tmpdir + '/rewrite_shebangs/usr/bin/shell-script') diff -Nru gem2deb-0.33.1/test/unit/setup_rb_installer_test.rb gem2deb-0.34/test/unit/setup_rb_installer_test.rb --- gem2deb-0.33.1/test/unit/setup_rb_installer_test.rb 2016-12-07 16:47:07.000000000 +0000 +++ gem2deb-0.34/test/unit/setup_rb_installer_test.rb 2017-07-01 14:30:17.000000000 +0000 @@ -23,7 +23,7 @@ end should "link #{target_so} against libruby#{version_number} for #{package}" do installed_so = installed_file_path(dirname, package, target_so) - assert_match /libruby-?#{version_number}/, `ldd #{installed_so}` + assert_match %r/libruby-?#{version_number}/, `ldd #{installed_so}` end end end