From ff04d2c4bd2ea388cc8a5febb23bec708a994b54 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Franti=C5=A1ek=20Dvo=C5=99=C3=A1k?= Date: Thu, 13 Mar 2014 14:43:45 +0100 Subject: [PATCH] Packaging of ruby-warden (= 1.2.3). --- ruby-warden/debian/changelog | 4 +- ruby-warden/debian/control | 19 ++++++--- ruby-warden/debian/copyright | 48 +++++++++++----------- .../debian/patches/explicit_require_rspec.patch | 15 +++++++ ruby-warden/debian/patches/series | 1 + ruby-warden/debian/ruby-tests.rake | 7 ++++ ruby-warden/debian/ruby-tests.rb | 13 ------ ruby-warden/debian/ruby-warden.docs | 3 +- ruby-warden/debian/rules | 3 ++ 9 files changed, 66 insertions(+), 47 deletions(-) create mode 100644 ruby-warden/debian/patches/explicit_require_rspec.patch create mode 100644 ruby-warden/debian/patches/series create mode 100644 ruby-warden/debian/ruby-tests.rake delete mode 100644 ruby-warden/debian/ruby-tests.rb diff --git a/ruby-warden/debian/changelog b/ruby-warden/debian/changelog index 8914155..8fc4515 100644 --- a/ruby-warden/debian/changelog +++ b/ruby-warden/debian/changelog @@ -1,5 +1,5 @@ -ruby-warden (1.2.3-1) UNRELEASED; urgency=medium +ruby-warden (1.2.3-1) unstable; urgency=low - * Initial release (Closes: #nnnn) + * Initial release -- František Dvořák Thu, 13 Mar 2014 14:30:29 +0100 diff --git a/ruby-warden/debian/control b/ruby-warden/debian/control index aa2375e..ec89ed5 100644 --- a/ruby-warden/debian/control +++ b/ruby-warden/debian/control @@ -3,9 +3,11 @@ Section: ruby Priority: optional Maintainer: Debian Ruby Extras Maintainers Uploaders: František Dvořák -Build-Depends: debhelper (>= 7.0.50~), gem2deb (>= 0.6.1~) -Standards-Version: 3.9.4 -#Vcs-Git: git://anonscm.debian.org/pkg-ruby-extras/ruby-warden.git +Build-Depends: debhelper (>= 7.0.50~), gem2deb (>= 0.6.1~), + ruby-rack (>= 1.0), rake, ruby-rspec +Standards-Version: 3.9.5 +# based on the package here: +Vcs-Git: git://git.debian.org/pkg-ruby-extras/ruby-warden.git #Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-ruby-extras/ruby-warden.git;a=summary Homepage: http://github.com/hassox/warden XS-Ruby-Versions: all @@ -13,7 +15,14 @@ XS-Ruby-Versions: all Package: ruby-warden Architecture: all XB-Ruby-Versions: ${ruby:Versions} -Depends: ${shlibs:Depends}, ${misc:Depends}, ruby | ruby-interpreter +Depends: ${shlibs:Depends}, ${misc:Depends}, ruby | ruby-interpreter, ruby-rack (>= 1.0) # rack (>= 1.0) Description: Rack middleware that provides authentication for rack applications - + Warden is a Rack-based middleware, designed to provide a mechanism for + authentication in Ruby web applications. It is a common mechanism that + fits into the Rack Machinery to offer powerful options for authentication. + . + Warden is designed to be lazy. That is, if you don't use it, it doesn't + do anything, but when you do use it, it will spring into action and + provide an underlying mechanism to allow authentication in any + Rack-based application. diff --git a/ruby-warden/debian/copyright b/ruby-warden/debian/copyright index 084ff98..45d2e24 100644 --- a/ruby-warden/debian/copyright +++ b/ruby-warden/debian/copyright @@ -1,35 +1,33 @@ Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: warden -Source: FIXME +Source: http://rubygems.org/gems/warden Files: * -Copyright: - -License: GPL-2+ (FIXME) +Copyright: 2009 Daniel Neighman +License: Expat Files: debian/* -Copyright: 2014 František Dvořák -License: GPL-2+ (FIXME) +Copyright: 2012 Praveen Arimbrathodiyil + 2014 František Dvořák +License: Expat 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 --git a/ruby-warden/debian/patches/explicit_require_rspec.patch b/ruby-warden/debian/patches/explicit_require_rspec.patch new file mode 100644 index 0000000..0623574 --- /dev/null +++ b/ruby-warden/debian/patches/explicit_require_rspec.patch @@ -0,0 +1,15 @@ +Description: Add explicit require rspec + This is needed for running tests with gem2deb +Forwarded: https://github.com/hassox/warden/pull/64 +Author: Praveen Arimbrathodiyil + +--- a/spec/spec_helper.rb ++++ b/spec/spec_helper.rb +@@ -7,6 +7,7 @@ + + require 'rubygems' + require 'rack' ++require 'rspec' + + Dir[File.join(File.dirname(__FILE__), "helpers", "**/*.rb")].each do |f| + require f diff --git a/ruby-warden/debian/patches/series b/ruby-warden/debian/patches/series new file mode 100644 index 0000000..a79c631 --- /dev/null +++ b/ruby-warden/debian/patches/series @@ -0,0 +1 @@ +explicit_require_rspec.patch diff --git a/ruby-warden/debian/ruby-tests.rake b/ruby-warden/debian/ruby-tests.rake new file mode 100644 index 0000000..89a753d --- /dev/null +++ b/ruby-warden/debian/ruby-tests.rake @@ -0,0 +1,7 @@ +require 'rspec/core/rake_task' + +RSpec::Core::RakeTask.new(:spec) do |spec| + spec.pattern = './spec/**/*_spec.rb' +end + +task :default => :spec diff --git a/ruby-warden/debian/ruby-tests.rb b/ruby-warden/debian/ruby-tests.rb deleted file mode 100644 index eac5ce6..0000000 --- a/ruby-warden/debian/ruby-tests.rb +++ /dev/null @@ -1,13 +0,0 @@ -# FIXME -# there's a spec/ or a test/ directory in the upstream source, but -# no test suite was defined in the Gem specification. It would be -# a good idea to define it here so the package gets tested at build time. -# Examples: -# $: << 'lib' << '.' -# Dir['{spec,test}/**/*.rb'].each { |f| require f } -# -# require 'test/ts_foo.rb' -# -# require 'rbconfig' -# ruby = File.join(RbConfig::CONFIG['bindir'], RbConfig::CONFIG['ruby_install_name']) -# exec("#{ruby} -I. test/runtests.rb") diff --git a/ruby-warden/debian/ruby-warden.docs b/ruby-warden/debian/ruby-warden.docs index 2c81977..5d86051 100644 --- a/ruby-warden/debian/ruby-warden.docs +++ b/ruby-warden/debian/ruby-warden.docs @@ -1,2 +1 @@ -# FIXME: READMEs found -# README.textile +README.textile diff --git a/ruby-warden/debian/rules b/ruby-warden/debian/rules index 82ddc0c..20caf70 100755 --- a/ruby-warden/debian/rules +++ b/ruby-warden/debian/rules @@ -13,3 +13,6 @@ %: dh $@ --buildsystem=ruby --with ruby + +override_dh_installchangelogs: + dh_installchangelogs History.rdoc -- 1.8.2.3