AsamK / signal-cli

signal-cli provides an unofficial commandline, JSON-RPC and dbus interface for the Signal messenger.
GNU General Public License v3.0
3.22k stars 306 forks source link

Version 0.13.0 not working with java runtime 17 #1460

Closed brknkfr closed 9 months ago

brknkfr commented 9 months ago

I have a debian system (bookworm) and the most recent java runtime is version 17. Unfortunately it seems that signal-cli version 0.13.0 doesn't work with that java runtime anymore ... Version 0.12.8 still works very well with java version 17.

Error: LinkageError occurred while loading main class org.asamk.signal.Main
    java.lang.UnsupportedClassVersionError: org/asamk/signal/Main has been compiled by a more recent version of the Java Runtime (class file version 65.0), this version of the Java Runtime only recognizes class file versions up to 61.0

Do I need to get a more recent java runtime or is this fixable in another way? I could imagine that other people run into the same problem, because version 17 of the java runtime ist the second latest long term support version and its available in a lot of linux distributions whereas version 21 is not yet widely available.

A workaround for me could be to use the java version of the adoptium repo or from orcale, but unfortunately they do not have an arm release of version 21. For now, I just do apt-pinning to get openjdk-21-jre-headless from trixie.

AsamK commented 9 months ago

Yes, the latest version requires java 21. As you mention, the are various ways to install it in stable distributions.

m-ueberall commented 9 months ago

Do I need to get a more recent java runtime or is this fixable in another way?

@brknkfr: There is yet another way, of course; you could switch to the native binary which only depends on glibc. Bookworm comes with glibc v2.36, so the upstream binary listed on the release page should work. In case you're using a system with an older version of glibc, you'll have to wait for half a day or two until third-party builds will become available (listed on the Wiki).

brknkfr commented 9 months ago

@brknkfr: There is yet another way, of course; you could switch to the native binary which only depends on glibc. Bookworm comes with glibc v2.36, so the upstream binary listed on the release page should work. In case you're using a system with an older version of glibc, you'll have to wait for half a day or two until third-party builds will become available (listed on the Wiki).

Thank you for your hint. I'm running a debian bookworm on a armv7 platform and unfortunately there are no prebuilt packages for armv7.