2020-04-24 23:36:52 +00:00
|
|
|
{ stdenv, fetchurl, gfortran, arpack, spooles, blas, lapack }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "calculix";
|
2020-09-25 04:45:31 +00:00
|
|
|
version = "2.17";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://www.dhondt.de/ccx_${version}.src.tar.bz2";
|
2020-09-25 04:45:31 +00:00
|
|
|
sha256 = "0l3fizxfdj2mpdp62wnk9v47q2yc3cy39fpsm629z7bjmba8lw6a";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ gfortran ];
|
|
|
|
|
|
|
|
buildInputs = [ arpack spooles blas lapack ];
|
|
|
|
|
|
|
|
NIX_CFLAGS_COMPILE = "-I${spooles}/include/spooles";
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
./calculix.patch
|
|
|
|
];
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
cd ccx*/src
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
install -Dm0755 ccx_${version} $out/bin/ccx
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
homepage = "http://www.calculix.de/";
|
|
|
|
description = "Three-dimensional structural finite element program";
|
|
|
|
license = licenses.gpl2Plus;
|
|
|
|
maintainers = with maintainers; [ gebner ];
|
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|