-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ONNXRuntime JAVA JNI build failure #4755
Comments
What version of Gradle do you have installed? |
@Craigacp see transcript below it is Gradle 4.9 gradle --version Gradle 4.9Build time: 2018-07-16 08:14:03 UTC Kotlin DSL: 0.18.4 |
As noted in the build docs you need gradle 6.1 or newer to build it. |
gradle -v Gradle 6.6Build time: 2020-08-10 22:06:19 UTC Kotlin: 1.3.72 |
@Craigacp see test results. 7: > Task :compileTestJava 100% tests passed, 0 tests failed out of 7 Total Test time (real) = 50.66 sec |
Describe the bug
A clear and concise description of what the bug is.
The problem is that the build for the java JNI run time is failing.
I used the instructions from ./java/README.txt
Building
Use the main project's build instructions with the
--build_java
option.System information
To Reproduce
./build.sh --config RelWithDebInfo --build_shared_lib --parallel --build_java
(venv) (base) MacBook-Pro:~/onnxruntime quantum-fusion$ ./build.sh --config RelWithDebInfo --build_shared_lib --parallel --build_java
2020-08-11 06:11:39,314 Build [DEBUG] - Defaulting to running update, build [and test for native builds].
2020-08-11 06:11:39,315 Build [INFO] - Build started
2020-08-11 06:11:39,315 Build [DEBUG] - Running subprocess in '/Users/hottelet/onnxruntime'
['git', 'submodule', 'sync', '--recursive']
Synchronizing submodule url for 'cmake/external/FeaturizersLibrary'
Synchronizing submodule url for 'cmake/external/FeaturizersLibrary/src/3rdParty/eigen'
Synchronizing submodule url for 'cmake/external/FeaturizersLibrary/src/3rdParty/re2'
Synchronizing submodule url for 'cmake/external/SafeInt/safeint'
Synchronizing submodule url for 'cmake/external/cub'
Synchronizing submodule url for 'cmake/external/cxxopts'
Synchronizing submodule url for 'cmake/external/date'
Synchronizing submodule url for 'cmake/external/eigen'
Synchronizing submodule url for 'cmake/external/gemmlowp'
Synchronizing submodule url for 'cmake/external/googletest'
Synchronizing submodule url for 'cmake/external/horovod'
Synchronizing submodule url for 'cmake/external/horovod/third_party/HTTPRequest'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/assert'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/config'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/core'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/detail'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/iterator'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/lockfree'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/mpl'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/parameter'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/predef'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/preprocessor'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/static_assert'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/type_traits'
Synchronizing submodule url for 'cmake/external/horovod/third_party/boost/utility'
Synchronizing submodule url for 'cmake/external/horovod/third_party/eigen'
Synchronizing submodule url for 'cmake/external/horovod/third_party/flatbuffers'
Synchronizing submodule url for 'cmake/external/horovod/third_party/gloo'
Synchronizing submodule url for 'cmake/external/horovod/third_party/lbfgs'
Synchronizing submodule url for 'cmake/external/json'
Synchronizing submodule url for 'cmake/external/libprotobuf-mutator'
Synchronizing submodule url for 'cmake/external/mimalloc'
Synchronizing submodule url for 'cmake/external/nsync'
Synchronizing submodule url for 'cmake/external/onnx'
Synchronizing submodule url for 'cmake/external/onnx/third_party/benchmark'
Synchronizing submodule url for 'cmake/external/onnx/third_party/pybind11'
Synchronizing submodule url for 'cmake/external/onnx/third_party/pybind11/tools/clang'
Synchronizing submodule url for 'cmake/external/onnx-tensorrt'
Synchronizing submodule url for 'cmake/external/onnx-tensorrt/third_party/onnx'
Synchronizing submodule url for 'cmake/external/onnx-tensorrt/third_party/onnx/third_party/benchmark'
Synchronizing submodule url for 'cmake/external/onnx-tensorrt/third_party/onnx/third_party/pybind11'
Synchronizing submodule url for 'cmake/external/onnx-tensorrt/third_party/onnx/third_party/pybind11/tools/clang'
Synchronizing submodule url for 'cmake/external/protobuf'
Synchronizing submodule url for 'cmake/external/protobuf/third_party/benchmark'
Synchronizing submodule url for 'cmake/external/protobuf/third_party/googletest'
Synchronizing submodule url for 'cmake/external/re2'
Synchronizing submodule url for 'cmake/external/tensorboard'
Synchronizing submodule url for 'cmake/external/tvm'
Synchronizing submodule url for 'cmake/external/tvm/3rdparty/HalideIR'
Synchronizing submodule url for 'cmake/external/tvm/3rdparty/dlpack'
Synchronizing submodule url for 'cmake/external/tvm/3rdparty/dmlc-core'
Synchronizing submodule url for 'cmake/external/tvm/3rdparty/rang'
Synchronizing submodule url for 'cmake/external/wil'
Synchronizing submodule url for 'server/external/spdlog'
2020-08-11 06:11:40,885 Build [DEBUG] - Subprocess completed. Return code=0
2020-08-11 06:11:40,885 Build [DEBUG] - Running subprocess in '/Users/hottelet/onnxruntime'
['git', 'submodule', 'update', '--init', '--recursive']
2020-08-11 06:11:46,857 Build [DEBUG] - Subprocess completed. Return code=0
2020-08-11 06:11:46,857 Build [INFO] - Generating CMake build tree
2020-08-11 06:11:46,857 Build [DEBUG] - Running subprocess in '/Users/hottelet/onnxruntime/build/Linux/RelWithDebInfo'
['/usr/local/Cellar/cmake/3.17.0_1/bin/cmake', '/Users/hottelet/onnxruntime/cmake', '-Donnxruntime_RUN_ONNX_TESTS=OFF', '-Donnxruntime_BUILD_WINML_TESTS=ON', '-Donnxruntime_GENERATE_TEST_REPORTS=ON', '-Donnxruntime_DEV_MODE=ON', '-DPYTHON_EXECUTABLE=/Users/hottelet/venv/bin/python3', '-Donnxruntime_USE_CUDA=OFF', '-Donnxruntime_CUDNN_HOME=', '-Donnxruntime_USE_FEATURIZERS=OFF', '-Donnxruntime_CUDA_HOME=', '-Donnxruntime_USE_JEMALLOC=OFF', '-Donnxruntime_USE_MIMALLOC_STL_ALLOCATOR=OFF', '-Donnxruntime_USE_MIMALLOC_ARENA_ALLOCATOR=OFF', '-Donnxruntime_ENABLE_PYTHON=OFF', '-Donnxruntime_BUILD_CSHARP=OFF', '-Donnxruntime_BUILD_JAVA=ON', '-Donnxruntime_BUILD_NODEJS=OFF', '-Donnxruntime_BUILD_SHARED_LIB=ON', '-Donnxruntime_USE_EIGEN_FOR_BLAS=ON', '-Donnxruntime_USE_OPENBLAS=OFF', '-Donnxruntime_USE_DNNL=OFF', '-Donnxruntime_USE_MKLML=OFF', '-Donnxruntime_USE_NGRAPH=OFF', '-Donnxruntime_USE_OPENVINO=OFF', '-Donnxruntime_USE_OPENVINO_MYRIAD=OFF', '-Donnxruntime_USE_OPENVINO_GPU_FP32=OFF', '-Donnxruntime_USE_OPENVINO_GPU_FP16=OFF', '-Donnxruntime_USE_OPENVINO_CPU_FP32=OFF', '-Donnxruntime_USE_OPENVINO_VAD_M=OFF', '-Donnxruntime_USE_OPENVINO_VAD_F=OFF', '-Donnxruntime_USE_OPENVINO_BINARY=OFF', '-Donnxruntime_USE_NNAPI_BUILTIN=OFF', '-Donnxruntime_USE_RKNPU=OFF', '-Donnxruntime_USE_OPENMP=OFF', '-Donnxruntime_USE_TVM=OFF', '-Donnxruntime_USE_LLVM=OFF', '-Donnxruntime_ENABLE_MICROSOFT_INTERNAL=OFF', '-Donnxruntime_USE_VITISAI=OFF', '-Donnxruntime_USE_NUPHAR=OFF', '-Donnxruntime_USE_TENSORRT=OFF', '-Donnxruntime_TENSORRT_HOME=', '-Donnxruntime_USE_MIGRAPHX=OFF', '-Donnxruntime_MIGRAPHX_HOME=', '-Donnxruntime_CROSS_COMPILING=OFF', '-Donnxruntime_DISABLE_CONTRIB_OPS=OFF', '-Donnxruntime_DISABLE_ML_OPS=OFF', '-Donnxruntime_DISABLE_RTTI=OFF', '-Donnxruntime_MSVC_STATIC_RUNTIME=OFF', '-Donnxruntime_ENABLE_LANGUAGE_INTEROP_OPS=OFF', '-Donnxruntime_USE_DML=OFF', '-Donnxruntime_USE_WINML=OFF', '-Donnxruntime_BUILD_FOR_WINDOWS_STORE=OFF', '-Donnxruntime_USE_TELEMETRY=OFF', '-Donnxruntime_ENABLE_LTO=OFF', '-Donnxruntime_USE_ACL=OFF', '-Donnxruntime_USE_ACL_1902=OFF', '-Donnxruntime_USE_ACL_1905=OFF', '-Donnxruntime_USE_ACL_1908=OFF', '-Donnxruntime_USE_ARMNN=OFF', '-Donnxruntime_ARMNN_RELU_USE_CPU=ON', '-Donnxruntime_ARMNN_BN_USE_CPU=ON', '-Donnxruntime_ENABLE_NVTX_PROFILE=OFF', '-Donnxruntime_ENABLE_TRAINING=OFF', '-Donnxruntime_USE_HOROVOD=OFF', '-Donnxruntime_BUILD_BENCHMARKS=OFF', '-Donnxruntime_PYBIND_EXPORT_OPSCHEMA=OFF', '-Donnxruntime_ENABLE_MEMLEAK_CHECKER=OFF', '-DCMAKE_BUILD_TYPE=RelWithDebInfo']
Adding flags for Mac builds
Use gtest from submodule
-- Found PythonInterp: /Users/hottelet/venv/bin/python3 (found version "3.8.3")
-- Found PythonInterp: /Users/hottelet/venv/bin/python3 (found suitable version "3.8.3", minimum required is "3.4")
Use protobuf from submodule
-- 3.11.3.0
-- Java Build is enabled
-- Using gradle: /usr/local/bin/gradle
-- Running Java tests
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/hottelet/onnxruntime/build/Linux/RelWithDebInfo
2020-08-11 06:11:49,416 Build [DEBUG] - Subprocess completed. Return code=0
2020-08-11 06:11:49,416 Build [INFO] - Building targets for RelWithDebInfo configuration
2020-08-11 06:11:49,417 Build [DEBUG] - Running subprocess in '/Users/hottelet/onnxruntime'
['/usr/local/Cellar/cmake/3.17.0_1/bin/cmake', '--build', '/Users/hottelet/onnxruntime/build/Linux/RelWithDebInfo', '--config', 'RelWithDebInfo', '--', '-j16']
Scanning dependencies of target pep8_check
Checking python scripts for PEP8 conformance using flake8
[ 0%] Built target onnxruntime_generate_def
[ 0%] Built target gtest
[ 1%] Generating /Users/hottelet/onnxruntime/java/build/libs/onnxruntime.jar
[ 1%] Built target onnxruntime_mocked_allocator
[ 2%] Built target custom_op_library
[ 3%] Built target re2
[ 10%] Built target libprotobuf-lite
[ 11%] Built target onnxruntime_mlas
[ 15%] Built target nsync_cpp
[ 23%] Built target libprotobuf
[ 23%] Built target gmock
[ 33%] Built target libprotoc
[ 33%] Built target protoc
[ 34%] Built target onnx_proto
Scanning dependencies of target onnx_test_data_proto
Scanning dependencies of target onnxruntime_util
Scanning dependencies of target onnxruntime_common
Scanning dependencies of target onnxruntime_session
Scanning dependencies of target onnxruntime_test_utils
Scanning dependencies of target onnxruntime_graph
Scanning dependencies of target onnxruntime_optimizer
Scanning dependencies of target onnxruntime_framework
[ 34%] Building CXX object CMakeFiles/onnx_test_data_proto.dir/tml.pb.cc.o
[ 34%] Building CXX object onnx/CMakeFiles/onnx.dir//external/onnx/onnx/checker.cc.o
[ 34%] Building CXX object onnx/CMakeFiles/onnx.dir//external/onnx/onnx/common/assertions.cc.o
[ 35%] Building CXX object onnx/CMakeFiles/onnx.dir//external/onnx/onnx/common/interned_strings.cc.o
[ 35%] Building CXX object onnx/CMakeFiles/onnx.dir//external/onnx/onnx/common/ir_pb_converter.cc.o
[ 35%] Building CXX object CMakeFiles/onnxruntime_test_utils.dir/Users/hottelet/onnxruntime/onnxruntime/test/util/compare_ortvalue.cc.o
[ 35%] Building CXX object onnx/CMakeFiles/onnx.dir//external/onnx/onnx/common/status.cc.o
[ 35%] Building CXX object onnx/CMakeFiles/onnx.dir//external/onnx/onnx/common/model_helpers.cc.o
[ 35%] Building CXX object CMakeFiles/onnxruntime_common.dir/Users/hottelet/onnxruntime/onnxruntime/core/common/cpuid_info.cc.o
[ 35%] Building CXX object CMakeFiles/onnxruntime_util.dir/Users/hottelet/onnxruntime/onnxruntime/core/profile/profile.cc.o
[ 35%] Building CXX object CMakeFiles/onnxruntime_graph.dir/Users/hottelet/onnxruntime/onnxruntime/core/graph/contrib_ops/attn_lstm_schema_defs.cc.o
[ 35%] Building CXX object CMakeFiles/onnxruntime_session.dir/Users/hottelet/onnxruntime/onnxruntime/core/session/IOBinding.cc.o
[ 35%] Building CXX object CMakeFiles/onnxruntime_optimizer.dir/Users/hottelet/onnxruntime/onnxruntime/core/optimizer/attention_fusion.cc.o
[ 35%] Building CXX object CMakeFiles/onnxruntime_framework.dir/Users/hottelet/onnxruntime/onnxruntime/core/framework/allocation_planner.cc.o
[ 35%] Building CXX object CMakeFiles/onnxruntime_util.dir/Users/hottelet/onnxruntime/onnxruntime/core/util/gemmlowp_common.cc.o
FAILURE: Build failed with an exception.
Where:
Build file '/Users/hottelet/onnxruntime/java/build.gradle' line: 32
What went wrong:
A problem occurred evaluating root project 'onnxruntime'.
Additional context
Add any other context about the problem here. If the issue is about a particular model, please share the model details as well to facilitate debugging.
The text was updated successfully, but these errors were encountered: