diff --git a/pkgs/development/libraries/physics/fastnlo/default.nix b/pkgs/development/libraries/physics/fastnlo_toolkit/default.nix similarity index 69% rename from pkgs/development/libraries/physics/fastnlo/default.nix rename to pkgs/development/libraries/physics/fastnlo_toolkit/default.nix index 87e2ae9631c..d6cbe7cc4dd 100644 --- a/pkgs/development/libraries/physics/fastnlo/default.nix +++ b/pkgs/development/libraries/physics/fastnlo_toolkit/default.nix @@ -1,38 +1,44 @@ { lib , stdenv , fetchurl +, autoreconfHook , boost -, fastjet , gfortran , lhapdf -, python2 -, root +, ncurses +, python +, swig , yoda , zlib +, withPython ? false }: stdenv.mkDerivation rec { pname = "fastnlo_toolkit"; - version = "2.3.1pre-2402"; + version = "2.3.1pre-2411"; src = fetchurl { - url = "https://fastnlo.hepforge.org/code/v23/${pname}-${version}.tar.gz"; - sha256 = "1h41xnqcz401x3zbs8i2dsb4xlhbv8i5ps0561p6y7gcyridgcbl"; + urls = [ + "https://fastnlo.hepforge.org/code/v23/${pname}-${version}.tar.gz" + "https://sid.ethz.ch/debian/fastnlo/${pname}-${version}.tar.gz" + ]; + sha256 = "0fm9k732pmi3prbicj2yaq815nmcjll95fagjqzf542ng3swpqnb"; }; + nativeBuildInputs = lib.optional withPython autoreconfHook; + buildInputs = [ boost - fastjet gfortran gfortran.cc.lib lhapdf - python2 - root yoda - ]; + ] ++ lib.optional withPython python + ++ lib.optional (withPython && python.isPy3k) ncurses; + propagatedBuildInputs = [ zlib - ]; + ] ++ lib.optional withPython swig; preConfigure = '' substituteInPlace ./fastnlotoolkit/Makefile.in \ @@ -41,7 +47,7 @@ stdenv.mkDerivation rec { configureFlags = [ "--with-yoda=${yoda}" - ]; + ] ++ lib.optional withPython "--enable-pyext"; enableParallelBuilding = true; diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index 56f6be15e49..9f62e7f547f 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -195,6 +195,7 @@ mapAliases ({ exfat-utils = exfat; # 2015-09-11 facette = throw "facette has been removed."; # added 2020-01-06 fast-neural-doodle = throw "fast-neural-doodle has been removed, as the upstream project has been abandoned"; # added 2020-03-28 + fastnlo = fastnlo_toolkit; # added 2021-04-24 fedora-coreos-config-transpiler = throw "fedora-coreos-config-transpiler has been renamed to 'butane'."; # added 2021-04-13 fetchFromGithub = throw "You meant fetchFromGitHub, with a capital H."; ffadoFull = ffado; # added 2018-05-01 diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 01fa18d0dfa..5dec430b2db 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -29717,7 +29717,7 @@ in fastjet-contrib = callPackage ../development/libraries/physics/fastjet-contrib { }; - fastnlo = callPackage ../development/libraries/physics/fastnlo { }; + fastnlo_toolkit = callPackage ../development/libraries/physics/fastnlo_toolkit { }; geant4 = libsForQt5.callPackage ../development/libraries/physics/geant4 { }; diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index ad9350093a2..a40e14cf358 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -2303,6 +2303,11 @@ in { fastjsonschema = callPackage ../development/python-modules/fastjsonschema { }; + fastnlo_toolkit = toPythonModule (pkgs.fastnlo_toolkit.override { + withPython = true; + inherit python; + }); + fastpair = callPackage ../development/python-modules/fastpair { }; fastparquet = callPackage ../development/python-modules/fastparquet { };