Hi all, does anybody know when the `-Xoverride-cl...
# kotlin-native
v
Hi all, does anybody know when the
-Xoverride-clang-options
option is going to be available? I am trying to compile for a custom arm64 target. My
build.gradle.kts
contains the following section:
Copy code
linuxArm64("arm64"){            
 binaries {
  executable {
   entryPoint = <entry_point>
   freeCompilerArgs += listOf("-Xoverride-clang-options=-target-cpu=cortex-a53")
  }
 }
}
and it produces the following warning:
w: Flag is not supported by this version of the compiler: -Xoverride-clang-options=-target-cpu=cortex-a53
. Did anybody succeed in compiling for a custom target? Thanks in advance!
m
It's not that simple - then everyting have to be compiled for different processor, including stdlib and platform libs. But they are precompiled in K/N distribution. The only way it can be done - compile your own compiler 🙂 Change it here - https://github.com/JetBrains/kotlin-native/blob/0425826fe89e0ad3111aee6cc352ad24d8c38525/konan/konan.properties#L409
v
Thanks
n
In that section the linuxArm64 target covers all ARM based CPUs that support the armv8 instruction set ( https://en.wikichip.org/wiki/arm/armv8 ), where an ARM 64 based Linux distribution is being run.
The ARM Cortex-A53 ( https://en.wikipedia.org/wiki/ARM_Cortex-A53 ) supports the armv8 instruction set, and no CLANG override needs to be applied (aka use as is).
v
Thanks!