Skip to content

unable to run on maven:3.8-eclipse-temurin-16 #116

Description

@cameronbraid

The home page states JVips.jar embeds libvips.so and its dependencies. The jar file is self-sufficient for Linux however I cannot get it to run in docker using image maven:3.8-eclipse-temurin-16

I get the following error :

Mar 08, 2022 7:59:53 PM com.criteo.vips.Vips loadLibraryFromJar
WARNING: Could not load lib 'libheif.so' via classloader
Mar 08, 2022 7:59:53 PM com.criteo.vips.Vips loadLibraryFromJar
WARNING: Could not load lib 'libspng.so' via classloader
Exception in thread "main" java.lang.UnsatisfiedLinkError: /tmp/libimagequant.so5724719230057576705: libgomp.so.1: cannot open shared object file: No such file or directory
        at java.base/jdk.internal.loader.NativeLibraries.load(Native Method)
        at java.base/jdk.internal.loader.NativeLibraries$NativeLibraryImpl.open(NativeLibraries.java:383)
        at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:227)
        at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:169)
        at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2383)
        at java.base/java.lang.Runtime.load0(Runtime.java:746)
        at java.base/java.lang.System.load(System.java:1857)
        at com.criteo.vips.Vips.loadLibraryFromJar(Vips.java:112)
        at com.criteo.vips.Vips.tryLoadLibrariesFromJar(Vips.java:78)
        at com.criteo.vips.Vips.<clinit>(Vips.java:58)
        at MainHttps.main(MainHttps.java:9)

Are these dependencies that you can add to the jar ?

Activity

  1. dbouron commented on Mar 28, 2022

    @dbouron
    Contributor

    Hi @cameronbraid ,

    JVips embeds only image related libraries but don't embed the whole required libraries (like LibreOffice does for example).
    You should install some prerequired libraries. According to the libvips Readme, you should install:
    libvips must have build-essential, pkg-config, libglib2.0-dev, libexpat1-dev

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

    help wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions