diff options
author | alaviss <alaviss@users.noreply.github.com> | 2018-08-14 14:35:07 +0700 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2018-08-14 09:35:07 +0200 |
commit | 7ef268274f387530b85f5a9f704e0eda5a7aa022 (patch) | |
tree | da50f8c26a1e1f94b5d152a8cdaab87a3dddeb34 /config/nim.cfg | |
parent | feda366d86e723ff1877a1751cb3eadde8b00cb0 (diff) | |
download | Nim-7ef268274f387530b85f5a9f704e0eda5a7aa022.tar.gz |
Haiku support for Nim (#8542)
* posix_other: Haiku now has spawn.h This is added per https://dev.haiku-os.org/ticket/13446 * posix_other: Add Haiku specific Dirent members * cpuinfo: Add an implementation for Haiku * distros: Add basic Haiku support * encodings: update Haiku support * fenv, math: Haiku now provides libm * times: Add Haiku struct members * ansi_c, osalloc: Add Haiku constants * threads: Add Haiku support * testament: Haiku uses LIBRARY_PATH * nim.cfg: Update Haiku support libnetwork should only be linked if network functions are used * threads: Haiku does not support -pthread switch * tworkingdir: Haiku's env is in /bin * posix_other: add SIGKILLTHR for Haiku * sockets: link with libnetwork on Haiku * coro: correct ucontext.h location http://pubs.opengroup.org/onlinepubs/009696699/basedefs/ucontext.h.html * coro: ucontext backend is not available on Haiku Haiku doesn't provide the <ucontext.h> header, as it was removed from POSIX * coro: fix setjmp backend The compiler does not allow statements after a noreturn function * nativesockets: Haiku doesn't support AI_V4MAPPED * system: hostOS can contains "haiku" * os: add support for Haiku's packagefs packagefs is read-only, but there are writable holes to the underlying file system as well * os: update constant for Haiku
Diffstat (limited to 'config/nim.cfg')
-rw-r--r-- | config/nim.cfg | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/config/nim.cfg b/config/nim.cfg index c30190a18..af9df9c55 100644 --- a/config/nim.cfg +++ b/config/nim.cfg @@ -82,19 +82,21 @@ path="$lib/pure" clang.cpp.options.linker = "-ldl" tcc.options.linker = "-ldl" @end - @if 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 @end @if haiku: - # -fopenmp - gcc.options.linker = "-lroot -lnetwork" - gcc.cpp.options.linker = "-lroot -lnetwork" - clang.options.linker = "-lroot -lnetwork" - clang.cpp.options.linker = "-lroot -lnetwork" - tcc.options.linker = "-lroot -lnetwork" + # Haiku currently have problems with TLS + # https://dev.haiku-os.org/ticket/14342 + tlsEmulation:on + 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 |