From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 5AEBB1381F3 for ; Fri, 18 Oct 2013 16:34:07 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id D3F4CE0ABF; Fri, 18 Oct 2013 16:33:38 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 6A022E0ABF for ; Fri, 18 Oct 2013 16:33:38 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 414B533BE94 for ; Fri, 18 Oct 2013 16:33:37 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id E6017E5308 for ; Fri, 18 Oct 2013 16:33:35 +0000 (UTC) From: "Michel Boaventura" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michel Boaventura" Message-ID: <1382114013.803c749c146aec82d35988139f17ed7d8edf9011.michelboaventura@gentoo> Subject: [gentoo-commits] proj/ruby-overlay:master commit in: dev-ruby/rake/files/, dev-ruby/rake/ X-VCS-Repository: proj/ruby-overlay X-VCS-Files: dev-ruby/rake/ChangeLog dev-ruby/rake/files/rake-10.1.0-ruby-1.8-fix.patch dev-ruby/rake/files/rake.bash-completion dev-ruby/rake/metadata.xml dev-ruby/rake/rake-10.1.0.ebuild X-VCS-Directories: dev-ruby/rake/files/ dev-ruby/rake/ X-VCS-Committer: michelboaventura X-VCS-Committer-Name: Michel Boaventura X-VCS-Revision: 803c749c146aec82d35988139f17ed7d8edf9011 X-VCS-Branch: master Date: Fri, 18 Oct 2013 16:33:35 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 99b34b0f-571f-427d-acfd-b3ca8ea733ee X-Archives-Hash: 20829586440242c1ed7f898357ea06a0 commit: 803c749c146aec82d35988139f17ed7d8edf9011 Author: Michel Boaventura michelboaventura com> AuthorDate: Fri Oct 18 16:33:33 2013 +0000 Commit: Michel Boaventura gmail com> CommitDate: Fri Oct 18 16:33:33 2013 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/ruby-overlay.git;a=commit;h=803c749c dev-ruby/rake: bump version to 10.1.0 and fix support for ruby 1.8.7 --- dev-ruby/rake/ChangeLog | 9 +++ dev-ruby/rake/files/rake-10.1.0-ruby-1.8-fix.patch | 66 ++++++++++++++++++++ dev-ruby/rake/files/rake.bash-completion | 55 +++++++++++++++++ dev-ruby/rake/metadata.xml | 8 +++ dev-ruby/rake/rake-10.1.0.ebuild | 70 ++++++++++++++++++++++ 5 files changed, 208 insertions(+) diff --git a/dev-ruby/rake/ChangeLog b/dev-ruby/rake/ChangeLog new file mode 100644 index 0000000..531f330 --- /dev/null +++ b/dev-ruby/rake/ChangeLog @@ -0,0 +1,9 @@ +# ChangeLog for dev-ruby/rake +# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 +# $Header: $ + +*rake-10.1.0 (18 Oct 2013) + + 18 Oct 2013; +files/rake-10.1.0-ruby-1.8-fix.patch, + +files/rake.bash-completion, +metadata.xml, +rake-10.1.0.ebuild: + Update rake to 10.1.0 and fix support for ruby 1.8.7 diff --git a/dev-ruby/rake/files/rake-10.1.0-ruby-1.8-fix.patch b/dev-ruby/rake/files/rake-10.1.0-ruby-1.8-fix.patch new file mode 100644 index 0000000..ee47902 --- /dev/null +++ b/dev-ruby/rake/files/rake-10.1.0-ruby-1.8-fix.patch @@ -0,0 +1,66 @@ +commit 514da2cec2ef3ca821c444f6b7b24f51bdd6e5d4 +Author: Jim Weirich +Date: Wed Jul 10 08:40:04 2013 -0400 + + Cleanup for 1.8.7 syntax. + +diff --git a/test/test_rake_backtrace.rb b/test/test_rake_backtrace.rb +index 8db3b5a..9a9c9e5 100644 +--- a/test/test_rake_backtrace.rb ++++ b/test/test_rake_backtrace.rb +@@ -12,6 +12,8 @@ class TestBacktraceSuppression < Rake::TestCase + + def test_system_dir_suppressed + path = RbConfig::CONFIG['rubylibprefix'] ++ skip if path.nil? ++ + paths = [path + ":12"] + + actual = Rake::Backtrace.collapse(paths) +@@ -21,6 +23,8 @@ class TestBacktraceSuppression < Rake::TestCase + + def test_near_system_dir_isnt_suppressed + path = RbConfig::CONFIG['rubylibprefix'] ++ skip if path.nil? ++ + paths = [" " + path + ":12"] + + actual = Rake::Backtrace.collapse(paths) +diff --git a/test/test_rake_clean.rb b/test/test_rake_clean.rb +index a6539fb..1dc7974 100644 +--- a/test/test_rake_clean.rb ++++ b/test/test_rake_clean.rb +@@ -15,7 +15,7 @@ class TestRakeClean < Rake::TestCase + file_name = create_undeletable_file + + out, _ = capture_io do +- Rake::Cleaner.cleanup(file_name, verbose: false) ++ Rake::Cleaner.cleanup(file_name, :verbose => false) + end + assert_match(/failed to remove/i, out) + +@@ -40,7 +40,7 @@ class TestRakeClean < Rake::TestCase + file_name = File.join(dir_name, "deleteme") + FileUtils.chmod(0777, dir_name) + FileUtils.chmod(0777, file_name) +- Rake::Cleaner.cleanup(file_name, verbose: false) +- Rake::Cleaner.cleanup(dir_name, verbose: false) ++ Rake::Cleaner.cleanup(file_name, :verbose => false) ++ Rake::Cleaner.cleanup(dir_name, :verbose => false) + end + end +diff --git a/test/test_rake_path_map.rb b/test/test_rake_path_map.rb +index b76a949..038ba1f 100644 +--- a/test/test_rake_path_map.rb ++++ b/test/test_rake_path_map.rb +@@ -156,8 +156,8 @@ class TestRakePathMap < Rake::TestCase + "src/org/onstepback/proj/A.java".pathmap("%{src,bin}d/%n.class")) + assert_equal( + "src_work/bin/org/onstepback/proj/A.class", +- "src_work/src/org/onstepback/proj/A.java" +- .pathmap('%{\bsrc\b,bin}X.class')) ++ "src_work/src/org/onstepback/proj/A.java". ++ pathmap('%{\bsrc\b,bin}X.class')) + assert_equal( + ".depends.bak", + ".depends".pathmap("%X.bak")) diff --git a/dev-ruby/rake/files/rake.bash-completion b/dev-ruby/rake/files/rake.bash-completion new file mode 100644 index 0000000..825f5d1 --- /dev/null +++ b/dev-ruby/rake/files/rake.bash-completion @@ -0,0 +1,55 @@ +have rake && +_rake() +{ + local cur prev rakef i + + COMPREPLY=() + cur=${COMP_WORDS[COMP_CWORD]} + prev=${COMP_WORDS[COMP_CWORD-1]} + rakef="Rakefile" + + if [[ "$prev" == "-f" ]]; then + _filedir + return 0 + fi + + if [[ "$cur" == *=* ]]; then + prev=${cur/=*/} + cur=${cur/*=/} + if [[ "$prev" == "--rakefile=" ]]; then + _filedir -o nospace + return 0 + fi + fi + + if [[ "$cur" == -* ]]; then + COMPREPLY=( $( compgen -W '-n -H -I -N -P -q -f\ + -r -s -T -t -h -v -V\ + --dry-run --help '--libdir=' --nosearch --prereqs --quiet\ + '--rakefile=' '--require=' --silent --tasks --trace --usage\ + --verbose --version'\ + -- $cur )) + else + + for (( i=0; i < ${#COMP_WORDS[@]}; i++)); do + case "${COMP_WORDS[i]}" in + -f) + eval rakef=${COMP_WORDS[i+1]} + break + ;; + --rakefile=*|--rakefile\=*) + eval rakef=${COMP_WORDS[i]/*=/} + break + ;; + esac + done + + [ ! -f $rakef ] && return 0 + + COMPREPLY=( $( rake -s -f "$rakef" -T | \ + awk -F ' ' '/^rake / { print $2 }' | \ + command grep "^$cur" )) + + fi +} && +complete -F _rake $filenames rake diff --git a/dev-ruby/rake/metadata.xml b/dev-ruby/rake/metadata.xml new file mode 100644 index 0000000..cf6388a --- /dev/null +++ b/dev-ruby/rake/metadata.xml @@ -0,0 +1,8 @@ + + + + ruby + + rake + + diff --git a/dev-ruby/rake/rake-10.1.0.ebuild b/dev-ruby/rake/rake-10.1.0.ebuild new file mode 100644 index 0000000..71a57a1 --- /dev/null +++ b/dev-ruby/rake/rake-10.1.0.ebuild @@ -0,0 +1,70 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-ruby/rake/rake-0.9.6.ebuild,v 1.5 2013/09/05 15:46:18 jer Exp $ + +EAPI=4 +USE_RUBY="ruby18 ruby19 ruby20 jruby" + +RUBY_FAKEGEM_TASK_DOC="" +RUBY_FAKEGEM_EXTRADOC="CHANGES README.rdoc TODO" + +RUBY_FAKEGEM_TASK_TEST="" + +inherit bash-completion-r1 ruby-fakegem + +DESCRIPTION="Make-like scripting in Ruby" +HOMEPAGE="http://rake.rubyforge.org/" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64" +IUSE="doc" + +DEPEND="${DEPEND} app-arch/gzip" +RDEPEND="${RDEPEND}" + +#This fix is already on upstream and will be fixed on next release +#https://github.com/jimweirich/rake/commit/514da2cec2ef3ca821c444f6b7b24f51bdd6e5d4 +RUBY_PATCHES=( "${P}-ruby-1.8-fix.patch" ) + +ruby_add_bdepend "doc? ( dev-ruby/rdoc ) + test? ( virtual/ruby-minitest dev-ruby/session dev-ruby/flexmock )" + +all_ruby_prepare() { + # Decompress the file. The compressed version has errors, ignore them. + zcat doc/rake.1.gz > doc/rake.1 +} + +each_ruby_prepare() { + case ${RUBY} in + *jruby) + # Remove failing test. This works on jruby 1.7, is a + # known bug on 1.6 and also fails on rake-0.9.6. + sed -i -e '/test_signal_propagation_in_tests/,/^ end/ s:^:#:' test/test_rake_functional.rb || die + ;; + esac +} + +all_ruby_compile() { + if use doc; then + ruby -Ilib bin/rake rdoc || die "doc generation failed" + fi +} + +each_ruby_test() { + ${RUBY} -Ilib bin/rake || die +} + +all_ruby_install() { + ruby_fakegem_binwrapper rake + + if use doc; then + pushd html + dohtml -r * + popd + fi + + doman doc/rake.1 + + newbashcomp "${FILESDIR}"/rake.bash-completion ${PN} +}