diff options
author | Stéphane Loeuillet <gstreamer@leroutier.net> | 2004-05-20 19:19:26 +0000 |
---|---|---|
committer | Stéphane Loeuillet <gstreamer@leroutier.net> | 2004-05-20 19:19:26 +0000 |
commit | 1d94409129dca2d098002724440c2b41182ad98a (patch) | |
tree | 92e615f745330a7df8128df59423f217932837fc /m4 | |
parent | ab2ba3d0c956a8c33db138729824bfee4e0d5a89 (diff) | |
download | gstreamer-plugins-bad-1d94409129dca2d098002724440c2b41182ad98a.tar.gz |
test FIONREAD ioctl presence in an alternate header for Solaris 10 (and perhaps earlier versions)
Original commit message from CVS:
test FIONREAD ioctl presence in an alternate header for Solaris 10 (and perhaps earlier versions)
Diffstat (limited to 'm4')
-rw-r--r-- | m4/gst-fionread.m4 | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/m4/gst-fionread.m4 b/m4/gst-fionread.m4 new file mode 100644 index 000000000..820d5cea6 --- /dev/null +++ b/m4/gst-fionread.m4 @@ -0,0 +1,42 @@ +AC_DEFUN([HAVE_FIONREAD], [ + + AC_MSG_CHECKING(for FIONREAD in sys/ioctl.h) + AC_CACHE_VAL(GST_FIONREAD_IN_SYS_IOCTL, [ + AC_TRY_COMPILE([ +#include <sys/types.h> +#include <sys/ioctl.h> +], [ +int x = FIONREAD; +if ( x ) + return 0; + ], GST_FIONREAD_IN_SYS_IOCTL="yes",GST_FIONREAD_IN_SYS_IOCTL="no") + ]) + + AC_MSG_RESULT($GST_FIONREAD_IN_SYS_IOCTL) + + if test "$GST_FIONREAD_IN_SYS_IOCTL" = "yes"; then + AC_DEFINE([FIONREAD_IN_SYS_IOCTL], 1, [FIONREAD ioctl found in sys/ioclt.h]) + + else + + AC_MSG_CHECKING(for FIONREAD in sys/filio.h) + AC_CACHE_VAL(GST_FIONREAD_IN_SYS_FILIO, [ + AC_TRY_COMPILE([ + #include <sys/types.h> + #include <sys/filio.h> + ], [ + int x = FIONREAD; + if ( x ) + return 0; + ], GST_FIONREAD_IN_SYS_FILIO="yes",GST_FIONREAD_IN_SYS_FILIO="no") + ]) + + AC_MSG_RESULT($GST_FIONREAD_IN_SYS_FILIO) + + if test "$GST_FIONREAD_IN_SYS_FILIO" = "yes"; then + AC_DEFINE([FIONREAD_IN_SYS_FILIO], 1, [FIONREAD ioctl found in sys/filio.h]) + fi + + fi + +]) |