Skip to content

DllNotFoundException on Linux with .NET 8 even when libleptonica-1.82.0.so exists #687

Description

@Tojan-Naiem

When running on Linux (Ubuntu) with .NET8 and the Tesseract NuGet
(wrapper from charlesw/tesseract), I get:

System.DllNotFoundException: Failed to find library "libleptonica-1.82.0.so" for platform x64.

Even when:

  • libleptonica-1.82.0.so is placed in runtimes/linux-x64/native/
  • NativeLibrary.Load is called manually before TesseractEngine

This seems to be caused by InteropDotNet loader not finding the .so
in expected runtime paths, nor following symlinks or preloaded libs.

Worked around by using external tesseract CLI instead.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions