-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathdevenv.nix
More file actions
74 lines (68 loc) · 1.25 KB
/
Copy pathdevenv.nix
File metadata and controls
74 lines (68 loc) · 1.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
{
config,
pkgs,
...
}:
{
packages = with pkgs; [
git
bashInteractive
bzip2
curl
go-task
catch2_3
clang
clang-tools
cmake
doxygen
eigen
gcc
ghostscript
gdb
graphviz
hyperfine
lcov
lldb
llvmPackages.openmp
nodejs
perf
valgrind
];
languages = {
cplusplus = {
enable = true;
};
julia = {
enable = true;
};
};
env.JULIA_PROJECT = "${config.devenv.root}/bindings/julia";
scripts.julia-bindings-check = {
description = "Build and smoke-test the Julia bindings";
exec = ''
julia --startup-file=no -e 'using Pkg; Pkg.instantiate()'
jlcxx_prefix="$(
julia --startup-file=no -e 'using CxxWrap; print(CxxWrap.prefix_path())'
)"
cmake \
-B build/julia \
-S . \
-DBUILD_JULIA_BINDINGS=ON \
-DBUILD_TESTING=OFF \
-DCMAKE_BUILD_TYPE=Debug \
-DCMAKE_PREFIX_PATH="$jlcxx_prefix"
cmake --build build/julia --target slopejll --parallel 8
julia \
--startup-file=no \
bindings/julia/smoke_test.jl \
build/julia/lib/libslopejll
'';
};
git-hooks = {
hooks = {
clang-format = {
enable = true;
};
};
};
}