mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-20 11:53:51 +00:00
python3.pkgs.laszip: fix how cmake and ninja dependencies are consumed
This commit is contained in:
parent
6258bfda13
commit
a967c0f741
@ -2,17 +2,18 @@
|
||||
, stdenv
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, scikit-build-core
|
||||
, pybind11
|
||||
, cmake
|
||||
, LASzip
|
||||
, ninja
|
||||
, pythonOlder
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "laszip-python";
|
||||
version = "0.2.3";
|
||||
|
||||
format = "pyproject";
|
||||
|
||||
disabled = pythonOlder "3.7";
|
||||
@ -24,14 +25,25 @@ buildPythonPackage rec {
|
||||
hash = "sha256-MiPzL9TDCf1xnCv7apwdfcpkFnBRi4PO/atTQxqL8cw=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Removes depending on the cmake and ninja PyPI packages, since we can pass
|
||||
# in the tools directly, and scikit-build-core can use them.
|
||||
# https://github.com/tmontaigu/laszip-python/pull/9
|
||||
(fetchpatch {
|
||||
name = "remove-cmake-ninja-pypi-dependencies.patch";
|
||||
url = "https://github.com/tmontaigu/laszip-python/commit/17e648d04945fa2d095d6d74d58c790a4fcde84a.patch";
|
||||
hash = "sha256-k58sS1RqVzT1WPh2OVt/D4Y045ODtj6U3bUjegd44VY=";
|
||||
})
|
||||
];
|
||||
|
||||
env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.cc.isGNU "-std=c++17";
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
ninja
|
||||
pybind11
|
||||
scikit-build-core
|
||||
scikit-build-core.optional-dependencies.pyproject
|
||||
];
|
||||
] ++ scikit-build-core.optional-dependencies.pyproject;
|
||||
|
||||
dontUseCmakeConfigure = true;
|
||||
|
||||
|
@ -5790,7 +5790,9 @@ self: super: with self; {
|
||||
|
||||
laspy = callPackage ../development/python-modules/laspy { };
|
||||
|
||||
laszip = callPackage ../development/python-modules/laszip { };
|
||||
laszip = callPackage ../development/python-modules/laszip {
|
||||
inherit (pkgs) cmake ninja;
|
||||
};
|
||||
|
||||
latex2mathml = callPackage ../development/python-modules/latex2mathml { };
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user