Merge pull request #47291 from veprbl/pr/xfitter_init

xfitter: init at 2.0.0
This commit is contained in:
Matthew Bauer
2018-10-05 22:38:09 -05:00
committed by GitHub
12 changed files with 811 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
{ stdenv, fetchFromGitHub, gfortran, lhapdf, python2 }:
stdenv.mkDerivation rec {
name = "apfel-${version}";
version = "3.0.3";
src = fetchFromGitHub {
owner = "scarrazza";
repo = "apfel";
rev = version;
sha256 = "13dvcc5ba6djflrcy5zf5ikaw8s78zd8ac6ickc0hxhbmx1gjb4j";
};
buildInputs = [ gfortran lhapdf python2 ];
enableParallelBuilding = true;
meta = with stdenv.lib; {
description = "A PDF Evolution Library";
license = licenses.gpl3;
homepage = http://apfel.mi.infn.it/;
platforms = platforms.unix;
maintainers = with maintainers; [ veprbl ];
};
}

View File

@@ -0,0 +1,26 @@
{ stdenv, fetchFromGitHub, autoreconfHook, apfel, applgrid, lhapdf, root }:
stdenv.mkDerivation rec {
name = "apfelgrid-${version}";
version = "1.0.1";
src = fetchFromGitHub {
owner = "nhartland";
repo = "APFELgrid";
rev = "v${version}";
sha256 = "0l0cyxd00kmb5aggzwsxg83ah0qiwav0shbxkxwrz3dvw78n89jk";
};
nativeBuildInputs = [ autoreconfHook ];
buildInputs = [ apfel applgrid lhapdf root ];
enableParallelBuilding = true;
meta = with stdenv.lib; {
description = "Ultra-fast theory predictions for collider observables";
license = licenses.mit;
homepage = http://nhartland.github.io/APFELgrid/;
platforms = platforms.unix;
maintainers = with maintainers; [ veprbl ];
};
}

View File

@@ -0,0 +1,39 @@
diff --git a/appl_grid/appl_grid.h b/appl_grid/appl_grid.h
index 5059622..a0651c9 100644
--- a/appl_grid/appl_grid.h
+++ b/appl_grid/appl_grid.h
@@ -56,7 +56,7 @@ public:
class exception : public std::exception {
public:
exception(const std::string& s) { std::cerr << what() << " " << s << std::endl; };
- exception(std::ostream& s) { std::cerr << what() << " " << s << std::endl; };
+ exception(std::ostream& s) { s << what() << " " << std::endl; };
virtual const char* what() const throw() { return "appl::grid::exception"; }
};
diff --git a/appl_grid/appl_pdf.h b/appl_grid/appl_pdf.h
index c71fd84..2525527 100644
--- a/appl_grid/appl_pdf.h
+++ b/appl_grid/appl_pdf.h
@@ -51,7 +51,7 @@ public:
class exception : public std::exception {
public:
exception(const std::string& s="") { std::cerr << what() << " " << s << std::endl; };
- exception(std::ostream& s) { std::cerr << what() << " " << s << std::endl; };
+ exception(std::ostream& s) { s << " " << std::endl; };
const char* what() const throw() { return "appl::appl_pdf::exception "; }
};
diff --git a/src/appl_igrid.h b/src/appl_igrid.h
index d25288e..be354df 100644
--- a/src/appl_igrid.h
+++ b/src/appl_igrid.h
@@ -52,7 +52,7 @@ private:
class exception {
public:
exception(const std::string& s) { std::cerr << s << std::endl; };
- exception(std::ostream& s) { std::cerr << s << std::endl; };
+ exception(std::ostream& s) { s << std::endl; };
};
typedef double (igrid::*transform_t)(double) const;

View File

