aboutsummaryrefslogtreecommitdiffstats
path: root/community/ruby-rake-compiler
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2017-12-26 01:30:05 +0100
committerJakub Jirutka <jakub@jirutka.cz>2017-12-26 01:30:05 +0100
commitcb6b327147d747c711cdfd000313d2ebbc64ea25 (patch)
treed3f006e78d02aec4955f8de94fbd6a663ee8ab49 /community/ruby-rake-compiler
parentf45c2cffc7d8bad71c9a4134e9a22329a2248fc5 (diff)
downloadaports-cb6b327147d747c711cdfd000313d2ebbc64ea25.tar.bz2
aports-cb6b327147d747c711cdfd000313d2ebbc64ea25.tar.xz
community/ruby-rake-compiler: move from testing
Diffstat (limited to 'community/ruby-rake-compiler')
-rw-r--r--community/ruby-rake-compiler/0001-extract-gemspec.patch129
-rw-r--r--community/ruby-rake-compiler/APKBUILD48
-rw-r--r--community/ruby-rake-compiler/gemfile-remove-unwanted-files.patch26
3 files changed, 203 insertions, 0 deletions
diff --git a/community/ruby-rake-compiler/0001-extract-gemspec.patch b/community/ruby-rake-compiler/0001-extract-gemspec.patch
new file mode 100644
index 0000000000..8c56150ae3
--- /dev/null
+++ b/community/ruby-rake-compiler/0001-extract-gemspec.patch
@@ -0,0 +1,129 @@
+From 9f15620e7db145d11ae2fc4ba032367903f625e3 Mon Sep 17 00:00:00 2001
+From: Kouhei Sutou <kou@clear-code.com>
+Date: Sun, 20 Aug 2017 14:47:44 +0900
+Subject: [PATCH] Extract gemspec
+
+Patch-Source: https://github.com/rake-compiler/rake-compiler/commit/9f15620e7db145d11ae2fc4ba032367903f625e3
+---
+ rake-compiler.gemspec | 52 +++++++++++++++++++++++++++++++++++++++++++++++++++
+ tasks/gem.rake | 49 +++---------------------------------------------
+ 2 files changed, 55 insertions(+), 46 deletions(-)
+ create mode 100644 rake-compiler.gemspec
+
+diff --git a/rake-compiler.gemspec b/rake-compiler.gemspec
+new file mode 100644
+index 0000000..feb2299
+--- /dev/null
++++ b/rake-compiler.gemspec
+@@ -0,0 +1,52 @@
++# -*- ruby -*-
++
++Gem::Specification.new do |s|
++ # basic information
++ s.name = "rake-compiler"
++ s.version = "1.0.5"
++ s.platform = Gem::Platform::RUBY
++
++ # description and details
++ s.summary = 'Rake-based Ruby Extension (C, Java) task generator.'
++ s.description = "Provide a standard and simplified way to build and package\nRuby extensions (C, Java) using Rake as glue."
++
++ # requirements
++ s.required_ruby_version = ">= 1.8.7"
++ s.required_rubygems_version = ">= 1.8.23"
++
++ # dependencies
++ s.add_dependency 'rake'
++
++ # development dependencies
++ s.add_development_dependency 'rspec', '~> 2.8.0'
++ s.add_development_dependency 'cucumber', '~> 1.1.4'
++
++ # components, files and paths
++ s.files = Dir.glob("features/**/*.{feature,rb}")
++ s.files += ["bin/rake-compiler"]
++ s.files += Dir.glob("lib/**/*.rb")
++ s.files += ["spec/spec.opts"]
++ s.files += Dir.glob("spec/**/*.rb")
++ s.files += Dir.glob("tasks/**/*.rake")
++ s.files += ["Rakefile", "Gemfile"]
++ s.files += Dir.glob("*.{rdoc,txt,yml}")
++
++ s.bindir = 'bin'
++ s.executables = ['rake-compiler']
++
++ s.require_path = 'lib'
++
++ # documentation
++ s.rdoc_options << '--main' << 'README.rdoc' << '--title' << 'rake-compiler -- Documentation'
++
++ s.extra_rdoc_files = %w(README.rdoc LICENSE.txt History.txt)
++
++ # project information
++ s.homepage = 'https://github.com/rake-compiler/rake-compiler'
++ s.rubyforge_project = 'rake-compiler'
++ s.licenses = ['MIT']
++
++ # author and contributors
++ s.authors = ['Kouhei Sutou', 'Luis Lavena']
++ s.email = ['kou@cozmixng.org', 'luislavena@gmail.com']
++end
+diff --git a/tasks/gem.rake b/tasks/gem.rake
+index 39924b8..7cc6df0 100644
+--- a/tasks/gem.rake
++++ b/tasks/gem.rake
+@@ -1,51 +1,8 @@
+ require 'rubygems/package_task'
+
+-GEM_SPEC = Gem::Specification.new do |s|
+- # basic information
+- s.name = "rake-compiler"
+- s.version = "1.0.4"
+- s.platform = Gem::Platform::RUBY
+-
+- # description and details
+- s.summary = 'Rake-based Ruby Extension (C, Java) task generator.'
+- s.description = "Provide a standard and simplified way to build and package\nRuby extensions (C, Java) using Rake as glue."
+-
+- # requirements
+- s.required_ruby_version = ">= 1.8.7"
+- s.required_rubygems_version = ">= 1.8.23"
+-
+- # dependencies
+- s.add_dependency 'rake'
+-
+- # development dependencies
+- s.add_development_dependency 'rspec', '~> 2.8.0'
+- s.add_development_dependency 'cucumber', '~> 1.1.4'
+-
+- # components, files and paths
+- s.files = FileList["features/**/*.{feature,rb}", "bin/rake-compiler",
+- "lib/**/*.rb", "spec/spec.opts", "spec/**/*.rb",
+- "tasks/**/*.rake", "Rakefile", "Gemfile",
+- "*.{rdoc,txt,yml}"]
+-
+- s.bindir = 'bin'
+- s.executables = ['rake-compiler']
+-
+- s.require_path = 'lib'
+-
+- # documentation
+- s.rdoc_options << '--main' << 'README.rdoc' << '--title' << 'rake-compiler -- Documentation'
+-
+- s.extra_rdoc_files = %w(README.rdoc LICENSE.txt History.txt)
+-
+- # project information
+- s.homepage = 'https://github.com/rake-compiler/rake-compiler'
+- s.rubyforge_project = 'rake-compiler'
+- s.licenses = ['MIT']
+-
+- # author and contributors
+- s.authors = ['Kouhei Sutou', 'Luis Lavena']
+- s.email = ['kou@cozmixng.org', 'luislavena@gmail.com']
+-end
++gemspec_path = File.join(__dir__, "..", "rake-compiler.gemspec")
++gemspec_path = File.expand_path(gemspec_path)
++GEM_SPEC = eval(File.read(gemspec_path), TOPLEVEL_BINDING, gemspec_path)
+
+ gem_package = Gem::PackageTask.new(GEM_SPEC) do |pkg|
+ pkg.need_tar = false
diff --git a/community/ruby-rake-compiler/APKBUILD b/community/ruby-rake-compiler/APKBUILD
new file mode 100644
index 0000000000..26f69b3af2
--- /dev/null
+++ b/community/ruby-rake-compiler/APKBUILD
@@ -0,0 +1,48 @@
+# Contributor: Jakub Jirutka <jakub@jirutka.cz>
+# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
+pkgname=ruby-rake-compiler
+_gemname=${pkgname#ruby-}
+pkgver=1.0.4
+pkgrel=1
+pkgdesc="Provide a standard and simplified way to build and package Ruby extensions"
+url="https://github.com/rake-compiler/rake-compiler"
+arch="noarch"
+license="MIT"
+depends="ruby ruby-rake"
+checkdepends="ruby-rspec"
+source="$pkgname-$pkgver.tar.gz::https://github.com/rake-compiler/$_gemname/archive/v$pkgver.tar.gz
+ 0001-extract-gemspec.patch
+ gemfile-remove-unwanted-files.patch"
+builddir="$srcdir/$_gemname-$pkgver"
+
+build() {
+ cd "$builddir"
+ gem build $_gemname.gemspec
+}
+
+check() {
+ cd "$builddir"
+ rspec spec
+}
+
+package() {
+ local gemdir="$pkgdir/$(ruby -rubygems -e 'puts Gem.default_dir')"
+
+ cd "$builddir"
+
+ gem install --local \
+ --install-dir "$gemdir" \
+ --bindir "$pkgdir/usr/bin" \
+ --ignore-dependencies \
+ --no-document \
+ --verbose \
+ $_gemname
+
+ # Remove unnecessary files and empty directories.
+ cd "$gemdir"
+ rm -r cache build_info doc
+}
+
+sha512sums="fc015d8f6dcc2ba380dbc3eb2959b068f3582e0efcdc765570f5b2c97737db2ba38fb324b9b5bb63d3af822843139561a36758408db637e7716afb3a6074251c ruby-rake-compiler-1.0.4.tar.gz
+ea218d90f5651bdf46a96eaca2bc34f27ace9ff22752f5ce6ad9bb0d8bede110b212f797f1accd1fa3bd76ee093003269d8fcfc1490124bfa54785e92443a1dc 0001-extract-gemspec.patch
+e68672541d62898bc72fb7e40f16bc75ed1d46eabedd18da60a6f0673d67bf63d990e191fb41d6034e3f6361662807030cbd8f0c817223a5d03c46a3a664f855 gemfile-remove-unwanted-files.patch"
diff --git a/community/ruby-rake-compiler/gemfile-remove-unwanted-files.patch b/community/ruby-rake-compiler/gemfile-remove-unwanted-files.patch
new file mode 100644
index 0000000000..3424cd912b
--- /dev/null
+++ b/community/ruby-rake-compiler/gemfile-remove-unwanted-files.patch
@@ -0,0 +1,26 @@
+--- a/rake-compiler.gemspec
++++ b/rake-compiler.gemspec
+@@ -22,14 +22,8 @@
+ s.add_development_dependency 'cucumber', '~> 1.1.4'
+
+ # components, files and paths
+- s.files = Dir.glob("features/**/*.{feature,rb}")
+ s.files += ["bin/rake-compiler"]
+ s.files += Dir.glob("lib/**/*.rb")
+- s.files += ["spec/spec.opts"]
+- s.files += Dir.glob("spec/**/*.rb")
+- s.files += Dir.glob("tasks/**/*.rake")
+- s.files += ["Rakefile", "Gemfile"]
+- s.files += Dir.glob("*.{rdoc,txt,yml}")
+
+ s.bindir = 'bin'
+ s.executables = ['rake-compiler']
+@@ -38,8 +32,6 @@
+
+ # documentation
+ s.rdoc_options << '--main' << 'README.rdoc' << '--title' << 'rake-compiler -- Documentation'
+-
+- s.extra_rdoc_files = %w(README.rdoc LICENSE.txt History.txt)
+
+ # project information
+ s.homepage = 'https://github.com/rake-compiler/rake-compiler'