summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--var/spack/repos/builtin/packages/py-onnx-runtime/libiconv-1.10.patch40
-rw-r--r--var/spack/repos/builtin/packages/py-onnx-runtime/package.py3
-rw-r--r--var/spack/repos/builtin/packages/py-onnxmltools/package.py1
3 files changed, 44 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/py-onnx-runtime/libiconv-1.10.patch b/var/spack/repos/builtin/packages/py-onnx-runtime/libiconv-1.10.patch
new file mode 100644
index 0000000000..446f263ebd
--- /dev/null
+++ b/var/spack/repos/builtin/packages/py-onnx-runtime/libiconv-1.10.patch
@@ -0,0 +1,40 @@
+--- cmake/onnxruntime.cmake.orig 2022-10-07 16:39:05.935164330 +0200
++++ cmake/onnxruntime.cmake 2022-10-07 16:39:56.702750071 +0200
+@@ -195,6 +195,7 @@
+ target_link_libraries(onnxruntime PRIVATE
+ ${onnxruntime_INTERNAL_LIBRARIES}
+ ${onnxruntime_EXTERNAL_LIBRARIES}
++ -liconv
+ )
+
+ set_property(TARGET onnxruntime APPEND_STRING PROPERTY LINK_FLAGS ${ONNXRUNTIME_SO_LINK_FLAG} ${onnxruntime_DELAYLOAD_FLAGS})
+--- cmake/onnxruntime_python.cmake.orig 2022-10-07 16:40:36.134428297 +0200
++++ cmake/onnxruntime_python.cmake 2022-10-07 16:40:46.916340311 +0200
+@@ -156,6 +156,7 @@
+ onnxruntime_common
+ onnxruntime_flatbuffers
+ ${pybind11_lib}
++ -liconv
+ )
+
+ if (onnxruntime_ENABLE_LANGUAGE_INTEROP_OPS)
+--- cmake/onnxruntime_unittests.cmake.orig 2022-10-07 16:41:33.413960900 +0200
++++ cmake/onnxruntime_unittests.cmake 2022-10-07 16:42:35.780451977 +0200
+@@ -664,7 +664,7 @@
+ SOURCES ${all_tests} ${onnxruntime_unittest_main_src}
+ LIBS
+ onnx_test_runner_common ${onnxruntime_test_providers_libs} ${onnxruntime_test_common_libs}
+- onnx_test_data_proto nlohmann_json::nlohmann_json
++ onnx_test_data_proto nlohmann_json::nlohmann_json -liconv
+ DEPENDS ${all_dependencies}
+ )
+ if(NOT MSVC)
+@@ -790,7 +790,7 @@
+ )
+ endif()
+
+-target_link_libraries(onnx_test_runner PRIVATE onnx_test_runner_common ${GETOPT_LIB_WIDE} ${onnx_test_libs})
++target_link_libraries(onnx_test_runner PRIVATE onnx_test_runner_common ${GETOPT_LIB_WIDE} ${onnx_test_libs} -liconv)
+ target_include_directories(onnx_test_runner PRIVATE ${ONNXRUNTIME_ROOT})
+ if (onnxruntime_USE_ROCM)
+ target_include_directories(onnx_test_runner PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/amdgpu/onnxruntime ${CMAKE_CURRENT_BINARY_DIR}/amdgpu/orttraining)
diff --git a/var/spack/repos/builtin/packages/py-onnx-runtime/package.py b/var/spack/repos/builtin/packages/py-onnx-runtime/package.py
index bfc555507b..62ea531395 100644
--- a/var/spack/repos/builtin/packages/py-onnx-runtime/package.py
+++ b/var/spack/repos/builtin/packages/py-onnx-runtime/package.py
@@ -28,6 +28,8 @@ class PyOnnxRuntime(CMakePackage, PythonPackage):
depends_on("ninja", type="build")
depends_on("python", type=("build", "run"))
depends_on("protobuf")
+ # https://github.com/microsoft/onnxruntime/pull/11639
+ depends_on("protobuf@:3.19", when="@:1.11")
depends_on("py-protobuf", type=("build", "run"))
depends_on("py-setuptools", type="build")
depends_on("py-numpy@1.16.6:", type=("build", "run"))
@@ -53,6 +55,7 @@ class PyOnnxRuntime(CMakePackage, PythonPackage):
patch("cms_1_10.patch", whe="@1.10")
# https://github.com/microsoft/onnxruntime/issues/4234#issuecomment-698077636
patch("libiconv.patch", level=0, when="@1.7.2")
+ patch("libiconv-1.10.patch", level=0, when="@1.10.0")
# https://github.com/microsoft/onnxruntime/commit/de4089f8cbe0baffe56a363cc3a41595cc8f0809.patch
patch("gcc11.patch", level=1, when="@1.7.2")
diff --git a/var/spack/repos/builtin/packages/py-onnxmltools/package.py b/var/spack/repos/builtin/packages/py-onnxmltools/package.py
index 9de56463db..7d51d0248e 100644
--- a/var/spack/repos/builtin/packages/py-onnxmltools/package.py
+++ b/var/spack/repos/builtin/packages/py-onnxmltools/package.py
@@ -12,6 +12,7 @@ class PyOnnxmltools(PythonPackage):
homepage = "https://github.com/onnx/onnxmltools"
pypi = "onnxmltools/onnxmltools-1.10.0.tar.gz"
+ version("1.11.0", sha256="174b857edcc2e4c56adbc7aed5234fff6a0f51a45956eb4c05c9f842c98bfa1f")
version("1.10.0", sha256="4eb4605f18ed66553fc17438ac8cf5406d66dcc624bedd76d8067e1b08e6c75d")
depends_on("py-setuptools", type="build")