From 0c4b516b28eeca9148da4d80d4682ac3c29c76c4 Mon Sep 17 00:00:00 2001 From: Nick Cao Date: Tue, 8 Oct 2024 13:21:45 -0400 Subject: [PATCH] julia_16-bin: drop --- pkgs/development/compilers/julia/1.6-bin.nix | 72 ------------------- pkgs/development/compilers/julia/default.nix | 1 - ...able-parallel-unit-tests-for-sandbox.patch | 30 -------- pkgs/top-level/aliases.nix | 1 + pkgs/top-level/all-packages.nix | 5 +- 5 files changed, 3 insertions(+), 106 deletions(-) delete mode 100644 pkgs/development/compilers/julia/1.6-bin.nix delete mode 100644 pkgs/development/compilers/julia/patches/1.6-bin/0005-nix-Enable-parallel-unit-tests-for-sandbox.patch diff --git a/pkgs/development/compilers/julia/1.6-bin.nix b/pkgs/development/compilers/julia/1.6-bin.nix deleted file mode 100644 index dea8a140ee5f..000000000000 --- a/pkgs/development/compilers/julia/1.6-bin.nix +++ /dev/null @@ -1,72 +0,0 @@ -{ autoPatchelfHook, fetchurl, lib, stdenv }: - -stdenv.mkDerivation rec { - pname = "julia-bin"; - version = "1.6.7"; - - src = { - x86_64-linux = fetchurl { - url = "https://julialang-s3.julialang.org/bin/linux/x64/${lib.versions.majorMinor version}/julia-${version}-linux-x86_64.tar.gz"; - sha256 = "sha256-bEUi1ZXky80AFXrEWKcviuwBdXBT0gc/mdqjnkQrKjY="; - }; - }.${stdenv.hostPlatform.system} or (throw "Unsupported system: ${stdenv.hostPlatform.system}"); - - # Julia’s source files are in different locations for source and binary - # releases. Thus we temporarily create a symlink to allow us to share patches - # with source releases. - prePatch = '' - ln -s share/julia/test - ''; - patches = [ - # Source release Nix patch(es) relevant for binary releases as well. - ./patches/1.6-bin/0005-nix-Enable-parallel-unit-tests-for-sandbox.patch - ]; - postPatch = '' - # Revert symlink hack. - rm test - - # Julia fails to pick up our Certification Authority root certificates, but - # it provides its own so we can simply disable the test. Patching in the - # dynamic path to ours require us to rebuild the Julia system image. - substituteInPlace share/julia/stdlib/v${lib.versions.majorMinor version}/NetworkOptions/test/runtests.jl \ - --replace '@test ca_roots_path() != bundled_ca_roots()' \ - '@test_skip ca_roots_path() != bundled_ca_roots()' - ''; - - nativeBuildInputs = [ autoPatchelfHook ]; - - installPhase = '' - runHook preInstall - cp -r . $out - runHook postInstall - ''; - - # Breaks backtraces, etc. - dontStrip = true; - - doInstallCheck = true; - preInstallCheck = '' - # Some tests require read/write access to $HOME. - export HOME="$TMPDIR" - ''; - installCheckPhase = '' - runHook preInstallCheck - # Command lifted from `test/Makefile`. - $out/bin/julia \ - --check-bounds=yes \ - --startup-file=no \ - --depwarn=error \ - $out/share/julia/test/runtests.jl - runHook postInstallCheck - ''; - - meta = { - description = "High-level, high-performance, dynamic language for technical computing"; - homepage = "https://julialang.org"; - # Bundled and linked with various GPL code, although Julia itself is MIT. - license = lib.licenses.gpl2Plus; - maintainers = with lib.maintainers; [ raskin thomasjm ]; - platforms = [ "x86_64-linux" ]; - mainProgram = "julia"; - }; -} diff --git a/pkgs/development/compilers/julia/default.nix b/pkgs/development/compilers/julia/default.nix index 27200143fb26..87fe963b2ea4 100644 --- a/pkgs/development/compilers/julia/default.nix +++ b/pkgs/development/compilers/julia/default.nix @@ -12,7 +12,6 @@ let in { - julia_16-bin = wrapJulia (callPackage ./1.6-bin.nix { }); julia_19-bin = wrapJulia (callPackage (import ./generic-bin.nix { version = "1.9.4"; diff --git a/pkgs/development/compilers/julia/patches/1.6-bin/0005-nix-Enable-parallel-unit-tests-for-sandbox.patch b/pkgs/development/compilers/julia/patches/1.6-bin/0005-nix-Enable-parallel-unit-tests-for-sandbox.patch deleted file mode 100644 index 243a9cfd76ae..000000000000 --- a/pkgs/development/compilers/julia/patches/1.6-bin/0005-nix-Enable-parallel-unit-tests-for-sandbox.patch +++ /dev/null @@ -1,30 +0,0 @@ -From 44c2c979c4f2222567ce65f506cf47fb87482348 Mon Sep 17 00:00:00 2001 -From: Pontus Stenetorp -Date: Thu, 8 Apr 2021 04:37:44 +0000 -Subject: [PATCH 5/6] nix: Enable parallel unit tests for sandbox - -Disabled by default due to lack of networking in the Nix sandbox. This -greatly speeds up the build process on a multi-core system. ---- - test/runtests.jl | 5 +++-- - 1 file changed, 3 insertions(+), 2 deletions(-) - -diff --git a/test/runtests.jl b/test/runtests.jl -index 2f9cd058bb..2f8c19fa32 100644 ---- a/test/runtests.jl -+++ b/test/runtests.jl -@@ -83,8 +83,9 @@ prepend!(tests, linalg_tests) - import LinearAlgebra - cd(@__DIR__) do - n = 1 -- if net_on -- n = min(Sys.CPU_THREADS, length(tests)) -+ if net_on || haskey(ENV, "NIX_BUILD_CORES") -+ x = haskey(ENV, "NIX_BUILD_CORES") ? parse(Int, ENV["NIX_BUILD_CORES"]) : Sys.CPU_THREADS -+ n = min(x, Sys.CPU_THREADS, length(tests)) - n > 1 && addprocs_with_testenv(n) - LinearAlgebra.BLAS.set_num_threads(1) - end --- -2.29.3 - diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index dc7f0f6fc1ae..cb80182b6a3a 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -766,6 +766,7 @@ mapAliases { jsawk = throw "'jsawk' has been removed because it is unmaintained upstream"; # Added 2028-08-07 # Julia + julia_16-bin = throw "'julia_16-bin' has been removed from nixpkgs as it has reached end of life"; # Added 2024-10-08 julia_18 = throw "'julia_18' has been removed from nixpkgs as it has reached end of life"; # Added 2024-01-11 julia_18-bin = throw "'julia_18-bin' has been removed from nixpkgs as it has reached end of life"; # Added 2024-01-11 diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index d344c9e4572e..ac9891c0bc50 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -15178,7 +15178,6 @@ with pkgs; juniper = callPackage ../development/compilers/juniper { }; inherit (callPackage ../development/compilers/julia { }) - julia_16-bin julia_19-bin julia_110-bin julia_111-bin @@ -15186,11 +15185,11 @@ with pkgs; julia_110 julia_111; - julia-lts = julia_16-bin; + julia-lts = julia_110-bin; julia-stable = julia_110; julia = julia-stable; - julia-lts-bin = julia_16-bin; + julia-lts-bin = julia_110-bin; julia-stable-bin = julia_110-bin; julia-bin = julia-stable-bin;