another attempt to getThreadId work on Linux

This commit is contained in:
araq
2017-01-31 15:44:11 +01:00
parent eaa0eda72d
commit bd580e9d6e

View File

@@ -195,7 +195,7 @@ else:
importc: "pthread_setaffinity_np", header: pthreadh.}
when defined(linux):
proc syscall(arg: int): int {.varargs, importc: "syscall", header: "<sys/syscall.h>".}
proc syscall(arg: int): int {.varargs, importc: "syscall", header: "<unistd.h>".}
var SYS_gettid {.importc, header: "<sys/syscall.h>".}: int
#type Pid {.importc: "pid_t", header: "<sys/types.h>".} = distinct int