From 0bd5e7706865c208b9eaa591363488e0015975d8 Mon Sep 17 00:00:00 2001 From: Eugene Yokota Date: Sat, 31 Dec 2022 16:48:52 -0500 Subject: [PATCH 1/3] ipcsocket 1.6.1 --- project/Dependencies.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project/Dependencies.scala b/project/Dependencies.scala index 33941806c..8f3cf364b 100644 --- a/project/Dependencies.scala +++ b/project/Dependencies.scala @@ -26,7 +26,7 @@ object Dependencies { val launcherInterface = "org.scala-sbt" % "launcher-interface" % launcherVersion val rawLauncher = "org.scala-sbt" % "launcher" % launcherVersion val testInterface = "org.scala-sbt" % "test-interface" % "1.0" - val ipcSocket = "org.scala-sbt.ipcsocket" % "ipcsocket" % "1.5.0" + val ipcSocket = "org.scala-sbt.ipcsocket" % "ipcsocket" % "1.6.1" private val compilerInterface = "org.scala-sbt" % "compiler-interface" % zincVersion private val compilerClasspath = "org.scala-sbt" %% "zinc-classpath" % zincVersion From b5228254643804bdc84c8ffc9fd813b6ee58156e Mon Sep 17 00:00:00 2001 From: Matthias Kurz Date: Mon, 2 Jan 2023 22:22:11 +0100 Subject: [PATCH 2/3] Add aarch64 libsbtipcsocket.so native-image/resource-config.json --- .../main/resources/META-INF/native-image/resource-config.json | 1 + 1 file changed, 1 insertion(+) diff --git a/client/src/main/resources/META-INF/native-image/resource-config.json b/client/src/main/resources/META-INF/native-image/resource-config.json index 0bc65dde4..19d10f4a9 100644 --- a/client/src/main/resources/META-INF/native-image/resource-config.json +++ b/client/src/main/resources/META-INF/native-image/resource-config.json @@ -16,6 +16,7 @@ {"pattern":"org/jline/utils/screen.caps"}, {"pattern":"library.properties"}, {"pattern":"darwin/x86_64/libsbtipcsocket.dylib"}, + {"pattern":"linux/aarch64/libsbtipcsocket.so"}, {"pattern":"linux/x86_64/libsbtipcsocket.so"}, {"pattern":"win32/x86_64/sbtipcsocket.dll"} ] From 03ae9f452e703774128c845590c883ac5a67e86d Mon Sep 17 00:00:00 2001 From: Matthias Kurz Date: Mon, 2 Jan 2023 23:48:13 +0100 Subject: [PATCH 3/3] Set correct page size for aarch64 binaries --- build.sbt | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/build.sbt b/build.sbt index 46681bca6..6bd6e6fb8 100644 --- a/build.sbt +++ b/build.sbt @@ -4,6 +4,7 @@ import com.typesafe.tools.mima.core.ProblemFilters._ import com.typesafe.tools.mima.core._ import local.Scripted import java.nio.file.{ Files, Path => JPath } +import java.util.Locale import scala.util.Try @@ -1146,6 +1147,10 @@ lazy val serverTestProj = (project in file("server-test")) ) val isWin = scala.util.Properties.isWin +val isLinux = scala.util.Properties.isLinux +val isArmArchitecture: Boolean = sys.props + .getOrElse("os.arch", "") + .toLowerCase(Locale.ROOT) == "aarch64" val buildThinClient = inputKey[JPath]("generate a java implementation of the thin client") // Use a TaskKey rather than SettingKey for nativeInstallDirectory so it can left unset by default @@ -1177,7 +1182,9 @@ lazy val sbtClientProj = (project in file("client")) "-H:+ReportExceptionStackTraces", "-H:-ParseRuntimeOptions", s"-H:Name=${target.value / "bin" / "sbtn"}", - ), + ) ++ (if (isLinux && isArmArchitecture) + Seq("-H:PageSize=65536") // Make sure binary runs on kernels with page size set to 4k, 16 and 64k + else Nil), buildThinClient := { val isFish = Def.spaceDelimited("").parsed.headOption.fold(false)(_ == "--fish") val ext = if (isWin) ".bat" else if (isFish) ".fish" else ".sh"