lichess-org / lila

♞ lichess.org: the forever free, adless and open source chess server ♞
https://lichess.org
GNU Affero General Public License v3.0
15.34k stars 2.25k forks source link

Cannot build it from last release #14156

Closed adamasantares closed 10 months ago

adamasantares commented 10 months ago

Exact URL of where the bug happened

I cannot start it at all

Steps to reproduce the bug

Hi, I cannot build it and I waste 3 days already to figure out what's wrong.

Ubuntu 22.04 openjdk 11.0.21

It starting normally, but at the end I'm getting the error which description, well I have no idea what does it mean. What is "21 is not a valid choise"?

lila# sbt run

downloading sbt launcher 1.9.7
copying runtime jar...
[info] [launcher] getting org.scala-sbt sbt 1.9.7  (this may take some time)...
[info] [launcher] getting Scala 2.12.18 (for sbt)...
[info] welcome to sbt 1.9.7 (Ubuntu Java 11.0.19)
[info] loading settings for project lila-build from plugins.sbt ...
[info] loading project definition from /root/lichess/lila/project
[warn] sbt-plugin.jar no longer exists at /root/.cache/coursier/v1/https/raw.githubusercontent.com/lichess-org/lila-maven/master/com.typesafe.play/sbt-plugin/scala_2.12/sbt_1.0/2.8.18-lila_1.21/jars/sbt-plugin.jar
[info] Updating 
https://repo1.maven.org/maven2/ch/epfl/scala/sbt-bloop_2.12_1.0/1.5.12/sbt-bloop_2.12_1.0-1.5.12.pom
  100.0% [##########] 2.2 KiB (6.3 KiB / s)
https://repo1.maven.org/maven2/org/scalameta/sbt-scalafmt_2.12_1.0/2.5.2/sbt-scalafmt_2.12_1.0-2.5.2.pom
  100.0% [##########] 2.9 KiB (8.1 KiB / s)

... other messages ...

https://repo1.maven.org/maven2/net/java/dev/jna/jna-platform/5.8.0/jna-platform-5.8.0.jar
  100.0% [##########] 1.3 MiB (725.2 KiB / s)
[info] Fetched artifacts of 
[info] compiling 49 Scala sources and 1 Java source to /root/lichess/lila/modules/common/target/scala-3.3.1/classes ...
[error] 21 is not a valid choice for -java-output-version
[info]   scalac -help  gives more information
[error] one error found
[error] (common / Compile / compileIncremental) Compilation failed

What did you expect to happen?

uhm, workable build

What happened instead?

doesn't work

Operating system

Ubuntu 22.04

Browser and version (or alternate access method)

Google Chrome

Additional information

I was doing search of solution for 3 days, no success. Please give me an idea what to check

adamasantares commented 10 months ago

One remark, I thought that problem with Java version and I tried to use 11.0.19 but the result is same

lsap commented 10 months ago

Is 'dev' label supposed here? If yes, do you have rights to put it?

lenguyenthanh commented 10 months ago

It's required jdk 21. Please check: https://github.com/lichess-org/lila/wiki/Lichess-Development-Onboarding#prerequisites

adamasantares commented 10 months ago

It's required jdk 21. Please check: https://github.com/lichess-org/lila/wiki/Lichess-Development-Onboarding#prerequisites

OMG thanks for reply! ^.^ I'll try it.

I guess issue can be closed, sorry for offtopic

lsap commented 10 months ago

60fa405 can't be built with OpenJDK 21.0.1 from Ubuntu 22.04.2 repo with an error same to aforementioned (only 21.0.1 instead of 11.0.9).

lsap commented 10 months ago

Built with: $ ./lila (compare to sbt run in the original post) succesfully