imageflow-dotnet icon indicating copy to clipboard operation
imageflow-dotnet copied to clipboard

Unable to load shared library 'imageflow'

Open bichtv opened this issue 1 year ago • 5 comments

I have issued runtime application. pls help me resolve issue. Thanks One or more errors occurred. (Looking for "libimageflow.so" RID="linux-x64", IsUnix=True, IsDotNetCore=True RelativeSearchPath=""\nBefore searching: Unable to load shared library 'imageflow' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: libimageflow: cannot open shared object file: No such file or directory\nFile not found: /app/x64/libimageflow.so\nFile not found: /app/libimageflow.so\nError "Success" (0) loading imageflow from /app/runtimes/linux-x64/native/libimageflow.so\n at Imageflow.Bindings.NativeMethods.imageflow_context_create(UInt32 imageflowAbiVerMajor, UInt32 imageflowAbiVerMinor)\n at Imageflow.Bindings.JobContextHandle.<>c.<.ctor>b__0_0()\n at Imageflow.Bindings.NativeLibraryLoader.FixDllNotFoundException[T](String basename, Func1 invokingOperation, IEnumerable1 customSearchDirectories)\n)

bichtv avatar Jun 22 '24 15:06 bichtv

Which nuget packages did you use?

On Sat, Jun 22, 2024, 9:02 AM bichtv @.***> wrote:

I have issued runtime application. pls help me resolve issue. Thanks One or more errors occurred. (Looking for "libimageflow.so" RID="linux-x64", IsUnix=True, IsDotNetCore=True RelativeSearchPath=""\nBefore searching: Unable to load shared library 'imageflow' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: libimageflow: cannot open shared object file: No such file or directory\nFile not found: /app/x64/libimageflow.so\nFile not found: /app/libimageflow.so\nError "Success" (0) loading imageflow from /app/runtimes/linux-x64/native/libimageflow.so\n at Imageflow.Bindings.NativeMethods.imageflow_context_create(UInt32 imageflowAbiVerMajor, UInt32 imageflowAbiVerMinor)\n at Imageflow.Bindings.JobContextHandle.<>c.<.ctor>b__0_0()\n at Imageflow.Bindings.NativeLibraryLoader.FixDllNotFoundException[T](String basename, Func1 invokingOperation, IEnumerable1 customSearchDirectories)\n)

— Reply to this email directly, view it on GitHub https://github.com/imazen/imageflow-dotnet/issues/61, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAA2LHYCRQSCIJ3IMZZ7SFLZIWGZJAVCNFSM6AAAAABJXQB5RWVHI2DSMVQWIX3LMV43ASLTON2WKOZSGM3DOOBWGU3TQNA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

lilith avatar Jun 22 '24 17:06 lilith

I have the same problem. MacOS Sonoma 14.5. .net 8.0 Imageflow.NativeRuntime.osx-x86_64/2.0.0-preview8

AlexandruIonutZarnescu avatar Jul 24 '24 09:07 AlexandruIonutZarnescu

Same problem for me. Sonoma as well. Imageflow.AllPlatforms & Imageflow.Net v0.13.2. Macbook Pro M1.

Tried to install Imageflow.NativeRuntime.osx-x86_64 explicitly but doesn't matter.

Remember this from a few years ago when imageflow was new, but can't remember how to fix it though.

aheintz avatar Aug 07 '24 12:08 aheintz

I believe the native runtime doesn't support ARM architecture. You should run it under the x86 runtime for .NET. I've tried that setup myself.

Specify the runtime as osx-x64 (it should be installed from the Microsoft binaries):

<PropertyGroup>
    <TargetFramework>net8.0</TargetFramework>
    <ImplicitUsings>enable</ImplicitUsings>
    <LangVersion>latest</LangVersion>
    <OutputType>Exe</OutputType>
    <Nullable>enable</Nullable>
    <RuntimeIdentifier>osx-x64</RuntimeIdentifier>
</PropertyGroup>

I tested this on the latest preview:

<PackageReference Include="Imageflow.NativeRuntime.osx-x86_64" Version="2.0.0-preview8" />

And stable releases as well:

<PackageReference Include="Imageflow.Net" Version="0.13.2" />
<PackageReference Include="Imageflow.AllPlatforms" Version="0.13.2" />

It works fine.

egbaydarov avatar Jan 15 '25 09:01 egbaydarov

Arm support is in preview, coming soon!

On Wed, Jan 15, 2025, 2:30 AM Egor @.***> wrote:

I believe the native runtime doesn't support ARM architecture. You should run it under the x86 runtime for .NET. I've tried that setup myself.

Specify the runtime as osx-x64 (it should be installed from the Microsoft binaries):

net8.0 enable latest Exe enable osx-x64

I tested this on the latest preview:

It works fine.

— Reply to this email directly, view it on GitHub https://github.com/imazen/imageflow-dotnet/issues/61#issuecomment-2592113110, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAA2LH7LQUPXIIUINUXUZFT2KYTDTAVCNFSM6AAAAABVGY3M2KVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKOJSGEYTGMJRGA . You are receiving this because you commented.Message ID: @.***>

lilith avatar Jan 15 '25 20:01 lilith

We do have arm packages for osx, linux, and windows on nuget now. The Imageflow.AllPlatforms release candidate pulls them all in - dotnet can be buggy on xplat packages so let me know if you encounter any issues. https://www.nuget.org/packages/Imageflow.AllPlatforms/0.14.0-rc01

lilith avatar Apr 18 '25 04:04 lilith