@@ -57,11 +57,19 @@ static OpenVINOLibraryLoader()
5757
5858#if LINQPad || NETCOREAPP3_1_OR_GREATER
5959
60+ public static List < string > SupportedVersionSuffixes { get ; set ; } = new ( )
61+ {
62+ "2410" ,
63+ "2400" ,
64+ "2330" ,
65+ "2320" ,
66+ "2310" ,
67+ } ;
68+
6069 private static IntPtr OpenVINOImportResolver ( string libraryName , Assembly assembly , DllImportSearchPath ? searchPath )
6170 {
6271 if ( libraryName == Dll )
6372 {
64- string [ ] allowedVersions = new [ ] { "2400" , "2330" , "2320" , "2310" } ;
6573 if ( RuntimeInformation . IsOSPlatform ( OSPlatform . Windows ) )
6674 {
6775 return LoadWithDeps ( assembly , searchPath , new LibDeps ( "openvino_c.dll" , new string [ ]
@@ -71,7 +79,7 @@ private static IntPtr OpenVINOImportResolver(string libraryName, Assembly assemb
7179 }
7280 else if ( RuntimeInformation . IsOSPlatform ( OSPlatform . OSX ) )
7381 {
74- return LoadWithDeps ( assembly , searchPath , allowedVersions . Select ( v => new LibDeps ( $ "libopenvino_c.{ v } .dylib", new string [ ]
82+ return LoadWithDeps ( assembly , searchPath , SupportedVersionSuffixes . Select ( v => new LibDeps ( $ "libopenvino_c.{ v } .dylib", new string [ ]
7583 {
7684 $ "libopenvino.{ v } .dylib",
7785 } ) ) . ToArray ( ) ) ;
@@ -86,7 +94,7 @@ private static IntPtr OpenVINOImportResolver(string libraryName, Assembly assemb
8694 else
8795 {
8896 /* linux or others */
89- return LoadWithDeps ( assembly , searchPath , allowedVersions . Select ( v => new LibDeps ( $ "libopenvino_c.so.{ v } ", new string [ ]
97+ return LoadWithDeps ( assembly , searchPath , SupportedVersionSuffixes . Select ( v => new LibDeps ( $ "libopenvino_c.so.{ v } ", new string [ ]
9098 {
9199 $ "libtbb.so.12",
92100 $ "libopenvino.so.{ v } ",
0 commit comments