diff --git a/config/nim.cfg b/config/nim.cfg index a33a2f0a9..83caf8a2b 100644 --- a/config/nim.cfg +++ b/config/nim.cfg @@ -111,7 +111,18 @@ path="$lib/pure" @end @if unix: - @if not bsd or haiku: + @if bsd: + # BSD got posix_spawn only recently, so we deactivate it for osproc: + define:useFork + # at least NetBSD has problems with thread local storage: + tlsEmulation:on + @elif haiku: + gcc.options.linker = "-Wl,--as-needed -lnetwork" + gcc.cpp.options.linker = "-Wl,--as-needed -lnetwork" + clang.options.linker = "-Wl,--as-needed -lnetwork" + clang.cpp.options.linker = "-Wl,--as-needed -lnetwork" + tcc.options.linker = "-Wl,--as-needed -lnetwork" + @else: # -fopenmp gcc.options.linker = "-ldl" gcc.cpp.options.linker = "-ldl" @@ -119,19 +130,6 @@ path="$lib/pure" clang.cpp.options.linker = "-ldl" tcc.options.linker = "-ldl" @end - @if bsd: - # BSD got posix_spawn only recently, so we deactivate it for osproc: - define:useFork - # at least NetBSD has problems with thread local storage: - tlsEmulation:on - @end - @if haiku: - gcc.options.linker = "-Wl,--as-needed -lnetwork" - gcc.cpp.options.linker = "-Wl,--as-needed -lnetwork" - clang.options.linker = "-Wl,--as-needed -lnetwork" - clang.cpp.options.linker = "-Wl,--as-needed -lnetwork" - tcc.options.linker = "-Wl,--as-needed -lnetwork" - @end @end @if android: