[corlib] Disable ThreadLocalTests.DisposeOnThreadExit on MonoTouch, it's randomly...
[mono.git] / configure.ac
index 5da2a242f3a7c68dc908294676b129a701670c0f..da4c798818d193a4b209575ad15978db82305de5 100644 (file)
@@ -546,7 +546,7 @@ if test x"$GCC" = xyes; then
                if test "x$mono_cv_clang" = "xyes"; then
                   # https://bugzilla.samba.org/show_bug.cgi?id=8118
                   WARN="$WARN -Qunused-arguments"
-                  WARN="$WARN -Wno-unused-function -Wno-tautological-compare -Wno-parentheses-equality -Wno-self-assign -Wno-return-stack-address"
+                  WARN="$WARN -Wno-unused-function -Wno-tautological-compare -Wno-parentheses-equality -Wno-self-assign -Wno-return-stack-address -Wno-constant-logical-operand"
                fi
 else
        # The Sun Forte compiler complains about inline functions that access static variables
@@ -2078,6 +2078,7 @@ if test x$host_win32 = xno; then
        AC_CHECK_FUNCS(setpgid)
        AC_CHECK_FUNCS(system)
        AC_CHECK_FUNCS(fork execv execve)
+       AC_CHECK_FUNCS(accept4)
        AC_CHECK_SIZEOF(size_t)
        AC_CHECK_TYPES([blksize_t], [AC_DEFINE(HAVE_BLKSIZE_T)], , 
                [#include <sys/types.h>
@@ -2089,6 +2090,8 @@ if test x$host_win32 = xno; then
                 #include <unistd.h>])
        AC_CHECK_TYPES([suseconds_t], [AC_DEFINE(HAVE_SUSECONDS_T)], ,
                [#include <sys/time.h>])
+       AC_CHECK_TYPES([struct cmsghdr], [AC_DEFINE(HAVE_STRUCT_CMSGHDR)], ,
+               [#include <sys/socket.h>])
        AC_CHECK_TYPES([struct flock], [AC_DEFINE(HAVE_STRUCT_FLOCK)], ,
                [#include <unistd.h>
                 #include <fcntl.h>])
@@ -2098,6 +2101,16 @@ if test x$host_win32 = xno; then
                [#include <sys/socket.h>])
        AC_CHECK_TYPES([struct pollfd], [AC_DEFINE(HAVE_STRUCT_POLLFD)], ,
                [#include <sys/poll.h>])
+       AC_CHECK_TYPES([struct sockaddr], [AC_DEFINE(HAVE_STRUCT_SOCKADDR)], ,
+               [#include <sys/socket.h>])
+       AC_CHECK_TYPES([struct sockaddr_storage], [AC_DEFINE(HAVE_STRUCT_SOCKADDR_STORAGE)], ,
+               [#include <sys/socket.h>])
+       AC_CHECK_TYPES([struct sockaddr_in], [AC_DEFINE(HAVE_STRUCT_SOCKADDR_IN)], ,
+               [#include <netinet/in.h>])
+       AC_CHECK_TYPES([struct sockaddr_in6], [AC_DEFINE(HAVE_STRUCT_SOCKADDR_IN6)], ,
+               [#include <netinet/in.h>])
+       AC_CHECK_TYPES([struct sockaddr_un], [AC_DEFINE(HAVE_STRUCT_SOCKADDR_UN)], ,
+               [#include <sys/un.h>])
        AC_CHECK_TYPES([struct stat], [AC_DEFINE(HAVE_STRUCT_STAT)], ,
                [#include <sys/types.h>
                 #include <sys/stat.h>
@@ -3519,6 +3532,29 @@ AC_ARG_WITH(checked_build, [  --with-checked-build=yes|no      Enable checked bu
        fi
 ], [with_checked_build=no])
 
+if test x$with_checked_build != xno ; then
+       DISABLED_CHECKED_BUILD_TEST=none
+
+       AC_ARG_ENABLE(checked_build_test, [  --enable-checked-build-test=LIST      drop support for LIST checked build tests. LIST is a comma-separated list from: gc, metadata, thread.],
+       [
+               for feature in `echo "$enable_checked_build_test" | sed -e "s/,/ /g"`; do
+                       eval "mono_checked_build_test_disable_$feature='yes'"
+               done
+               DISABLED_CHECKED_BUILD_TEST=$enable_checked_build_test
+       ],[])
+
+       if test "x$mono_checked_build_test_disable_gc" = "xyes"; then
+               AC_DEFINE(DISABLE_CHECKED_BUILD_GC, 1, [Disable GC checked build])
+       fi
+
+       if test "x$mono_checked_build_test_disable_metadata" = "xyes"; then
+               AC_DEFINE(DISABLE_CHECKED_BUILD_METADATA, 1, [Disable metadata checked build])
+       fi
+
+       if test "x$mono_checked_build_test_disable_thread" = "xyes"; then
+               AC_DEFINE(DISABLE_CHECKED_BUILD_THREAD, 1, [Disable thread checked build])
+       fi
+fi
 
 AC_CHECK_HEADER([malloc.h], 
                [AC_DEFINE([HAVE_USR_INCLUDE_MALLOC_H], [1], 
@@ -3615,6 +3651,9 @@ AC_SUBST(CFLAGS)
 AC_SUBST(CPPFLAGS)
 AC_SUBST(LDFLAGS)
 
+#This must always be defined when building the runtime
+AC_DEFINE(MONO_INSIDE_RUNTIME,1, [Disable banned functions from being used by the runtime])
+
 mono_build_root=`pwd`
 AC_SUBST(mono_build_root)