Files
nixpkgs/pkgs/development/python-modules/mlx/dont-fetch-nanobind.patch

20 lines
564 B
Diff

diff --git a/CMakeLists.txt b/CMakeLists.txt
index a2395d02..6d24df02 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -354,13 +354,7 @@ if(MLX_BUILD_PYTHON_BINDINGS)
Python 3.10
COMPONENTS Interpreter Development.Module
REQUIRED)
- FetchContent_Declare(
- nanobind
- GIT_REPOSITORY https://github.com/wjakob/nanobind.git
- GIT_TAG v2.12.0
- GIT_SHALLOW TRUE
- EXCLUDE_FROM_ALL)
- FetchContent_MakeAvailable(nanobind)
+ find_package(nanobind CONFIG REQUIRED)
add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/python/src)
endif()