@@ -52,45 +52,13 @@ macro(mlir_configure_python_dev_packages)
5252 find_package (nanobind 2.9 CONFIG REQUIRED)
5353 else ()
5454 include (FetchContent)
55- # # nanobind uses tsl-robin-map and since we're not using GIT for nanobind we need to
56- # # get tsl-robin-map manually too.
57- # FetchContent_Declare(
58- # tsl-robin-map
59- # OVERRIDE_FIND_PACKAGE
60- # # timestamp the files with the extraction time instead of archive time
61- # DOWNLOAD_EXTRACT_TIMESTAMP FALSE
62- # URL https://github.com/Tessil/robin-map/archive/refs/tags/v1.4.0.tar.gz
63- # # put this last otherwise windows parses everything after the hash as part of the hash???
64- # URL_HASH MD5=d56a879c94e021c55d8956e37deb3e4f
65- # )
66- # FetchContent_MakeAvailable(tsl-robin-map)
67- # # Tell nanobind to use find_project(tsl-robin-map) instead of searching its
68- # # submodule folder.
69- # set(NB_USE_SUBMODULE_DEPS OFF CACHE INTERNAL "Switch off Nanobind submodule deps")
70- # FetchContent_Declare(
71- # nanobind
72- # OVERRIDE_FIND_PACKAGE
73- # # timestamp the files with the extraction time instead of archive time
74- # DOWNLOAD_EXTRACT_TIMESTAMP FALSE
75- # URL https://github.com/wjakob/nanobind/archive/refs/tags/v2.9.0.tar.gz
76- # # put this last otherwise windows parses everything after the hash as part of the hash???
77- # URL_HASH MD5=df0e9de9d5fd817df264584be4917fd0
78- # )
79- # FetchContent_MakeAvailable(nanobind)
8055 FetchContent_Declare(
8156 nanobind
8257 GIT_REPOSITORY https://github.com/wjakob/nanobind.git
8358 GIT_TAG v2.9.0
8459 GIT_SHALLOW TRUE
85- OVERRIDE_FIND_PACKAGE
8660 )
8761 FetchContent_MakeAvailable(nanobind)
88- if (CMAKE_VERSION VERSION_LESS "3.24.0" )
89- # OVERRIDE_FIND_PACKAGE not implemented so have to set the dirs manually.
90- set (nanobind_DIR "${nanobind_SOURCE_DIR} /cmake" CACHE INTERNAL "" )
91- endif ()
92- # no PACKAGE_VERSION in this path but we know it's 2.9 of course.
93- find_package (nanobind CONFIG REQUIRED)
9462 endif ()
9563 message (STATUS "Found nanobind: ${NB_DIR} " )
9664 endif ()
0 commit comments