cmake HAVE_TIMERFD examples

JulNadeauCA/libagar CMakeChecks.cmake :3349

check_c_source_compiles("
#include <sys/timerfd.h>

int
main(int argc, char *argv[])
{
	struct itimerspec its;
	int fd;

	if ((fd = timerfd_create(CLOCK_MONOTONIC, TFD_TIMER_ABSTIME)) != -1) {
		its.it_interval.tv_sec = 0;
		its.it_interval.tv_nsec = 0L;
		its.it_value.tv_sec = 0;
		its.it_value.tv_nsec = 0L;
		return (timerfd_settime(fd, 0, &its, NULL) == -1);
	}
	return (1);
}
" HAVE_TIMERFD)

aidanmcb1/Citra externals/libusb/CMakeLists.txt :132

check_function_exists(timerfd_create HAVE_TIMERFD)

feather-wallet/feather contrib/depends/patches/libusb/CMakeLists.txt :48

check_symbol_exists(timerfd_create  "sys/timerfd.h" HAVE_TIMERFD)