mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-04 04:46:43 +00:00
ergoscf: init at 3.8
This commit is contained in:
parent
66f8529d91
commit
7d3b20253f
40
pkgs/applications/science/chemistry/ergoscf/default.nix
Normal file
40
pkgs/applications/science/chemistry/ergoscf/default.nix
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
{ lib, stdenv, fetchurl, blas, lapack } :
|
||||||
|
|
||||||
|
stdenv.mkDerivation rec {
|
||||||
|
pname = "ergoscf";
|
||||||
|
version = "3.8";
|
||||||
|
|
||||||
|
src = fetchurl {
|
||||||
|
url = "http://www.ergoscf.org/source/tarfiles/ergo-${version}.tar.gz";
|
||||||
|
sha256 = "1s50k2gfs3y6r5kddifn4p0wmj0yk85wm5vf9v3swm1c0h43riix";
|
||||||
|
};
|
||||||
|
|
||||||
|
buildInputs = [ blas lapack ];
|
||||||
|
|
||||||
|
patches = [ ./math-constants.patch ];
|
||||||
|
|
||||||
|
postPatch = ''
|
||||||
|
patchShebangs ./test
|
||||||
|
'';
|
||||||
|
|
||||||
|
configureFlags = [
|
||||||
|
"--enable-linalgebra-templates"
|
||||||
|
"--enable-performance"
|
||||||
|
] ++ lib.optional stdenv.isx86_64 "--enable-sse-intrinsics";
|
||||||
|
|
||||||
|
LDFLAGS = "-lblas -llapack";
|
||||||
|
|
||||||
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
|
OMP_NUM_THREADS = 2; # required for check phase
|
||||||
|
|
||||||
|
doCheck = true;
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
description = "Quantum chemistry program for large-scale self-consistent field calculations";
|
||||||
|
homepage = "http://www.ergoscf.org";
|
||||||
|
license = licenses.gpl3Plus;
|
||||||
|
maintainers = [ maintainers.markuskowa ];
|
||||||
|
platforms = platforms.linux;
|
||||||
|
};
|
||||||
|
}
|
@ -0,0 +1,19 @@
|
|||||||
|
diff --git a/source/dft/functionals.h b/source/dft/functionals.h
|
||||||
|
index fde49ba..f7a61fc 100644
|
||||||
|
--- a/source/dft/functionals.h
|
||||||
|
+++ b/source/dft/functionals.h
|
||||||
|
@@ -59,6 +59,14 @@
|
||||||
|
#define EXTERN_C
|
||||||
|
#endif
|
||||||
|
|
||||||
|
+#ifndef M_PI
|
||||||
|
+#define M_PI 3.14159265358979323846
|
||||||
|
+#endif
|
||||||
|
+
|
||||||
|
+#ifndef M_SQRT2
|
||||||
|
+#define M_SQRT2 1.41421356237309504880
|
||||||
|
+#endif
|
||||||
|
+
|
||||||
|
typedef ergo_real real;
|
||||||
|
|
||||||
|
#if defined(FUNC_PRECISION) && FUNC_PRECISION == 1
|
@ -30026,6 +30026,8 @@ in
|
|||||||
|
|
||||||
d-seams = callPackage ../applications/science/chemistry/d-seams {};
|
d-seams = callPackage ../applications/science/chemistry/d-seams {};
|
||||||
|
|
||||||
|
ergoscf = callPackage ../applications/science/chemistry/ergoscf { };
|
||||||
|
|
||||||
gwyddion = callPackage ../applications/science/chemistry/gwyddion {};
|
gwyddion = callPackage ../applications/science/chemistry/gwyddion {};
|
||||||
|
|
||||||
jmol = callPackage ../applications/science/chemistry/jmol {
|
jmol = callPackage ../applications/science/chemistry/jmol {
|
||||||
|
Loading…
Reference in New Issue
Block a user