linux: adjust gettid visibility

gettid is currently available as a C++ symbol. This is because it usually does
not appear in standard libc headers. A lot of its callers go through the
syscall() path. But for us, since it is a global symbol, better have C linkage
than C++.

Signed-off-by: Glauber Costa <glommer@cloudius-systems.com>
Signed-off-by: Pekka Enberg <penberg@cloudius-systems.com>