39 lines
802 B
Nix
39 lines
802 B
Nix
## { stdenv, fetchgit, cmake, gfortran, pkg-config, openblas, hwloc, scotch, lapack } :
|
|
{ pkgs ? import <nixpkgs> {} }:
|
|
pkgs.stdenv.mkDerivation rec {
|
|
name = "calculix";
|
|
version = "2.22";
|
|
src = pkgs.fetchurl {
|
|
url = "http://www.dhondt.de/ccx_${version}.src.tar.bz2";
|
|
hash = "";
|
|
};
|
|
enableParallelBuilding = true;
|
|
|
|
nativeBuildInputs = with pkgs; [
|
|
gfortran
|
|
arpack
|
|
spooles
|
|
];
|
|
|
|
buildInputs = with pkgs; [
|
|
openblas
|
|
hwloc
|
|
scotch
|
|
lapack #-ilp64
|
|
python3
|
|
];
|
|
|
|
# postPatch = ''
|
|
# substituteInPlace doc/*.sh \
|
|
# --replace "#!/bin/bash" ""
|
|
# '';
|
|
|
|
configurePhase = ''
|
|
'';
|
|
|
|
buildPhase = ''
|
|
cd ./CalculiX/ccx_${version}/src
|
|
make -I ${pkgs.spooles}/include/spooles
|
|
'';
|
|
}
|