1 #include <time.h> 2 #include <errno.h> 3 #include <string.h> 4 #include "test.h" 5 6 #define TEST(c, ...) \ 7 ( (c) || (t_error(#c " failed: " __VA_ARGS__),0) ) 8 9 extern int __clock_gettime64(clockid_t, struct timespec *); 10 mainnull11int main() 12 { 13 struct timespec ts; 14 TEST(clock_gettime(CLOCK_REALTIME, &ts) == 0 && errno == 0, "%s\n", strerror(errno)); 15 TEST(__clock_gettime64(CLOCK_REALTIME, &ts) == 0 && errno == 0, "%s\n", strerror(errno)); 16 return t_status; 17 } 18