diff options
-rw-r--r-- | libre/ruby/PKGBUILD | 27 | ||||
-rw-r--r-- | libre/ruby/json-2.0.2-libre.patch | 36 | ||||
-rw-r--r-- | libre/ruby/json-2.0.2-ruby-2.4.1-backports.patch | 64 | ||||
-rw-r--r-- | libre/ruby/json-2.1.0-libre.patch | 19 | ||||
-rw-r--r-- | libre/ruby/ruby-2.5.0-add-json_pure.patch (renamed from libre/ruby/ruby-2.4.1-add-json_pure.patch) | 10 | ||||
-rw-r--r-- | libre/ruby/ruby-2.5.0-remove-json-ext.patch (renamed from libre/ruby/ruby-2.4.1-remove-json-ext.patch) | 87 | ||||
-rw-r--r-- | libre/ruby/ruby.install | 2 |
7 files changed, 64 insertions, 181 deletions
diff --git a/libre/ruby/PKGBUILD b/libre/ruby/PKGBUILD index 002a67eaa..772bea4fa 100644 --- a/libre/ruby/PKGBUILD +++ b/libre/ruby/PKGBUILD @@ -7,6 +7,7 @@ # Contributor: Daniel Milewski <niitotantei@riseup.net> # Contributor: André Silva <emulatorman@hyperbola.info> # Contributor: Luke Shumaker <lukeshu@parabola.nu> +# Contributor: Omar Vega Ramos <ovruni@gnu.org.pe> # Rationale for inclusion in [libre]: Problematic license of # generator.c in bundled json extension. @@ -16,10 +17,10 @@ # https://github.com/flori/json/issues/277 pkgname=(ruby ruby-docs) -pkgver=2.4.1 -_jsonver=2.0.2 -pkgrel=3.parabola3 -_srcrel=2 # increment this to rebuild the sourceball without bumping pkgver +pkgver=2.5.0 +_jsonver=2.1.0 +pkgrel=1.parabola1 +_srcrel=1 # increment this to rebuild the sourceball without bumping pkgver arch=(i686 x86_64 armv7h) url='http://www.ruby-lang.org/en/' license=(BSD2 custom) @@ -27,28 +28,24 @@ makedepends=(gdbm openssl libffi doxygen graphviz libyaml ttf-dejavu tk) options=(!emptydirs) source=(https://repo.parabola.nu/other/ruby-libre/ruby-${pkgver}-libre${_srcrel}.tar.gz gemrc) -sha1sums=('ca7ca50c2e96200062afe081bf82c2cfaa3d18a1' - 'dc536754c8fac2c3d82965c5a708cd8f79562d98') +sha512sums=('e94355d3d9b6882f4dc355ca6721a0ce1b777f7f1144144adfa2e5732acbfb69f16b062ce9fad5be0e2e06ac49db0171d9e9fcc43c78836b5bbf3a5b97ef145e' + '8cafd14d414ee3c16aa94f79072bc6c100262f925dc1300e785846c3fabbbbffc1356b8e2223af5684e3340c55032d41231179ffa948bb12e01dbae0f4131911') mkdepends=('ruby') # for 'gem build' mksource=(https://cache.ruby-lang.org/pub/ruby/${pkgver:0:3}/ruby-${pkgver}.tar.xz ruby-${pkgver}-remove-json-ext.patch ruby-${pkgver}-add-json_pure.patch json-${_jsonver}.tar.gz::https://github.com/flori/json/archive/v${_jsonver}.tar.gz - json-${_jsonver}-ruby-${pkgver}-backports.patch json-${_jsonver}-libre.patch) -mksha512sums=('e6fd290b6edd166348b70f0f1c56f7ed9d956c4c1eb91d97d0548041ca4196b9b75ec1ad35c745bdbfd4de195899093e7205d7f02b014ecf1c48e6f31cf25903' - 'a7b6a5a6da4861ee51f3e9a9064c39ef1e5f2efb7d969f20f93028acfa0eed0264c336fce2eb1c6a3bdcdc595ef2cf3441b5db7cd4eebf5f24e5cb4a19a7d915' - '29185acc7ea3ad48e805945e53717bfd8483a0581236eb49e63eb8e9f467ddcede38a606d089aa35e5fb73099a1ebdb253fc4c51a7933b900fc36918a43628b8' - '405f09681808c108ec4a889f7628ede4aec15122c8a6848b5a7ec99a17bd8d72bf410152461164acd0f17d92a460732bf525c26a17b319b94dc940dccf6d3ebf' - '1882619e98fa4b6cc2738c25ebf0ba957499f6b20f6837f23379b90700a6a751d0a9be85032f1c9e1d98f8d839784a3caa611266ad68e311dd3747cb0396b817' - '53459f8971e87a3a5dfff3e72be5d27460a624eff06ccabb57bef1fd039c77d67f0f9eecdc03661c929d9eda9bff8f86383c9b16b15602a874bcf1914aecf633') +mksha512sums=('55714a33d7661fe8b432f73c34fd67b49699f8b79df1cbd680a74899124d31111ab0f444677672aac1ba725820182940d485efb2db0bf2bc96737c5d40c54578' + 'dbfd2517e87571e25fea832f50535e76c07972e15f48050ad7b08b04993c566ae7b5e8b1dd0e3cd65eb6161290026eaa71ff4528e98a92e37983066b4929cfb1' + '303172561a4ba54515fddfd9ea7e0c833e550b0ae5e9f331956f178f8c5e20aa0e3c4036251ddfd04312769ef7d71d83fde0afe64f6fa8e9052ca5a294c62927' + '6019cc26a0919e4d39ae0bf737b51cd9a474c74a55d25f6931ac04d61826bb810d063190a80a29810e57d7457d1a247acd82fd78de2c4c01acb7d73ee9fde603' + 'ccbcbc964e08c10470f1552cec5bcf71fc14f4f6faf83e51fcaf01b662596f5400e7f60279209c9d4df03e3c798b9008383667375f884a1115ac96956053a38d') mksource() { # Start with the vanilla version of json cd "$srcdir/json-${_jsonver}" - # Apply changes made to it for the ruby distribution - patch -p1 -i ../json-${_jsonver}-ruby-${pkgver}-backports.patch # Modify it so that 'json' doesn't try to load (non-free!) 'json/ext' rm -rf -- json.gemspec ext lib/json/ext* patch -p1 -i ../json-${_jsonver}-libre.patch diff --git a/libre/ruby/json-2.0.2-libre.patch b/libre/ruby/json-2.0.2-libre.patch deleted file mode 100644 index 188bc628e..000000000 --- a/libre/ruby/json-2.0.2-libre.patch +++ /dev/null @@ -1,36 +0,0 @@ -diff --git a/lib/json.rb b/lib/json.rb -index b5a6912415..bf93c663fe 100644 ---- a/lib/json.rb -+++ b/lib/json.rb -@@ -55,9 +55,5 @@ - module JSON - require 'json/version' - -- begin -- require 'json/ext' -- rescue LoadError -- require 'json/pure' -- end -+ require 'json/pure' - end ---- a/tests/test_helper.rb -+++ b/tests/test_helper.rb -@@ -1,16 +1,7 @@ - gem 'json', File.read('VERSION').chomp - --case ENV['JSON'] --when 'pure' -- $:.unshift 'lib' -- require 'json/pure' --when 'ext' -- $:.unshift 'ext', 'lib' -- require 'json/ext' --else -- $:.unshift 'ext', 'lib' -- require 'json' --end -+$:.unshift 'lib' -+require 'json' - - require 'test/unit' - begin diff --git a/libre/ruby/json-2.0.2-ruby-2.4.1-backports.patch b/libre/ruby/json-2.0.2-ruby-2.4.1-backports.patch deleted file mode 100644 index 4791731fb..000000000 --- a/libre/ruby/json-2.0.2-ruby-2.4.1-backports.patch +++ /dev/null @@ -1,64 +0,0 @@ -This is the complete set of patches applied to json-2.0.2 for the ruby -2.4.1 distribution (excluding build system changes). - - -- Luke Shumaker - Parabola GNU/Linux-libre - -commit 1ffad9c1a7bafb59453acf0779231e241458260b -Author: nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> -Date: Fri Sep 9 09:27:38 2016 +0000 - - json_generator_test.rb: no Bignum - - * test/json/json_generator_test.rb (test_broken_bignum): get rid - of use of Bignum, obsolete name. - - git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56126 b2dd03c8-39d4-4d8f-98ff-823fe69b080e - (cherry picked from commit 7f6410f02d3092075b9990705d0151ffb44f51a1) - -diff --git a/tests/json_generator_test.rb b/tests/json_generator_test.rb -index 18b08337f8..86be398f46 100644 ---- a/tests/json_generator_test.rb -+++ b/tests/json_generator_test.rb -@@ -277,12 +277,13 @@ EOT - if defined?(JSON::Ext::Generator) - def test_broken_bignum # [ruby-core:38867] - pid = fork do -- Bignum.class_eval do -+ x = 1 << 64 -+ x.class.class_eval do - def to_s - end - end - begin -- JSON::Ext::Generator::State.new.generate(1<<64) -+ JSON::Ext::Generator::State.new.generate(x) - exit 1 - rescue TypeError - exit 0 - -commit 9f4a32dbd50df3bb066be4028a3b1bb9845c76cd -Author: nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> -Date: Tue Aug 30 06:27:29 2016 +0000 - - Fix rdoc of OpenStruct.json_create [ci skip] - - * ext/json/lib/json/add/ostruct.rb (OpenStruct.json_create): - Correct documentation, fix the name of values. [Fix GH-1421] - - git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56038 b2dd03c8-39d4-4d8f-98ff-823fe69b080e - (cherry picked from commit c2d77880c070fa94e6fe1e31e477225c13318933) - -diff --git a/lib/json/add/ostruct.rb b/lib/json/add/ostruct.rb -index 7c13910052..e064c85ff4 100644 ---- a/lib/json/add/ostruct.rb -+++ b/lib/json/add/ostruct.rb -@@ -7,7 +7,7 @@ require 'ostruct' - class OpenStruct - - # Deserializes JSON string by constructing new Struct object with values -- # <tt>v</tt> serialized by <tt>to_json</tt>. -+ # <tt>t</tt> serialized by <tt>to_json</tt>. - def self.json_create(object) - new(object['t'] || object[:t]) - end diff --git a/libre/ruby/json-2.1.0-libre.patch b/libre/ruby/json-2.1.0-libre.patch new file mode 100644 index 000000000..7b188ad91 --- /dev/null +++ b/libre/ruby/json-2.1.0-libre.patch @@ -0,0 +1,19 @@ +--- a/tests/test_helper.rb 2017-04-18 04:16:28.000000000 -0500 ++++ b/tests/test_helper.rb 2018-01-07 10:52:13.466053202 -0500 +@@ -1,14 +1,5 @@ +-case ENV['JSON'] +-when 'pure' +- $:.unshift 'lib' +- require 'json/pure' +-when 'ext' +- $:.unshift 'ext', 'lib' +- require 'json/ext' +-else +- $:.unshift 'ext', 'lib' +- require 'json' +-end ++$:.unshift 'lib' ++require 'json' + + require 'test/unit' + begin diff --git a/libre/ruby/ruby-2.4.1-add-json_pure.patch b/libre/ruby/ruby-2.5.0-add-json_pure.patch index b624687d0..5630451ea 100644 --- a/libre/ruby/ruby-2.4.1-add-json_pure.patch +++ b/libre/ruby/ruby-2.5.0-add-json_pure.patch @@ -20,13 +20,3 @@ index 0000000000..7ae6b614de +*.rb +add/*.rb +pure/*.rb -diff --git a/test/json/test_helper.rb b/test/json/test_helper.rb -index 9d3665d47a..3feed36b6a 100644 ---- a/test/json/test_helper.rb -+++ b/test/json/test_helper.rb -@@ -1,5 +1,3 @@ --gem 'json', File.read('VERSION').chomp -- - $:.unshift 'lib' - require 'json' - diff --git a/libre/ruby/ruby-2.4.1-remove-json-ext.patch b/libre/ruby/ruby-2.5.0-remove-json-ext.patch index 4005e4ccf..507f8283a 100644 --- a/libre/ruby/ruby-2.4.1-remove-json-ext.patch +++ b/libre/ruby/ruby-2.5.0-remove-json-ext.patch @@ -1,8 +1,6 @@ -diff --git a/LEGAL b/LEGAL -index 8080cfef61..d5dfef033c 100644 ---- a/LEGAL -+++ b/LEGAL -@@ -593,28 +593,6 @@ ext/digest/sha2/sha2.[ch]: +--- a/LEGAL 2017-12-22 18:08:05.000000000 -0500 ++++ b/LEGAL 2018-01-07 09:52:56.660004692 -0500 +@@ -625,28 +625,6 @@ OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. @@ -31,11 +29,9 @@ index 8080cfef61..d5dfef033c 100644 ext/nkf/nkf-utf8/config.h: ext/nkf/nkf-utf8/nkf.c: ext/nkf/nkf-utf8/utf8tbl.c: -diff --git a/common.mk b/common.mk -index 3f4bcf6c3a..6c5bea5402 100644 ---- a/common.mk -+++ b/common.mk -@@ -814,8 +814,7 @@ EXT_SRCS = $(srcdir)/ext/ripper/ripper.c \ +--- a/common.mk 2017-12-22 18:08:05.000000000 -0500 ++++ b/common.mk 2018-01-07 09:56:46.206272867 -0500 +@@ -903,8 +903,7 @@ srcs-ext: $(EXT_SRCS) @@ -45,49 +41,44 @@ index 3f4bcf6c3a..6c5bea5402 100644 $(empty) LIB_SRCS = $(srcdir)/lib/unicode_normalize/tables.rb -@@ -911,11 +910,6 @@ $(srcdir)/ext/ripper/ripper.c: $(srcdir)/parse.y id.h - Q=$(Q) ECHO=$(ECHO) RM="$(RM)" top_srcdir=../.. srcdir=. VPATH="$(PWD)" \ +@@ -1006,11 +1005,6 @@ + Q=$(Q) ECHO=$(ECHO) RM="$(RM)" top_srcdir=../.. srcdir=. VPATH="$${VPATH}" \ RUBY="$(BASERUBY)" PATH_SEPARATOR="$(PATH_SEPARATOR)" -$(srcdir)/ext/json/parser/parser.c: $(srcdir)/ext/json/parser/parser.rl - $(ECHO) generating $@ -- $(Q) $(CHDIR) $(@D) && $(exec) $(MAKE) -f prereq.mk $(MFLAGS) \ +- $(Q) $(CHDIR) $(@D) && $(exec) $(MAKE) -f prereq.mk $(mflags) \ - Q=$(Q) ECHO=$(ECHO) top_srcdir=../../.. srcdir=. VPATH=../../.. BASERUBY="$(BASERUBY)" - $(srcdir)/ext/date/zonetab.h: $(srcdir)/ext/date/zonetab.list $(ECHO) generating $@ - $(Q) $(CHDIR) $(@D) && $(exec) $(MAKE) -f prereq.mk $(MFLAGS) \ -diff --git a/doc/maintainers.rdoc b/doc/maintainers.rdoc -index d22d09f7a4..ec6a6b7134 100644 ---- a/doc/maintainers.rdoc -+++ b/doc/maintainers.rdoc -@@ -209,8 +209,6 @@ Zachary Scott (zzak) - Nobuyuki Nakada (nobu) - [ext/io/wait] + $(Q) $(CHDIR) $(@D) && $(exec) $(MAKE) -f prereq.mk $(mflags) \ +--- a/doc/maintainers.rdoc 2017-12-22 18:08:05.000000000 -0500 ++++ b/doc/maintainers.rdoc 2018-01-07 09:57:59.999596681 -0500 +@@ -253,9 +253,6 @@ + [ext/io/console] Nobuyuki Nakada (nobu) + https://github.com/ruby/io-console -[ext/json] -- NARUSE, Yui (naruse) - [ext/mathn/complex] - Keiju ISHITSUKA (keiju) - [ext/mathn/rational] -diff --git a/ext/.document b/ext/.document -index 2e6fc78879..f5da0912ed 100644 ---- a/ext/.document -+++ b/ext/.document -@@ -35,9 +35,6 @@ io/console/console.c +- NARUSE, Yui (naruse), Hiroshi SHIBATA (hsbt) +- https://github.com/flori/json + [ext/openssl] + Kazuki Yamaguchi (rhe) + https://github.com/ruby/openssl +--- a/ext/.document 2017-09-03 08:31:34.000000000 -0500 ++++ b/ext/.document 2018-01-07 09:58:54.180475610 -0500 +@@ -27,9 +27,6 @@ + io/console/console.c io/nonblock/nonblock.c - io/wait/lib io/wait/wait.c --json/ext/generator/generator.c --json/ext/parser/parser.c +-json/generator/generator.c -json/lib - mathn/complex/complex.c - mathn/rational/rational.c +-json/parser/parser.c nkf/lib -diff --git a/ext/Setup b/ext/Setup -index 0929d647ae..7d5e99bca7 100644 ---- a/ext/Setup -+++ b/ext/Setup + nkf/nkf.c + objspace/objspace.c +--- a/ext/Setup 2017-04-20 03:21:24.000000000 -0500 ++++ b/ext/Setup 2018-01-07 10:06:52.168822642 -0500 @@ -20,9 +20,6 @@ #io/console #io/nonblock @@ -95,20 +86,6 @@ index 0929d647ae..7d5e99bca7 100644 -#json -#json/generator -#json/parser - #mathn/complex - #mathn/rational #nkf -diff --git a/ext/Setup.nacl b/ext/Setup.nacl -index eb8a1a70cd..4b1cca1392 100644 ---- a/ext/Setup.nacl -+++ b/ext/Setup.nacl -@@ -22,9 +22,6 @@ - # io/console - # io/nonblock - # io/wait --# #json --# json/generator --# json/parser - # mathn/complex - # mathn/rational - # nkf + #objspace + #openssl diff --git a/libre/ruby/ruby.install b/libre/ruby/ruby.install index ce78e96ec..165936c23 100644 --- a/libre/ruby/ruby.install +++ b/libre/ruby/ruby.install @@ -3,7 +3,7 @@ print_gem_default_target() { echo 'The default location of gem installs is $HOME/.gem/ruby' echo 'Add the following line to your PATH if you plan to install using gem' - echo '$(ruby -rubygems -e "puts Gem.user_dir")/bin' + echo '$(ruby -e "puts Gem.user_dir")/bin' echo 'If you want to install to the system wide location, you must either:' echo 'edit /etc/gemrc or run gem with the --no-user-install flag.' } |