You are not logged in.
I hope I am posting this in the right forum, please move it (or let me know where to repost it) if this isn't the correct place.
About https://archlinux.org/packages/extra/x86_64/nim/
The default config file (/etc/nim/nim.cfg) has these two lines at the bottom:
gcc.options.always %= "${gcc.options.always} -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection "
gcc.options.linker %= "${gcc.options.linker} -Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now"
This is only ok when Nim is using gcc to build Linux binaries, but it doesn't work when compiling Windows binaries with mingw because of the -z option which is not supported there.
To solve this: please change it to:
@if linux:
gcc.options.always ...
gcc.options.linker ...
@end
Make sure you use spaces, not tabs.
Last edited by scippie (2024-03-28 15:23:52)
Offline