-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Description
On OpenBSD, posix.Time is defined as a clong (due to posix_other.nim), where OpenBSD defines it as a __int64_t which is long long on AMD64.
This results in errors like below:
/home/build/.cache/nim/tasync_cpp_d/stdlib_times.nim.cpp:1509:19: error: no matching function for call to 'localtime'
struct tm* T2_ = localtime((&a));
^~~~~~~~~
/usr/include/time.h:131:12: note: candidate function not viable: no known conversion from 'long *' to 'const time_t *' (aka 'const long long *') for 1st argument
struct tm *localtime(const time_t *);
Note that it looks like FreeBSD may also be the same under certain circumstances, though I'm not sure?
Possible Solution
A new posix_openbsd_amd64 module should be added to define time_t correctly, along with any other different values.