@@ -0,0 +1,42 @@
{ stdenv, fetchurl, gfortran, hoppet, lhapdf, root5 }:
stdenv.mkDerivation rec {
name = "applgrid-${version}";
version = "1.4.70";
src = fetchurl {
url = "https://www.hepforge.org/archive/applgrid/${name}.tgz";
sha256 = "1yw9wrk3vjv84kd3j4s1scfhinirknwk6xq0hvj7x2srx3h93q9p";
};
buildInputs = [ gfortran hoppet lhapdf root5 ];
patches = [
./bad_code.patch
];
preConfigure = ''
substituteInPlace src/Makefile.in \
--replace "-L\$(subst /libgfortran.a, ,\$(FRTLIB) )" "-L${gfortran.cc.lib}/lib"
'' + (if stdenv.isDarwin then ''
substituteInPlace src/Makefile.in \
--replace "gfortran -print-file-name=libgfortran.a" "gfortran -print-file-name=libgfortran.dylib"
'' else "");
enableParallelBuilding = false; # broken
# Install private headers required by APFELgrid
postInstall = ''
for header in src/*.h; do
install -Dm644 "$header" "$out"/include/appl_grid/"`basename $header`"
done
'';
meta = with stdenv.lib; {
description = "The APPLgrid project provides a fast and flexible way to reproduce the results of full NLO calculations with any input parton distribution set in only a few milliseconds rather than the weeks normally required to gain adequate statistics";
license = licenses.gpl3;
homepage = http://applgrid.hepforge.org;
platforms = platforms.unix;
maintainers = with maintainers; [ veprbl ];
};
}

View File

@@ -0,0 +1,23 @@
{ stdenv, fetchurl, gfortran }:
stdenv.mkDerivation rec {
name = "hoppet-${version}";
version = "1.2.0";
src = fetchurl {
url = "https://hoppet.hepforge.org/downloads/${name}.tgz";
sha256 = "0j7437rh4xxbfzmkjr22ry34xm266gijzj6mvrq193fcsfzipzdz";
};
buildInputs = [ gfortran ];
enableParallelBuilding = true;
meta = with stdenv.lib; {
description = "Higher Order Perturbative Parton Evolution Toolkit";
license = licenses.gpl2;
homepage = https://hoppet.hepforge.org;
platforms = platforms.unix;
maintainers = with maintainers; [ veprbl ];
};
}

View File

@@ -0,0 +1,25 @@
{ stdenv, fetchFromGitHub, gfortran }:
stdenv.mkDerivation rec {
name = "mela-${version}";
version = "2.0.1";
src = fetchFromGitHub {
owner = "vbertone";
repo = "MELA";
rev = version;
sha256 = "01sgd4mwx4n58x95brphp4dskqkkx8434bvsr38r5drg9na5nc9y";
};
buildInputs = [ gfortran ];
enableParallelBuilding = true;
meta = with stdenv.lib; {
description = "a Mellin Evolution LibrAry";
license = licenses.gpl3;
homepage = https://github.com/vbertone/MELA;
platforms = platforms.unix;
maintainers = with maintainers; [ veprbl ];
};
}

View File

@@ -0,0 +1,23 @@
{ stdenv, fetchurl, gfortran }:
stdenv.mkDerivation rec {
name = "QCDNUM-${version}";
version = "17-01-14";
src = fetchurl {
url = "http://www.nikhef.nl/user/h24/qcdnum-files/download/qcdnum${builtins.replaceStrings ["-"] [""] version}.tar.gz";
sha256 = "199s6kgmszxgjzd9214mpx3kyplq2q6987sii67s5xkg10ynyv31";
};
nativeBuildInputs = [ gfortran ];
enableParallelBuilding = true;
meta = {
description = "QCDNUM is a very fast QCD evolution program written in FORTRAN77";
license = stdenv.lib.licenses.gpl3;
homepage = https://www.nikhef.nl/~h24/qcdnum/index.html;
platforms = stdenv.lib.platforms.unix;
maintainers = with stdenv.lib.maintainers; [ veprbl ];
};
}