aboutsummaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorRiku Voipio <riku.voipio@linaro.org>2014-06-22 11:25:42 +0100
committerRiku Voipio <riku.voipio@linaro.org>2014-08-22 15:06:33 +0300
commit518343413fd311a3d95798b2c1d51853fd8d3c85 (patch)
treed0b8b5929b946a3cdccd40d4399e24c47eef9e5b /configure
parentf17f4989fa193fa8279474c5462289a3cfe69aea (diff)
linux-user: support timerfd_{create, gettime, settime} syscalls
Adds support for the timerfd_create, timerfd_gettime & timerfd_settime syscalls, allowing use of timerfds by target programs. v2: By Riku - added configure check for timerfd and ifdefs for benefit of old distributions like RHEL5. Signed-off-by: Paul Burton <paul@archlinuxmips.org> Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure17
1 files changed, 17 insertions, 0 deletions
diff --git a/configure b/configure
index 283c71cb7a..3d0ab1b193 100755
--- a/configure
+++ b/configure
@@ -3456,6 +3456,20 @@ if compile_prog "" "" ; then
sendfile=yes
fi
+# check for timerfd support (glibc 2.8 and newer)
+timerfd=no
+cat > $TMPC << EOF
+#include <sys/timerfd.h>
+
+int main(void)
+{
+ return(timerfd_create(CLOCK_REALTIME, 0));
+}
+EOF
+if compile_prog "" "" ; then
+ timerfd=yes
+fi
+
# Check if tools are available to build documentation.
if test "$docs" != "no" ; then
if has makeinfo && has pod2man; then
@@ -4524,6 +4538,9 @@ fi
if test "$sendfile" = "yes" ; then
echo "CONFIG_SENDFILE=y" >> $config_host_mak
fi
+if test "$timerfd" = "yes" ; then
+ echo "CONFIG_TIMERFD=y" >> $config_host_mak
+fi
if test "$inotify" = "yes" ; then
echo "CONFIG_INOTIFY=y" >> $config_host_mak
fi