diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9dcfce1..0b9a401 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - scalaVersion: ['2.12.19', '2.13.14', '3.3.3', '3.4.3'] + scalaVersion: ['2.12.19', '2.13.14', '3.4.3', '3.5.0'] javaTag: [ 'graalvm-community-22.0.1', 'graalvm-community-21.0.2', @@ -72,6 +72,21 @@ jobs: dockerfile: 'alpine.Dockerfile' baseImageTag: '17.0.10_7-jdk-alpine' platforms: 'linux/amd64' + exclude: + # https://github.com/VirtusLab/scala-cli/issues/3130 + - scalaVersion: '3.5.0' + javaTag: 'graalvm-community-22.0.1' + - scalaVersion: '3.5.0' + javaTag: 'graalvm-community-21.0.2' + - scalaVersion: '3.5.0' + javaTag: 'graalvm-ce-22.3.3-b1-java17' + # https://github.com/VirtusLab/scala-cli/issues/2758 + - scalaVersion: '3.5.0' + javaTag: 'eclipse-temurin-alpine-22_36' + - scalaVersion: '3.5.0' + javaTag: 'eclipse-temurin-alpine-21.0.2_13' + - scalaVersion: '3.5.0' + javaTag: 'eclipse-temurin-alpine-17.0.10_7' steps: - uses: actions/checkout@v4 - name: Set up QEMU diff --git a/eclipse-temurin/Dockerfile b/eclipse-temurin/Dockerfile index db5aef9..7f79e5d 100644 --- a/eclipse-temurin/Dockerfile +++ b/eclipse-temurin/Dockerfile @@ -45,7 +45,7 @@ RUN \ chmod -R 755 /usr/share/scala && \ ln -s /usr/share/scala/bin/* /usr/local/bin && \ case $SCALA_VERSION in \ - "3"*) echo '@main def main = println(s"Scala library version ${dotty.tools.dotc.config.Properties.versionNumberString}")' > test.scala ;; \ + "3"*) echo 'import java.io.FileInputStream;import java.util.jar.JarInputStream;val scala3LibJar = classOf[CanEqual[_, _]].getProtectionDomain.getCodeSource.getLocation.toURI.getPath;val manifest = new JarInputStream(new FileInputStream(scala3LibJar)).getManifest;val ver = manifest.getMainAttributes.getValue("Implementation-Version");@main def main = println(s"Scala version ${ver}")' > test.scala ;; \ *) echo "println(util.Properties.versionMsg)" > test.scala ;; \ esac && \ scala -nocompdaemon test.scala && rm test.scala diff --git a/eclipse-temurin/alpine.Dockerfile b/eclipse-temurin/alpine.Dockerfile index 7990c78..dfaa70d 100644 --- a/eclipse-temurin/alpine.Dockerfile +++ b/eclipse-temurin/alpine.Dockerfile @@ -24,8 +24,8 @@ RUN \ update-ca-certificates && \ scala -version && \ case $SCALA_VERSION in \ - "3"*) echo '@main def main = println(s"Scala library version ${dotty.tools.dotc.config.Properties.versionNumberString}")' > test.scala ;; \ - *) echo "println(util.Properties.versionMsg)" > test.scala ;; \ + "3"*) echo 'import java.io.FileInputStream;import java.util.jar.JarInputStream;val scala3LibJar = classOf[CanEqual[_, _]].getProtectionDomain.getCodeSource.getLocation.toURI.getPath;val manifest = new JarInputStream(new FileInputStream(scala3LibJar)).getManifest;val ver = manifest.getMainAttributes.getValue("Implementation-Version");@main def main = println(s"Scala version ${ver}")' > test.scala ;; \ + *) echo "println(util.Properties.versionMsg)" > test.scala ;; \ esac && \ scala -nocompdaemon test.scala && rm test.scala diff --git a/graalvm-ce/Dockerfile b/graalvm-ce/Dockerfile index 20015d5..f2070f1 100644 --- a/graalvm-ce/Dockerfile +++ b/graalvm-ce/Dockerfile @@ -39,7 +39,7 @@ RUN \ chmod -R 755 /usr/share/scala && \ ln -s /usr/share/scala/bin/* /usr/local/bin && \ case $SCALA_VERSION in \ - "3"*) echo '@main def main = println(s"Scala library version ${dotty.tools.dotc.config.Properties.versionNumberString}")' > test.scala ;; \ + "3"*) echo 'import java.io.FileInputStream;import java.util.jar.JarInputStream;val scala3LibJar = classOf[CanEqual[_, _]].getProtectionDomain.getCodeSource.getLocation.toURI.getPath;val manifest = new JarInputStream(new FileInputStream(scala3LibJar)).getManifest;val ver = manifest.getMainAttributes.getValue("Implementation-Version");@main def main = println(s"Scala version ${ver}")' > test.scala ;; \ *) echo "println(util.Properties.versionMsg)" > test.scala ;; \ esac && \ scala -nocompdaemon test.scala && rm test.scala diff --git a/graalvm-community/Dockerfile b/graalvm-community/Dockerfile index 6cf27df..130fb3f 100644 --- a/graalvm-community/Dockerfile +++ b/graalvm-community/Dockerfile @@ -39,7 +39,7 @@ RUN \ chmod -R 755 /usr/share/scala && \ ln -s /usr/share/scala/bin/* /usr/local/bin && \ case $SCALA_VERSION in \ - "3"*) echo '@main def main = println(s"Scala library version ${dotty.tools.dotc.config.Properties.versionNumberString}")' > test.scala ;; \ + "3"*) echo 'import java.io.FileInputStream;import java.util.jar.JarInputStream;val scala3LibJar = classOf[CanEqual[_, _]].getProtectionDomain.getCodeSource.getLocation.toURI.getPath;val manifest = new JarInputStream(new FileInputStream(scala3LibJar)).getManifest;val ver = manifest.getMainAttributes.getValue("Implementation-Version");@main def main = println(s"Scala version ${ver}")' > test.scala ;; \ *) echo "println(util.Properties.versionMsg)" > test.scala ;; \ esac && \ scala -nocompdaemon test.scala && rm test.scala