Setting up OpenCV on macos - Apple Silicon

I am running into this issue please help!!

=== Detected probe priority based on environment vars: pkg_config: false, cmake: false, vcpkg: false
=== Probing the OpenCV library in the following order: environment, pkg_config, cmake, vcpkg_cmake, vcpkg
=== Configuring OpenCV library from the environment:
=== include_paths: /opt/homebrew/Cellar/opencv/4.8.0_4/include
=== link_paths: /opt/homebrew/Cellar/opencv/4.8.0_4/share/opencv4
=== link_libs: /opt/homebrew/Cellar/opencv/4.8.0_4/lib
=== Successfully probed using: environment
=== OpenCV library configuration: Library {
include_paths: [
version: Version {
major: 0,
minor: 0,
patch: 0,
cargo_metadata: [
thread 'main' panicked at 'Unsupported OpenCV version: 0.0.0, must be from 3.2, 3.4 or 4.x branch', /Users/aaqidmasoodi/.cargo/registry/src/
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace

This looks like a bug in the opencv crate.

I've gotten in touch with the developer gave him multiple dumps.
but i think it is not a bug in the crate, i think i am doing something stupid with the path. I am actual not sure what paths, env i should be setting. I set it up based on what i found online and changed them according to my machine and paths. :frowning: Hope i am able to use opencv

Edit: Finally figured it out. I have written a whole article on it.

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.