Deliver x86_64 Illuaminate binaries to all Macs

The Intel native binaries run just fine on Apple-silicon Macs through
Rosetta.
This commit is contained in:
David Queneau 2022-12-17 13:52:36 -08:00
parent 27b732f835
commit 6e5b7243f4
1 changed files with 3 additions and 1 deletions

View File

@ -66,9 +66,11 @@ private fun illuaminateArtifact(project: Project, version: String): Dependency {
val osArch = System.getProperty("os.arch").toLowerCase()
val arch = when {
// On macOS the x86_64 binary will work for both ARM and Intel Macs through Rosetta.
os == "macos" -> "x86_64"
osArch == "arm" || osArch.startsWith("aarch") -> error("Unsupported architecture '$osArch' for illuaminate")
osArch.contains("64") -> "x86_64"
else -> error("Unsupported architecture $osArch for illuaminate")
else -> error("Unsupported architecture '$osArch' for illuaminate")
}
return project.dependencies.create(