pythonPackages.pythonocc-core: Fix building on darwin
This commit is contained in:
committed by
Jonathan Ringer
parent
256ae8cfe0
commit
cce62f7b21
@@ -1,5 +1,6 @@
|
||||
{ stdenv, python, fetchFromGitHub, cmake, swig, ninja,
|
||||
opencascade, smesh, freetype, libGL, libGLU, libX11 }:
|
||||
{ stdenv, python, fetchFromGitHub, cmake, swig, ninja
|
||||
, opencascade, smesh, freetype, libGL, libGLU, libX11
|
||||
, Cocoa }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "pythonocc-core";
|
||||
@@ -12,11 +13,17 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "1jk4y7f75z9lyawffpfkr50qw5452xzi1imcdlw9pdvf4i0y86k3";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake swig ninja ];
|
||||
postPatch = ''
|
||||
substituteInPlace CMakeLists.txt \
|
||||
--replace "/usr/X11R6/lib/libGL.dylib" "${libGL}/lib/libGL.dylib" \
|
||||
--replace "/usr/X11R6/lib/libGLU.dylib" "${libGLU}/lib/libGLU.dylib"
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [ cmake swig ];
|
||||
buildInputs = [
|
||||
python opencascade smesh
|
||||
freetype libGL libGLU libX11
|
||||
];
|
||||
] ++ stdenv.lib.optionals stdenv.isDarwin [ Cocoa ];
|
||||
|
||||
cmakeFlags = [
|
||||
"-Wno-dev"
|
||||
|
||||
Reference in New Issue
Block a user