diff --git a/pkgs/development/python-modules/pybind11/default.nix b/pkgs/development/python-modules/pybind11/default.nix index 94a25b2858e..2df360dfaab 100644 --- a/pkgs/development/python-modules/pybind11/default.nix +++ b/pkgs/development/python-modules/pybind11/default.nix @@ -23,7 +23,8 @@ buildPythonPackage rec { dontUseCmakeConfigure = true; - checkInputs = [ pytest cmake ] + nativeBuildInputs = [ cmake ]; + checkInputs = [ pytest ] ++ (lib.optional (numpy != null) numpy) ++ (lib.optional (eigen != null) eigen) ++ (lib.optional (scipy != null) scipy); @@ -32,6 +33,11 @@ buildPythonPackage rec { make -j $NIX_BUILD_CORES pytest ''; + # re-expose the headers to other packages + postInstall = '' + ln -s $out/include/python${python.pythonVersion}m/pybind11/ $out/include/pybind11 + ''; + meta = { homepage = https://github.com/pybind/pybind11; description = "Seamless operability between C++11 and Python";