homuler / MediaPipeUnityPlugin

Unity plugin to run MediaPipe
MIT License
1.83k stars 465 forks source link

An error occurred when executing Execute python build.py build --desktop cpu -v #1218

Closed Daniel70-liu closed 4 months ago

Daniel70-liu commented 4 months ago

Plugin Version or Commit ID

v0.14.4

Unity Version

2021.6.6f1

Your Host OS

window home version

Target Platform

Windows Standalone

[Windows Only] Visual Studio C++ and Windows SDK Version

Visual Studio 2019 BuildTools : 14.29.30133 , winsdk: 10.0.19041.0 , bazel :7.2.1

[Linux Only] GCC/G++ and GLIBC Version

No response

[Android Only] Android Build Tools and NDK Version

No response

[iOS Only] XCode Version

No response

Command Sequences

(mediapipe) C:\MediaPipeUnityPlugin>python build.py build --desktop cpu -v

Log

C:\MediaPipeUnityPlugin>activate mediapipe

(mediapipe) C:\MediaPipeUnityPlugin>bazel clean --expunge Extracting Bazel installation... Starting local Bazel server and connecting to it... INFO: Starting clean . (mediapipe) C:\MediaPipeUnityPlugin>python build.py build --desktop cpu -v INFO (build.py): Building protobuf sources... DEBUG (build.py): Running bazel --output_user_root C:/_bzl build -c opt --action_env PYTHON_BIN_PATH="C://anaconda2022//envs//mediapipe//python.exe" --action_env ProgramData --action_env PROCESSOR_ARCHITECTURE --action_env PROCESSOR_IDENTIFIER --action_env PROCESSOR_LEVEL --action_env PROCESSOR_REVISION //mediapipe_api:mediapipe_proto_srcs Extracting Bazel installation... Starting local Bazel server and connecting to it... DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'com_google_absl' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'com_google_benchmark' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'flatbuffers' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'XNNPACK' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'pthreadpool' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'cpuinfo' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'com_googlesource_code_re2' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'com_google_protobuf' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'com_google_googletest' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'com_github_gflags_gflags' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'zlib' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'build_bazel_rules_apple' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'build_bazel_rules_swift' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'build_bazel_apple_support' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'xctestrunner' because it already exists. DEBUG: C:/_bzl/kwr2wusf/external/org_tensorflow/third_party/repo.bzl:132:14: Warning: skipping import of repository 'com_github_glog_glog' because it already exists. ERROR: Traceback (most recent call last): File "C:/_bzl/kwr2wusf/external/build_bazel_rules_apple/apple/internal/rule_support.bzl", line 217, column 36, in deps_cfg = apple_common.multi_arch_split, Error: 'apple_common' value has no field or method 'multi_arch_split' ERROR: error loading package '@@mediapipe//mediapipe/gpu': at C:/_bzl/kwr2wusf/external/build_bazel_rules_apple/apple/ios.bzl:33:5: at C:/_bzl/kwr2wusf/external/build_bazel_rules_apple/apple/internal/ios_rules.bzl:75:5: initialization of module 'apple/internal/rule_support.bzl' failed ERROR: C:/mediapipeunityplugin/mediapipe_api/tasks/cc/vision/hand_detector/proto/BUILD:20:17: error loading package '@@mediapipe//mediapipe/gpu': at C:/_bzl/kwr2wusf/external/build_bazel_rules_apple/apple/ios.bzl:33:5: at C:/_bzl/kwr2wusf/external/build_bazel_rules_apple/apple/internal/ios_rules.bzl:75:5: initialization of module 'apple/internal/rule_support.bzl' failed and referenced by '//mediapipe_api/tasks/cc/vision/hand_detector/proto:hand_detector_graph_options_cs' ERROR: Analysis of target '//mediapipe_api:mediapipe_proto_srcs' failed; build aborted: Analysis failed INFO: Elapsed time: 349.244s, Critical Path: 0.10s INFO: 1 process: 1 internal. ERROR: Build did NOT complete successfully FAILED: Fetching repository @@com_google_protobuf; starting 5s Fetching repository @@npm; starting 4s Fetching repository @@yarn; starting 4s Fetching C:/_bzl/kwr2wusf/external/com_google_protobuf; Extracting v3.19.1.tar.gz Fetching repository @@nodejs_windows_amd64; starting Fetching https://nodejs.org/dist/v16.19.0/node-v16.19.0-win-x64.zip; 13.4 MiB (51.9%) Traceback (most recent call last): File "C:\MediaPipeUnityPlugin\build.py", line 475, in Argument().command().run() File "C:\MediaPipeUnityPlugin\build.py", line 114, in run self._run_command(self._build_proto_srcs_commands()) File "C:\MediaPipeUnityPlugin\build.py", line 56, in _run_command return subprocess.run(' '.join(command_list), check=True, shell=shell) File "C:\anaconda2022\envs\mediapipe\lib\subprocess.py", line 528, in run raise CalledProcessError(retcode, process.args, subprocess.CalledProcessError: Command 'bazel --output_user_root C:/_bzl build -c opt --action_env PYTHON_BIN_PATH="C://anaconda2022//envs//mediapipe//python.exe" --action_env ProgramData --action_env PROCESSOR_ARCHITECTURE --action_env PROCESSOR_IDENTIFIER --action_env PROCESSOR_LEVEL --action_env PROCESSOR_REVISION //mediapipe_api:mediapipe_proto_srcs' returned non-zero exit status 1.

Additional Context

螢幕擷取畫面 2024-07-19 101755

I try to use : #5105, but new problems came up about patch incompatibility.

homuler commented 4 months ago

At least it's working on GitHub Actions, so if you can't run it locally, please fork this repository and use the workflow (see also https://github.com/homuler/MediaPipeUnityPlugin?tab=readme-ov-file#hammer_and_wrench-installation).

bazel :7.2.1

If it really is, it won't work (you should use bazelisk instead).

Daniel70-liu commented 4 months ago

At least it's working on GitHub Actions, so if you can't run it locally, please fork this repository and use the workflow (see also https://github.com/homuler/MediaPipeUnityPlugin?tab=readme-ov-file#hammer_and_wrench-installation).

bazel :7.2.1

If it really is, it won't work (you should use bazelisk instead).

Thanks for the reminder. Using bazelisk helped me find a suitable version, so it can work.