initial push
This commit is contained in:
commit
41ef462f0c
|
@ -0,0 +1,27 @@
|
|||
{
|
||||
"nodes": {
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1723637854,
|
||||
"narHash": "sha256-med8+5DSWa2UnOqtdICndjDAEjxr5D7zaIiK4pn0Q7c=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "c3aa7b8938b17aebd2deecf7be0636000d62a2b9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nixos",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
|
@ -0,0 +1,46 @@
|
|||
{
|
||||
description = "A very basic flake";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, ... }:
|
||||
let
|
||||
system = "x86_64-linux";
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
scotch = pkgs.scotch.overrideAttrs (finalAttrs: previousAttrs: {
|
||||
cmakeFlags = [ "-DINTSIZE=64 -DBUILD_SHARED_LIBS=ON" ];
|
||||
});
|
||||
# hwloc = pkgs.hwloc.overrideAttrs (finalAttrs: previousAttrs: {
|
||||
# configureFlags = [ "--localstatedir=/var" "--enable-netloc" --"" ];
|
||||
# });
|
||||
starpu = pkgs.callPackage ./package-starpu.nix { };
|
||||
#starpu-static = pkgs.pkgsStatic.callPackage ./package-starpu.nix { };
|
||||
pastix = pkgs.callPackage ./package-pastix.nix { };
|
||||
pastix-static = pkgs.pkgsStatic.callPackage ./package-pastix.nix { };
|
||||
|
||||
in {
|
||||
devShells.${system}.default = pkgs.mkShell {
|
||||
buildInputs = [
|
||||
pkgs.autoconf
|
||||
pkgs.automake
|
||||
pkgs.cmake
|
||||
pkgs.gfortran
|
||||
pkgs.pkg-config
|
||||
pkgs.libtool
|
||||
pkgs.blas-ilp64
|
||||
pkgs.hwloc
|
||||
scotch
|
||||
pkgs.lapack-ilp64
|
||||
pkgs.arpack
|
||||
pkgs.spooles
|
||||
pkgs.python3
|
||||
pkgs.gdb
|
||||
starpu
|
||||
pastix
|
||||
];
|
||||
};
|
||||
# starpu = pkgs.callPackage ./package-starpu.nix { };
|
||||
};
|
||||
}
|
|
@ -0,0 +1,38 @@
|
|||
## { 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
|
||||
'';
|
||||
}
|
|
@ -0,0 +1,60 @@
|
|||
#{ stdenv, fetchgit, cmake, gfortran, pkg-config, openblas, hwloc, scotch, lapack } :
|
||||
{ pkgs ? import <nixpkgs> {} }:
|
||||
pkgs.stdenv.mkDerivation rec {
|
||||
name = "pastix";
|
||||
version = "6.4.0";
|
||||
src = pkgs.fetchgit {
|
||||
url = "https://gitlab.inria.fr/solverstack/${name}";
|
||||
rev = "v${version}";
|
||||
fetchSubmodules = true;
|
||||
hash = "sha256-dbxGIRUSUQPTdGnYE+Lj+MX+/oGVOFhU4uu43LZuavY=";
|
||||
};
|
||||
enableParallelBuilding = true;
|
||||
|
||||
nativeBuildInputs = with pkgs; [
|
||||
cmake
|
||||
pkg-config
|
||||
gfortran
|
||||
];
|
||||
|
||||
scotch = pkgs.scotch.overrideAttrs (finalAttrs: previousAttrs: {
|
||||
cmakeFlags = [ "-DINTSIZE=64 -DBUILD_SHARED_LIBS=ON" ];
|
||||
});
|
||||
starpu = pkgs.callPackage ./package-starpu.nix { };
|
||||
|
||||
buildInputs = [
|
||||
pkgs.openblas
|
||||
pkgs.hwloc
|
||||
scotch
|
||||
starpu
|
||||
pkgs.lapack-ilp64
|
||||
pkgs.python3
|
||||
];
|
||||
|
||||
# postPatch = ''
|
||||
# substituteInPlace doc/*.sh \
|
||||
# --replace "#!/bin/bash" ""
|
||||
# '';
|
||||
|
||||
configurePhase = ''
|
||||
cmake \
|
||||
-B ./build \
|
||||
-DCMAKE_INSTALL_PREFIX=$out \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DPASTIX_WITH_STARPU=ON \
|
||||
-DPASTIX_WITH_CUDA=OFF \
|
||||
-DPASTIX_ORDERING_SCOTCH=ON \
|
||||
-DPASTIX_INT64=ON \
|
||||
-DPASTIX_WITH_MPI=OFF \
|
||||
-DCMAKE_C_COMPILER=gcc \
|
||||
-DCMAKE_CXX_COMPILER=g++ \
|
||||
-DCMAKE_Fortran_COMPILER=gfortran \
|
||||
-DCMAKE_C_FLAGS="-fopenmp" \
|
||||
.
|
||||
'';
|
||||
|
||||
buildPhase = ''
|
||||
cd ./build
|
||||
make
|
||||
'';
|
||||
}
|
|
@ -0,0 +1,53 @@
|
|||
{ stdenv, fetchFromGitLab, autoconf, automake, pkg-config, libtool, openblas, hwloc } :
|
||||
stdenv.mkDerivation rec {
|
||||
name = "starpu";
|
||||
version = "1.4.7";
|
||||
src = fetchFromGitLab {
|
||||
repo = "${name}";
|
||||
domain = "gitlab.inria.fr";
|
||||
owner = "${name}";
|
||||
rev = "${name}-${version}";
|
||||
hash = "sha256-bYKfVB4oUFQPuwiJ/qFHXfLcKYHm2wCE53itIqCe7pM=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
autoconf
|
||||
automake
|
||||
pkg-config
|
||||
libtool
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
openblas
|
||||
hwloc
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace doc/*.sh \
|
||||
--replace "#!/bin/bash" ""
|
||||
'';
|
||||
|
||||
configurePhase = ''
|
||||
./autogen.sh
|
||||
./configure \
|
||||
--prefix=$out \
|
||||
--disable-build-doc \
|
||||
--disable-build-doc-pdf \
|
||||
--disable-build-examples \
|
||||
--enable-build-tests \
|
||||
--disable-cuda \
|
||||
--disable-fortran \
|
||||
--disable-mpi \
|
||||
--disable-opencl \
|
||||
--disable-socl \
|
||||
--disable-starpufft \
|
||||
--disable-starpupy \
|
||||
--enable-blas-lib=openblas \
|
||||
--enable-cpu \
|
||||
--enable-maxbuffers=16 \
|
||||
--enable-maxcpus=16 \
|
||||
--enable-openmp \
|
||||
--with-pic \
|
||||
--with-hwloc
|
||||
'';
|
||||
}
|
Loading…
Reference in New Issue