-
Notifications
You must be signed in to change notification settings - Fork 314
/
package.nix
82 lines (75 loc) · 1.58 KB
/
package.nix
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
75
76
77
78
79
80
81
82
{
boost,
cmake,
cxxopts,
eigen,
#fetchFromGitHub,
glew,
gtest,
lib,
qt6Packages,
libGL,
metis,
stdenv,
tinyxml-2,
zlib,
}:
stdenv.mkDerivation {
pname = "sofa";
version = "24.06.00";
src = lib.fileset.toSource {
root = ./.;
fileset = lib.fileset.unions [
./applications
./Authors.txt
./cmake
./CHANGELOG.md
./CMakeLists.txt
./CMakePresets.json
./examples
./extlibs
./LICENSE-LGPL.md
./package.cmake
./README.md
./scripts
./share
./Sofa
./tools
];
};
propagatedNativeBuildInputs = [
cmake
qt6Packages.wrapQtAppsHook
];
propagatedBuildInputs = [
boost
cxxopts
eigen
glew
gtest
qt6Packages.libqglviewer
qt6Packages.qtbase
libGL
metis
tinyxml-2
zlib
];
cmakeFlags = [
(lib.cmakeBool "SOFA_ALLOW_FETCH_DEPENDENCIES" false)
];
doCheck = true;
postFixup = lib.optionalString stdenv.hostPlatform.isDarwin ''
install_name_tool -change \
$out/lib/libSceneChecking.24.12.99.dylib \
$out/plugins/SceneChecking/lib/libSceneChecking.24.12.99.dylib \
$out/bin/.runSofa-24.12.99-wrapped
'';
meta = {
description = "SOFA is an open-source framework for interactive physics simulation, with emphasis on biomechanical and robotic simulations";
homepage = "https://github.com/sofa-framework/sofa";
license = lib.licenses.lgpl21Only;
maintainers = with lib.maintainers; [ nim65s ];
mainProgram = "runSofa";
platforms = lib.platforms.unix ++ lib.platforms.windows;
};
}