From 59be35113d81ca8f433d4b0a9a3950cd18a09e7e Mon Sep 17 00:00:00 2001 From: Mario Rodas Date: Tue, 2 Jan 2018 04:50:37 -0500 Subject: ruby_2_5: init at 2.5.0 (#33293) --- pkgs/development/interpreters/ruby/default.nix | 20 ++++++++++++++++++-- pkgs/development/interpreters/ruby/patchsets.nix | 5 +++++ pkgs/development/interpreters/ruby/rvm-patchsets.nix | 4 ++-- 3 files changed, 25 insertions(+), 4 deletions(-) (limited to 'pkgs/development/interpreters') diff --git a/pkgs/development/interpreters/ruby/default.nix b/pkgs/development/interpreters/ruby/default.nix index d664c00bc31d..3d18d5650a81 100644 --- a/pkgs/development/interpreters/ruby/default.nix +++ b/pkgs/development/interpreters/ruby/default.nix @@ -1,7 +1,7 @@ { stdenv, lib, fetchurl, fetchpatch, fetchFromSavannah, fetchFromGitHub , zlib, openssl, gdbm, ncurses, readline, groff, libyaml, libffi, autoreconfHook, bison , autoconf, darwin ? null -, buildEnv, bundler, bundix +, buildEnv, bundler, bundix, Foundation } @ args: let @@ -27,6 +27,7 @@ let tag = ver.gitTag; isRuby20 = ver.majMin == "2.0"; isRuby21 = ver.majMin == "2.1"; + isRuby25 = ver.majMin == "2.5"; baseruby = self.override { useRailsExpress = false; }; self = lib.makeOverridable ( { stdenv, lib, fetchurl, fetchpatch, fetchFromSavannah, fetchFromGitHub @@ -40,7 +41,7 @@ let , libffi, fiddleSupport ? true , autoreconfHook, bison, autoconf , darwin ? null - , buildEnv, bundler, bundix + , buildEnv, bundler, bundix, Foundation }: let rubySrc = if useRailsExpress then fetchFromGitHub { @@ -75,11 +76,13 @@ let ++ (op opensslSupport openssl) ++ (op gdbmSupport gdbm) ++ (op yamlSupport libyaml) + ++ (op isRuby25 autoconf) # Looks like ruby fails to build on darwin without readline even if curses # support is not enabled, so add readline to the build inputs if curses # support is disabled (if it's enabled, we already have it) and we're # running on darwin ++ (op (!cursesSupport && stdenv.isDarwin) readline) + ++ (op (isRuby25 && stdenv.isDarwin) Foundation) ++ (ops stdenv.isDarwin (with darwin; [ libiconv libobjc libunwind ])); enableParallelBuilding = true; @@ -106,6 +109,11 @@ let cp ${config}/config.guess tool/ cp ${config}/config.sub tool/ '' + else if isRuby25 then '' + sed -i configure.ac -e '/config.guess/d' + cp ${config}/config.guess tool/ + cp ${config}/config.sub tool/ + '' else opString useRailsExpress '' sed -i configure.in -e '/config.guess/d' cp ${config}/config.guess tool/ @@ -220,4 +228,12 @@ in { git = "1w83kzak3m6vv3k09ynfw9vpgc7vpmij3x3zmgrhwm4ds1sp5irl"; }; }; + + ruby_2_5_0 = generic { + version = rubyVersion "2" "5" "0" ""; + sha256 = { + src = "1azj0d2lzziw6iml7bx3sxpxzcdmfwfq3yhm7djyp20q1xiz7rj6"; + git = "0d436nqmp3ykdkp4sck5bb8sf3qvx30x1p58xh8axv66mvsyc2jd"; + }; + }; } diff --git a/pkgs/development/interpreters/ruby/patchsets.nix b/pkgs/development/interpreters/ruby/patchsets.nix index 3d3b17cd2f70..858bc0a13f34 100644 --- a/pkgs/development/interpreters/ruby/patchsets.nix +++ b/pkgs/development/interpreters/ruby/patchsets.nix @@ -39,4 +39,9 @@ rec { "${patchSet}/patches/ruby/2.4/head/railsexpress/02-improve-gc-stats.patch" "${patchSet}/patches/ruby/2.4/head/railsexpress/03-display-more-detailed-stack-trace.patch" ]; + "2.5.0" = ops useRailsExpress [ + "${patchSet}/patches/ruby/2.5/head/railsexpress/01-fix-broken-tests-caused-by-ad.patch" + "${patchSet}/patches/ruby/2.5/head/railsexpress/02-improve-gc-stats.patch" + "${patchSet}/patches/ruby/2.5/head/railsexpress/03-more-detailed-stacktrace.patch" + ]; } diff --git a/pkgs/development/interpreters/ruby/rvm-patchsets.nix b/pkgs/development/interpreters/ruby/rvm-patchsets.nix index c60d6e3728d0..1598cbc56e1d 100644 --- a/pkgs/development/interpreters/ruby/rvm-patchsets.nix +++ b/pkgs/development/interpreters/ruby/rvm-patchsets.nix @@ -3,6 +3,6 @@ fetchFromGitHub { owner = "skaes"; repo = "rvm-patchsets"; - rev = "15f5df0fba0e2fb489856b5bdb67a52fb9745f94"; - sha256 = "0vdgr7xp3gbmsyaz4q78qlbwmp006b1gkgj0kwi6h8d80dclbzny"; + rev = "ba5a3c6f972e1b957b4b3fe28b5730ef0e27bff3"; + sha256 = "0sjmhhb8hshxa58x062j44w0xdck8ykgpsg33wjr0wv9npwpkwrz"; } -- cgit 1.4.1