Skip to content

Commit

Permalink
Add nix flake
Browse files Browse the repository at this point in the history
  • Loading branch information
zebreus committed Jun 11, 2024
1 parent 4bc96c5 commit 58292b7
Show file tree
Hide file tree
Showing 2 changed files with 183 additions and 0 deletions.
117 changes: 117 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

66 changes: 66 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
{
description = "High-performance computing projects";

inputs = {
fenix = {
url = "github:nix-community/fenix";
inputs.nixpkgs.follows = "nixpkgs";
};
nixpkgs.url = "github:nixos/nixpkgs?ref=refs/heads/master";
nixpkgs-asciidoc.url = "github:zebreus/nixpkgs?ref=f1a3be7a1160cc4810c0274ab76f0fac813eb4d6";
flake-utils.url = "github:numtide/flake-utils";
};

outputs =
{
self,
nixpkgs,
flake-utils,
nixpkgs-asciidoc,
fenix,
}:
flake-utils.lib.eachDefaultSystem (
system:
with nixpkgs.legacyPackages.${system};
let
pkgs-with-asciidoc = import nixpkgs-asciidoc { inherit system; };
pkgs-fenix = fenix.packages.${system};
in
rec {

name = "high-performance-computing";
packages.default = llvmPackages_16.stdenv.mkDerivation {
name = name;
src = ./.;

buildInputs = [
llvmPackages_16.openmp
gcc12
clang_16

openmpi
gnumake
zlib
sshfs

clang-tools_16
lldb
nil

(pkgs-fenix.complete.withComponents [
"cargo"
"clippy"
"rust-src"
"rustc"
"rustfmt"
])
pkgs-fenix.rust-analyzer
python3
gnumake
cmake
protobuf
];
};
}
);
}

0 comments on commit 58292b7

Please sign in to comment.