Skip to content
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

AARCH64 Support #35

Open
adeeb10abbas opened this issue Mar 13, 2023 · 2 comments
Open

AARCH64 Support #35

adeeb10abbas opened this issue Mar 13, 2023 · 2 comments
Assignees
Labels
help wanted Extra attention is needed

Comments

@adeeb10abbas
Copy link
Owner

My initial analysis suggests that we only need to start using opencv arm rules (or pull in the binaries)...
Other than that, all targets already support arm. Let's just push through this, so that we're done once and for all.

cc/ @sidor926 can you take a lead on this?

@adeeb10abbas adeeb10abbas added the help wanted Extra attention is needed label Mar 13, 2023
@sidor926
Copy link
Collaborator

Will work on this along with #34

@adeeb10abbas
Copy link
Owner Author

Update -

root@25a4ac59be1b:~/outdoor_slam_ros2# bazelisk build ...
ERROR: /root/.cache/bazel/_bazel_root/cd02400566e20f8639eace29e76364c7/external/opencv/BUILD:36:12: configurable attribute "content" in @opencv//:cv_cpu_config.h doesn't match this configuration. Would a default condition help?

Conditions checked:
 @com_github_mjbots_bazel_deps//conditions:arm
 @com_github_mjbots_bazel_deps//conditions:x86_64

To see a condition's definition, run: bazel query --output=build <condition label>.

This instance of @opencv//:cv_cpu_config.h has configuration identifier e60975a. To inspect its configuration, run: bazel config e60975a.

For more help, see https://bazel.build/docs/configurable-attributes#faq-select-choose-condition.

INFO: Repository qhull instantiated at:
  /root/outdoor_slam_ros2/WORKSPACE:67:13: in <toplevel>
Repository rule http_archive defined at:
  /root/.cache/bazel/_bazel_root/cd02400566e20f8639eace29e76364c7/external/bazel_tools/tools/build_defs/repo/http.bzl:372:31: in <toplevel>
INFO: Repository ffmpeg instantiated at:
  /root/outdoor_slam_ros2/WORKSPACE:150:15: in <toplevel>
  /root/.cache/bazel/_bazel_root/cd02400566e20f8639eace29e76364c7/external/com_github_mjbots_bazel_deps/tools/workspace/default.bzl:99:26: in add_default_repositories
  /root/.cache/bazel/_bazel_root/cd02400566e20f8639eace29e76364c7/external/com_github_mjbots_bazel_deps/tools/workspace/ffmpeg/repository.bzl:292:23: in ffmpeg_repository
Repository rule _ffmpeg_repository defined at:
  /root/.cache/bazel/_bazel_root/cd02400566e20f8639eace29e76364c7/external/com_github_mjbots_bazel_deps/tools/workspace/ffmpeg/repository.bzl:279:37: in <toplevel>
ERROR: Analysis of target '//dwsl/variot:img_pub_cc' failed; build aborted:
INFO: Elapsed time: 27.650s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (80 packages loaded, 17610 targets configured)

This needs to be solved. Following is a potential solution -

  • Remove pulling in building the opencv inside the bazel workspace
  • write a shell script that isntalls opencv system wide and then make Bazel use the path usr/local/lib or whatevs
  • and the BUILD file would look something simple like this just globb-ing whatever's needed
cc_library(
    name = "opencv",
    hdrs = glob(["include/opencv4/*/.h*"]),
    includes = ["include/opencv4"],
    linkopts = ["-lopencv_core", "-lopencv_imgproc", "-lopencv_highgui"],
    visibility = ["//visibility:public"],
)

adeeb10abbas added a commit that referenced this issue Apr 9, 2023
Adding Docker support. Builds from a base Ubuntu Jammy image with ROS 2 Humble. 

Solves #43 entirely. Complete multiplatform support is contingent upon #35 which is essentially blocked by having intelligent OpenCV rules.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants