41 lines
540 B
Makefile
41 lines
540 B
Makefile
VPATH+= ${TOPDIR}/event
|
|
|
|
SRCS+= event_system.cc
|
|
SRCS+= io_service.cc
|
|
|
|
ifndef USE_POLL
|
|
ifeq "${OSNAME}" "Darwin"
|
|
USE_POLL= kqueue
|
|
endif
|
|
|
|
ifeq "${OSNAME}" "FreeBSD"
|
|
USE_POLL= kqueue
|
|
endif
|
|
|
|
ifeq "${OSNAME}" "OpenBSD"
|
|
USE_POLL= kqueue
|
|
endif
|
|
|
|
ifeq "${OSNAME}" "Linux"
|
|
USE_POLL= epoll
|
|
endif
|
|
|
|
ifeq "${OSNAME}" "Interix"
|
|
USE_POLL= select
|
|
endif
|
|
|
|
ifeq "${OSNAME}" "SunOS"
|
|
USE_POLL= port
|
|
endif
|
|
|
|
ifndef USE_POLL
|
|
USE_POLL= poll
|
|
endif
|
|
endif
|
|
|
|
ifeq "${OSNAME}" "Linux"
|
|
# Required for clock_gettime(3).
|
|
LDADD+= -lrt
|
|
endif
|
|
|
|
SRCS+= event_poll_${USE_POLL}.cc
|