I'm trying to use a feature of Libreoffice that requires java (VB macros for calc). Libreoffice tells me to select a java installation in the advanced options, but even when pointed to the right folder (/usr/lib/openjdk-{11,17}) it says that no JRE is found there.
Has anyone managed to activate it?

P.S. I also tried to trace trough libreoffice to check what it is actually doing, but apparently there are no debug symbols for the incriminated code, even though I installed libreoffice-dbginfo, is that normal?

    probably adding java to PATH variable can fix it

    Both options were already tried, unfortunately

    elusian (/usr/lib/openjdk-{11,17}

    Just noticed what you posted, it should be lib64, so /usr/lib64/openjdk-11 or /usr/lib64/openjdk-17.

    lib is a symlink to lib64, lib32 is the 32bit one.

    I tried, just to be sure, but it does not change.

    So, to summarize my current findings:

    1. libreoffice searches for libjvm.so at
      • $JAVA_HOME/lib/amd64/client/libjvm.so
      • $JAVA_HOME/lib/amd64/server/libjvm.so
      • $JAVA_HOME/lib/amd64/classic/libjvm.so
      • $JAVA_HOME/lib/amd64/jrockit/libjvm.so
      • $JAVA_HOME/lib/server/libjvm.so
    2. But the openjdk package in Solus provides the library at $JAVA_HOME/lib/client/libjvm.so

    Since Libreoffice probably does not really need the server variant, the possible solutions I see are

    • ask Libreoffice to add a search path
    • patch Libreoffice to add a search path
    • build openjdk in the server variant like other distros do (longer build), which is likely why Libreoffice searches in that path
    • link the openjdk client variant to a server path (which is a lie I guess)

    Can anyone in the team comment on this? I can open issues in either project.

    You can file issue about this with all your research on Solus github here. The staffs track it better that way.

    Makes sense, I was just trying to get feedback on whether this is a Solus issue or a Libreoffice issue before opening a bug in either project.