cmake HAVE_CLOCK_SYSCALL examples

asset-group/5ghoul-5g-nr-attacks libs/react-cpp/libev/CMakeLists.txt :61

check_c_source_compiles("\
            #include <unistd.h>\n\
            #include <sys/syscall.h>\n\
            #include <time.h>\n\
            int main(int argc, char *argv[])\n\
            {\n\
                (void) argc;\n\
                (void) argv;\n\
                struct timespec ts;\n\
                int status = syscall (SYS_clock_gettime, CLOCK_REALTIME, &ts);\n\
                return status;\n\
            }\
            "
            HAVE_CLOCK_SYSCALL
        )