Skip to content

Commit 97a1ad0

Browse files
authored
tulip: fix build (#354236)
2 parents 0dc5bb1 + 27c93e9 commit 97a1ad0

File tree

1 file changed

+43
-13
lines changed

1 file changed

+43
-13
lines changed

pkgs/applications/science/misc/tulip/default.nix

Lines changed: 43 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,20 @@
1-
{ lib, stdenv, fetchurl, libxml2, freetype, libGLU, libGL, glew
2-
, qtbase, wrapQtAppsHook, autoPatchelfHook, python3
3-
, cmake, libjpeg, llvmPackages }:
1+
{
2+
lib,
3+
stdenv,
4+
fetchurl,
5+
libxml2,
6+
freetype,
7+
libGLU,
8+
libGL,
9+
glew,
10+
qtbase,
11+
wrapQtAppsHook,
12+
autoPatchelfHook,
13+
python3,
14+
cmake,
15+
libjpeg,
16+
llvmPackages,
17+
}:
418

519
stdenv.mkDerivation rec {
620
pname = "tulip";
@@ -11,21 +25,37 @@ stdenv.mkDerivation rec {
1125
hash = "sha256-7z21WkPi1v2AGishDmXZPAedMjgXPRnpUiHTzEnc5LY=";
1226
};
1327

14-
nativeBuildInputs = [ cmake wrapQtAppsHook ]
15-
++ lib.optionals stdenv.hostPlatform.isLinux [ autoPatchelfHook ];
28+
nativeBuildInputs = [
29+
cmake
30+
wrapQtAppsHook
31+
] ++ lib.optionals stdenv.hostPlatform.isLinux [ autoPatchelfHook ];
1632

17-
buildInputs = [ libxml2 freetype glew libjpeg qtbase python3 ]
33+
buildInputs =
34+
[
35+
libxml2
36+
freetype
37+
glew
38+
libjpeg
39+
qtbase
40+
python3
41+
]
1842
++ lib.optionals stdenv.hostPlatform.isDarwin [ llvmPackages.openmp ]
19-
++ lib.optionals stdenv.hostPlatform.isLinux [ libGLU libGL ];
43+
++ lib.optionals stdenv.hostPlatform.isLinux [
44+
libGLU
45+
libGL
46+
];
2047

2148
qtWrapperArgs = [ ''--prefix PATH : ${lib.makeBinPath [ python3 ]}'' ];
2249

23-
env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.hostPlatform.isDarwin (toString [
24-
# fatal error: 'Python.h' file not found
25-
"-I${python3}/include/${python3.libPrefix}"
26-
# error: format string is not a string literal (potentially insecure)
27-
"-Wno-format-security"
28-
]);
50+
env.NIX_CFLAGS_COMPILE =
51+
# error: invalid conversion from 'unsigned char*' to 'char*'
52+
"-fpermissive "
53+
+ (lib.optionalString stdenv.hostPlatform.isDarwin (toString [
54+
# fatal error: 'Python.h' file not found
55+
"-I${python3}/include/${python3.libPrefix}"
56+
# error: format string is not a string literal (potentially insecure)
57+
"-Wno-format-security"
58+
]));
2959

3060
# FIXME: "make check" needs Docbook's DTD 4.4, among other things.
3161
doCheck = false;

0 commit comments

Comments
 (0)