1 { lib, stdenv, fetchurl, autoconf, gfortran, hepmc3, fastjet, lhapdf, rivet, sqlite }:
3 stdenv.mkDerivation rec {
8 url = "https://www.hepforge.org/archive/sherpa/SHERPA-MC-${version}.tar.gz";
9 sha256 = "sha256-AntSN5BhtJFuDBoOFvrzoCr/W4SnX5CeAXiTcz9MjUs=";
12 postPatch = lib.optionalString (stdenv.hostPlatform.libc == "glibc") ''
13 sed -ie '/sys\/sysctl.h/d' ATOOLS/Org/Run_Parameter.C
16 nativeBuildInputs = [ autoconf gfortran ];
18 buildInputs = [ sqlite lhapdf rivet ];
20 enableParallelBuilding = true;
23 "--with-sqlite3=${sqlite.dev}"
24 "--enable-hepmc3=${hepmc3}"
25 "--enable-fastjet=${fastjet}"
26 "--enable-lhapdf=${lhapdf}"
27 "--enable-rivet=${rivet}"
32 description = "Simulation of High-Energy Reactions of PArticles in lepton-lepton, lepton-photon, photon-photon, lepton-hadron and hadron-hadron collisions";
33 license = licenses.gpl2;
34 homepage = "https://gitlab.com/sherpa-team/sherpa";
35 platforms = platforms.unix;
36 maintainers = with maintainers; [ veprbl ];
37 # never built on aarch64-darwin since first introduction in nixpkgs
38 broken = stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64;