Fix the new Ruby interpreters (fixes #3509).
Ruby >= 2.1.0 will try to download config.{sub,guess} if not already present. This provides both files in a pure manner, and also deletes the download script to prevent any future confusion.
This commit is contained in:
parent
eca58fd02f
commit
e38d7cbfb2
pkgs/development/interpreters/ruby
|
@ -0,0 +1,6 @@
|
||||||
|
# Ruby >= 2.1.0 tries to download config.{guess,sub}
|
||||||
|
fetchgit: fetchgit {
|
||||||
|
url = "git://git.sv.gnu.org/config.git";
|
||||||
|
rev = "576c839acca0e082e536fd27568b90a446ce5b96";
|
||||||
|
sha256 = "11bjngchjhj0qq0ppp8c37rfw0yhp230nvhs2jvlx15i9qbf56a0";
|
||||||
|
}
|
|
@ -1,4 +1,4 @@
|
||||||
{ stdenv, fetchurl, fetchFromGitHub
|
{ stdenv, fetchurl, fetchgit, fetchFromGitHub
|
||||||
, zlib, zlibSupport ? true
|
, zlib, zlibSupport ? true
|
||||||
, openssl, opensslSupport ? true
|
, openssl, opensslSupport ? true
|
||||||
, gdbm, gdbmSupport ? true
|
, gdbm, gdbmSupport ? true
|
||||||
|
@ -12,6 +12,7 @@ let
|
||||||
op = stdenv.lib.optional;
|
op = stdenv.lib.optional;
|
||||||
ops = stdenv.lib.optionals;
|
ops = stdenv.lib.optionals;
|
||||||
patchSet = import ./rvm-patchsets.nix { inherit fetchFromGitHub; };
|
patchSet = import ./rvm-patchsets.nix { inherit fetchFromGitHub; };
|
||||||
|
config = import ./config.nix fetchgit;
|
||||||
baseruby = ruby_2_1_0.override { useRailsExpress = false; };
|
baseruby = ruby_2_1_0.override { useRailsExpress = false; };
|
||||||
in
|
in
|
||||||
|
|
||||||
|
@ -63,6 +64,13 @@ stdenv.mkDerivation rec {
|
||||||
"${patchSet}/patches/ruby/2.1.0/railsexpress/12-backport-r44370.patch"
|
"${patchSet}/patches/ruby/2.1.0/railsexpress/12-backport-r44370.patch"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Ruby >= 2.1.0 tries to download config.{guess,sub}
|
||||||
|
postPatch = ''
|
||||||
|
rm tool/config_files.rb
|
||||||
|
cp ${config}/config.guess tool/
|
||||||
|
cp ${config}/config.sub tool/
|
||||||
|
'';
|
||||||
|
|
||||||
configureFlags = ["--enable-shared" ]
|
configureFlags = ["--enable-shared" ]
|
||||||
++ op useRailsExpress "--with-baseruby=${baseruby}/bin/ruby"
|
++ op useRailsExpress "--with-baseruby=${baseruby}/bin/ruby"
|
||||||
# on darwin, we have /usr/include/tk.h -- so the configure script detects
|
# on darwin, we have /usr/include/tk.h -- so the configure script detects
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ stdenv, fetchurl, fetchFromGitHub
|
{ stdenv, fetchurl, fetchgit, fetchFromGitHub
|
||||||
, zlib, zlibSupport ? true
|
, zlib, zlibSupport ? true
|
||||||
, openssl, opensslSupport ? true
|
, openssl, opensslSupport ? true
|
||||||
, gdbm, gdbmSupport ? true
|
, gdbm, gdbmSupport ? true
|
||||||
|
@ -12,6 +12,7 @@ let
|
||||||
op = stdenv.lib.optional;
|
op = stdenv.lib.optional;
|
||||||
ops = stdenv.lib.optionals;
|
ops = stdenv.lib.optionals;
|
||||||
patchSet = import ./rvm-patchsets.nix { inherit fetchFromGitHub; };
|
patchSet = import ./rvm-patchsets.nix { inherit fetchFromGitHub; };
|
||||||
|
config = import ./config.nix fetchgit;
|
||||||
baseruby = ruby_2_1_1.override { useRailsExpress = false; };
|
baseruby = ruby_2_1_1.override { useRailsExpress = false; };
|
||||||
in
|
in
|
||||||
|
|
||||||
|
@ -62,6 +63,13 @@ stdenv.mkDerivation rec {
|
||||||
"${patchSet}/patches/ruby/2.1.0/railsexpress/11-backport-r44370.patch"
|
"${patchSet}/patches/ruby/2.1.0/railsexpress/11-backport-r44370.patch"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Ruby >= 2.1.0 tries to download config.{guess,sub}
|
||||||
|
postPatch = ''
|
||||||
|
rm tool/config_files.rb
|
||||||
|
cp ${config}/config.guess tool/
|
||||||
|
cp ${config}/config.sub tool/
|
||||||
|
'';
|
||||||
|
|
||||||
configureFlags = ["--enable-shared" ]
|
configureFlags = ["--enable-shared" ]
|
||||||
++ op useRailsExpress "--with-baseruby=${baseruby}/bin/ruby"
|
++ op useRailsExpress "--with-baseruby=${baseruby}/bin/ruby"
|
||||||
# on darwin, we have /usr/include/tk.h -- so the configure script detects
|
# on darwin, we have /usr/include/tk.h -- so the configure script detects
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ stdenv, fetchurl, fetchFromGitHub
|
{ stdenv, fetchurl, fetchgit, fetchFromGitHub
|
||||||
, zlib, zlibSupport ? true
|
, zlib, zlibSupport ? true
|
||||||
, openssl, opensslSupport ? true
|
, openssl, opensslSupport ? true
|
||||||
, gdbm, gdbmSupport ? true
|
, gdbm, gdbmSupport ? true
|
||||||
|
@ -12,6 +12,7 @@ let
|
||||||
op = stdenv.lib.optional;
|
op = stdenv.lib.optional;
|
||||||
ops = stdenv.lib.optionals;
|
ops = stdenv.lib.optionals;
|
||||||
patchSet = import ./rvm-patchsets.nix { inherit fetchFromGitHub; };
|
patchSet = import ./rvm-patchsets.nix { inherit fetchFromGitHub; };
|
||||||
|
config = import ./config.nix fetchgit;
|
||||||
baseruby = ruby_2_1_2.override { useRailsExpress = false; };
|
baseruby = ruby_2_1_2.override { useRailsExpress = false; };
|
||||||
in
|
in
|
||||||
|
|
||||||
|
@ -61,6 +62,13 @@ stdenv.mkDerivation rec {
|
||||||
"${patchSet}/patches/ruby/2.1.2/railsexpress/10-funny-falcon-method-cache.patch"
|
"${patchSet}/patches/ruby/2.1.2/railsexpress/10-funny-falcon-method-cache.patch"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Ruby >= 2.1.0 tries to download config.{guess,sub}
|
||||||
|
postPatch = ''
|
||||||
|
rm tool/config_files.rb
|
||||||
|
cp ${config}/config.guess tool/
|
||||||
|
cp ${config}/config.sub tool/
|
||||||
|
'';
|
||||||
|
|
||||||
configureFlags = ["--enable-shared" ]
|
configureFlags = ["--enable-shared" ]
|
||||||
++ op useRailsExpress "--with-baseruby=${baseruby}/bin/ruby"
|
++ op useRailsExpress "--with-baseruby=${baseruby}/bin/ruby"
|
||||||
# on darwin, we have /usr/include/tk.h -- so the configure script detects
|
# on darwin, we have /usr/include/tk.h -- so the configure script detects
|
||||||
|
|
Loading…
Reference in New Issue