Skip to content

Commit f4af2fc

Browse files
committed
Add more paths to openvino-finder
This change allows `openvino-finder` to find paths in newer released archives. For all versions since 2022.3.0 (checked: 2022.3.0, 2022.3.1, 2023.0.0, 2023.0.1, 2023.0.2, 2023.1.0), I see paths like: - linux: `runtime/lib/intel64/libopenvino.so` - windows: `runtime/bin/intel64/Release/openvino.dll` - macos: `runtime/lib/intel64/Release/libopenvino.dylib` This path-finding code is getting out of hand, though, so soon it will need to be pared down. For the time being, though, this enables finding more libraries and doesn't break any existing paths. One other caveat: this change does not yet find the Windows-linkable version of the library that Cargo expects for dynamic linking: `runtime/lib/intel64/Release/openvino.lib`.
1 parent 2f86339 commit f4af2fc

File tree

1 file changed

+9
-3
lines changed
  • crates/openvino-finder/src

1 file changed

+9
-3
lines changed

crates/openvino-finder/src/lib.rs

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@
2727
//!
2828
//! | Installation Method | Path | Available on | Notes |
2929
//! | ------------------- | -------------------------------------------------- | --------------------- | -------------------------------- |
30-
//! | Archive (`.tar.gz`) | `<extracted folder>/runtime/lib/<arch>` | Linux, MacOS | `<arch>`: `intel64,armv7l,arm64` |
30+
//! | Archive (`.tar.gz`) | `<extracted folder>/runtime/lib/<arch>` | Linux | `<arch>`: `intel64,armv7l,arm64` |
31+
//! | Archive (`.tar.gz`) | `<extracted folder>/runtime/lib/<arch>/Release` | MacOS | `<arch>`: `intel64,armv7l,arm64` |
3132
//! | Archive (`.zip`) | `<unzipped folder>/runtime/bin/<arch>/Release` | Windows | `<arch>`: `intel64,armv7l,arm64` |
3233
//! | PyPI | `<pip install folder>/site-packages/openvino/libs` | Linux, MacOS, Windows | Find install folder with `pip show openvino` |
3334
//! | DEB | `/usr/lib/x86_64-linux-gnu/openvino-<version>/` | Linux (APT-based) | This path is for plugins; the libraries are one directory above |
@@ -210,8 +211,13 @@ cfg_if! {
210211
}
211212
}
212213

213-
const KNOWN_INSTALLATION_SUBDIRECTORIES: &[&str] =
214-
&["runtime/lib/intel64", "runtime/3rdparty/tbb/lib"];
214+
const KNOWN_INSTALLATION_SUBDIRECTORIES: &[&str] = &[
215+
"runtime/lib/intel64/Release",
216+
"runtime/lib/intel64",
217+
"runtime/3rdparty/tbb/lib",
218+
"runtime/bin/intel64",
219+
"runtime/3rdparty/tbb/bin",
220+
];
215221

216222
const KNOWN_BUILD_SUBDIRECTORIES: &[&str] = &[
217223
"bin/intel64/Debug/lib",

0 commit comments

Comments
 (0)