Merge pull request #556 from jack-pappas/ipproto-patch
authorMiguel de Icaza <miguel@gnome.org>
Fri, 22 Feb 2013 21:22:36 +0000 (13:22 -0800)
committerMiguel de Icaza <miguel@gnome.org>
Fri, 22 Feb 2013 21:22:36 +0000 (13:22 -0800)
Added checks for BSD-compliant protocol constants.

1  2 
configure.in

diff --combined configure.in
index f01073312cef7500808f8c5ab0d14719415b9d74,6f8db16e078b827507a29414f4786d5bc7ef88dd..783fa0f074edd6d7bc704f8dea33dee6a005328f
@@@ -1,7 -1,7 +1,7 @@@
  # Process this file with autoconf to produce a configure script.
  #AC_PREREQ([2.62])
  
 -AC_INIT(mono, [3.0.4],
 +AC_INIT(mono, [3.0.5],
          [http://bugzilla.xamarin.com/enter_bug.cgi?classification=Mono])
  
  AC_CONFIG_SRCDIR([README])
@@@ -734,7 -734,7 +734,7 @@@ AC_ARG_ENABLE(system-aot, [  --enable-s
  DISABLED_FEATURES=none
  
  AC_ARG_ENABLE(minimal, [  --enable-minimal=LIST      drop support for LIST subsystems.
 -     LIST is a comma-separated list from: aot, profiler, decimal, pinvoke, debug,
 +     LIST is a comma-separated list from: aot, profiler, decimal, pinvoke, debug, appdomains, verifier, 
       reflection_emit, reflection_emit_save, large_code, logging, com, ssa, generics, attach, jit, simd, soft_debug, perfcounters, normalization, assembly_remapping, shared_perfcounters,
         sgen_remset, sgen_marksweep_par, sgen_marksweep_fixed, sgen_marksweep_fixed_par, sgen_copying.],
  [
@@@ -870,11 -870,6 +870,11 @@@ if test "x$mono_feature_disable_shared_
        AC_MSG_NOTICE([Disabled Shared perfcounters.])
  fi
  
 +if test "x$mono_feature_disable_appdomains" = "xyes"; then
 +      AC_DEFINE(DISABLE_APPDOMAINS, 1, [Disable support for multiple appdomains.])
 +      AC_MSG_NOTICE([Disabled support for multiple appdomains.])
 +fi
 +
  if test "x$mono_feature_disable_sgen_remset" = "xyes"; then
        AC_DEFINE(DISABLE_SGEN_REMSET, 1, [Disable wbarrier=remset support in SGEN.])
        AC_MSG_NOTICE([Disabled wbarrier=remset support in SGEN.])
@@@ -1231,6 -1226,51 +1231,51 @@@ if test x$target_win32 = xno; the
                AC_MSG_RESULT(no)
        ])
  
+       dnl *****************************
+       dnl *** Checks for IPPROTO_IP ***
+       dnl *****************************
+       AC_MSG_CHECKING(for IPPROTO_IP)
+       AC_TRY_COMPILE([#include <netinet/in.h>], [
+               int level = IPPROTO_IP;
+       ], [
+               # Yes, we have it...
+               AC_MSG_RESULT(yes)
+               AC_DEFINE(HAVE_IPPROTO_IP, 1, [Have IPPROTO_IP])
+       ], [
+               # We'll have to use getprotobyname
+               AC_MSG_RESULT(no)
+       ])
+       dnl *******************************
+       dnl *** Checks for IPPROTO_IPV6 ***
+       dnl *******************************
+       AC_MSG_CHECKING(for IPPROTO_IPV6)
+       AC_TRY_COMPILE([#include <netinet/in.h>], [
+               int level = IPPROTO_IPV6;
+       ], [
+               # Yes, we have it...
+               AC_MSG_RESULT(yes)
+               AC_DEFINE(HAVE_IPPROTO_IPV6, 1, [Have IPPROTO_IPV6])
+       ], [
+               # We'll have to use getprotobyname
+               AC_MSG_RESULT(no)
+       ])
+       dnl ******************************
+       dnl *** Checks for IPPROTO_TCP ***
+       dnl ******************************
+       AC_MSG_CHECKING(for IPPROTO_TCP)
+       AC_TRY_COMPILE([#include <netinet/in.h>], [
+               int level = IPPROTO_TCP;
+       ], [
+               # Yes, we have it...
+               AC_MSG_RESULT(yes)
+               AC_DEFINE(HAVE_IPPROTO_TCP, 1, [Have IPPROTO_TCP])
+       ], [
+               # We'll have to use getprotobyname
+               AC_MSG_RESULT(no)
+       ])
        dnl *****************************
        dnl *** Checks for SOL_IP     ***
        dnl *****************************
        dnl *** Checks for IP_PKTINFO ***
        dnl *****************************
        AC_MSG_CHECKING(for IP_PKTINFO)
-       AC_TRY_COMPILE([#include <netdb.h>], [
+       AC_TRY_COMPILE([#include <linux/in.h>], [
                int level = IP_PKTINFO;
        ], [
                # Yes, we have it...
                AC_MSG_RESULT(no)
        ])
  
+       dnl **********************************
+       dnl *** Checks for IP_DONTFRAG     ***
+       dnl **********************************
+       AC_MSG_CHECKING(for IP_DONTFRAG)
+       AC_TRY_COMPILE([#include <netinet/in.h>], [
+               int level = IP_DONTFRAG;
+       ], [
+               # Yes, we have it...
+               AC_MSG_RESULT(yes)
+               AC_DEFINE(HAVE_IP_DONTFRAG, 1, [Have IP_DONTFRAG])
+       ], [
+               AC_MSG_RESULT(no)
+       ])
        dnl **********************************
        dnl *** Checks for IP_DONTFRAGMENT ***
        dnl **********************************
        AC_MSG_CHECKING(for IP_DONTFRAGMENT)
-       AC_TRY_COMPILE([#include <netdb.h>], [
+       AC_TRY_COMPILE([#include <Ws2ipdef.h>], [
                int level = IP_DONTFRAGMENT;
        ], [
                # Yes, we have it...
        dnl *** Checks for IP_MTU_DISCOVER ***
        dnl **********************************
        AC_MSG_CHECKING(for IP_MTU_DISCOVER)
-       AC_TRY_COMPILE([#include <netdb.h>], [
+       AC_TRY_COMPILE([#include <linux/in.h>], [
                int level = IP_MTU_DISCOVER;
        ], [
                # Yes, we have it...
                AC_MSG_RESULT(no)
        ])
  
+       dnl **********************************
+       dnl *** Checks for  IP_PMTUDISC_DO ***
+       dnl **********************************
+       AC_MSG_CHECKING(for IP_PMTUDISC_DO)
+       AC_TRY_COMPILE([#include <linux/in.h>], [
+               int level = IP_PMTUDISC_DO;
+       ], [
+               # Yes, we have it...
+               AC_MSG_RESULT(yes)
+               AC_DEFINE(HAVE_IP_PMTUDISC_DO, 1, [Have IP_PMTUDISC_DO])
+       ], [
+               AC_MSG_RESULT(no)
+       ])
        dnl *********************************
        dnl *** Check for struct ip_mreqn ***
        dnl *********************************
@@@ -3459,4 -3527,4 +3532,4 @@@ echo 
  "
  if test x$with_static_mono = xno -a "x$host_win32" != "xyes"; then
     AC_MSG_WARN(Turning off static Mono is a risk, you might run into unexpected bugs)
 -fi
 +fi