X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=blobdiff_plain;f=eglib%2Fconfigure.ac;h=89f85d18e590434088b672fc593b3f2012052ead;hb=fe0b8311e7cb09d8251b27671550b6cb131806dc;hp=2197c6f9c96605404f19ee9bc6b0b038f94986fb;hpb=ccdf8c3274d1793ffeddedfd784d49707feea62a;p=mono.git diff --git a/eglib/configure.ac b/eglib/configure.ac index 2197c6f9c96..89f85d18e59 100644 --- a/eglib/configure.ac +++ b/eglib/configure.ac @@ -130,6 +130,10 @@ AM_CONDITIONAL(TARGET_WIN32, test x$OS = xWIN32) AM_CONDITIONAL(PLATFORM_DARWIN, test x$platform_darwin = xyes) AM_CONDITIONAL(PLATFORM_ANDROID, test x$platform_android = xyes) +# Defined for all targets/platforms using classic Windows API support. +AC_DEFINE(HAVE_CLASSIC_WINAPI_SUPPORT, 1, [Use classic Windows API support]) +AC_DEFINE(HAVE_UWP_WINAPI_SUPPORT, 0, [Don't use UWP Windows API support]) + AC_CHECK_SIZEOF(int) AC_CHECK_SIZEOF(void *) AC_CHECK_SIZEOF(long) @@ -138,6 +142,15 @@ AC_CHECK_FUNCS(strlcpy stpcpy strtok_r rewinddir vasprintf) AC_CHECK_FUNCS(getrlimit) AC_CHECK_FUNCS(fork execv execve) +AC_ARG_WITH([overridable-allocators], [ --with-overridable-allocators allow g_*alloc/g_free to call custom allocators set via g_mem_set_vtable]) + +if test x$with_overridable_allocators = xyes; then + AC_DEFINE(ENABLE_OVERRIDABLE_ALLOCATORS,1,[Overridable allocator support enabled]) + AC_MSG_NOTICE([Overridable allocator support enabled]) +else + AC_MSG_NOTICE([Overridable allocator support disabled]) +fi + # # Mono currently supports 10.6, but strndup is not available prior to 10.7; avoiding # the detection of strndup on OS X so Mono built on 10.7+ still runs on 10.6. This can be @@ -151,7 +164,7 @@ elif test x$target_ios = xno; then AC_CHECK_FUNCS(strndup getpwuid_r) fi -AM_CONDITIONAL(NEED_VASPRINTF, test x$ac_cv_func_vasprintf = xno ) +AM_CONDITIONAL(NEED_VASPRINTF, test x$ac_cv_func_vasprintf = xno || test x$with_overridable_allocators = xyes) AM_ICONV() AC_SEARCH_LIBS(sqrtf, m) @@ -181,7 +194,7 @@ if test "x$have_iso_varargs" = "xyes"; then fi AC_SUBST(G_HAVE_ISO_VARARGS) -AC_CHECK_HEADERS(getopt.h sys/select.h sys/time.h sys/wait.h pwd.h langinfo.h iconv.h localcharset.h sys/types.h sys/resource.h) +AC_CHECK_HEADERS(getopt.h sys/select.h sys/time.h sys/wait.h pwd.h iconv.h localcharset.h sys/types.h sys/resource.h) AC_CHECK_LIB([iconv], [locale_charset],[],[AC_CHECK_LIB([charset], [locale_charset],[LIBS+="-liconv -lcharset"])]) AC_CHECK_HEADER(alloca.h, [HAVE_ALLOCA_H=1], [HAVE_ALLOCA_H=0]) AC_SUBST(HAVE_ALLOCA_H) @@ -193,10 +206,6 @@ if test $ac_cv_sizeof_void_p = $ac_cv_sizeof_int; then GUINT_TO_POINTER="((gpointer) (v))" GSIZE="int" GSIZE_FORMAT='"u"' - G_GUINT64_FORMAT='"llu"' - G_GINT64_FORMAT='"lld"' - G_GUINT32_FORMAT='"lu"' - G_GINT32_FORMAT='"ld"' elif test $ac_cv_sizeof_void_p = $ac_cv_sizeof_long; then GPOINTER_TO_INT="((gint)(long) (ptr))" GPOINTER_TO_UINT="((guint)(long) (ptr))" @@ -204,10 +213,6 @@ elif test $ac_cv_sizeof_void_p = $ac_cv_sizeof_long; then GUINT_TO_POINTER="((gpointer)(gulong) (v))" GSIZE="long" GSIZE_FORMAT='"lu"' - G_GUINT64_FORMAT='"lu"' - G_GINT64_FORMAT='"ld"' - G_GUINT32_FORMAT='"u"' - G_GINT32_FORMAT='"d"' elif test $ac_cv_sizeof_void_p = $ac_cv_sizeof_long_long; then GPOINTER_TO_INT="((gint)(long long) (ptr))" GPOINTER_TO_UINT="((guint)(unsigned long long) (ptr))" @@ -215,10 +220,6 @@ elif test $ac_cv_sizeof_void_p = $ac_cv_sizeof_long_long; then GUINT_TO_POINTER="((gpointer)(unsigned long long) (v))" GSIZE="long long" GSIZE_FORMAT='"I64u"' - G_GUINT64_FORMAT='"I64u"' - G_GINT64_FORMAT='"I64i"' - G_GUINT32_FORMAT='"I32u"' - G_GINT32_FORMAT='"I32i"' else AC_MSG_ERROR([unsupported pointer size]) fi