Hi all!
https://nim-lang.org/docs/nimc.html#cross-compilation says that it's possible to specify custom C compiler executable paths by setting variable values in the nim.cfg file. So i'd write something like
arm64.android.gcc.path=<path>
in nim.cfg. However, my project is using config.nims instead. What would be the equivalent of the above, but for config.nims?
Thanks in advance!
Hey! The nimscript way of doing this is put(key, value)
For example in my project I'm doing:
put "arm.standalone.gcc.path", getEnv("DEVKITARM") & "/bin"
put "arm.standalone.gcc.exe", "arm-none-eabi-gcc"
Thanks @exelotl, you rock! Worked flawlessly, I've just added this to config.nims and voila:
put "arm64.android.clang.path", getEnv("ANDROID_NDK") & "/toolchains/llvm/prebuilt/darwin-x86_64/bin"
put "arm64.android.clang.exe", "clang"
switch("passC", "-isysroot " & getEnv("ANDROID_NDK") & "/sysroot -target aarch64-linux-android23")