diff options
author | Rodrigo Kumpera <kumpera@users.noreply.github.com> | 2017-09-08 21:55:38 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-09-08 21:55:38 +0300 |
commit | 098f6e8aa8ead1a80b751fa34e5e049439c2f0c3 (patch) | |
tree | e8e1ea0c466144f38f2701b7e841a0deb1385086 /configure.ac | |
parent | d96de323da8d7d9561ecbb5c2ebcdeb23ee1ee2e (diff) | |
parent | 0f0b9c2913f0ca8f700378c22cd28485ae52efeb (diff) |
Merge pull request #5428 from kumpera/wasm-support-p2
Mono Wasm support
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 23 |
1 files changed, 16 insertions, 7 deletions
diff --git a/configure.ac b/configure.ac index c2d59d88407..bad8ecc8e3c 100644 --- a/configure.ac +++ b/configure.ac @@ -117,8 +117,8 @@ host_darwin=no if test "x$enable_wasm" = "xyes"; then -CFLAGS="$CFLAGS -D_REENTRANT -D_GNU_SOURCE -DNO_UNALIGNED_ACCESS -s WASM=1 -DWASM -Os" -CPPFLAGS="$CPPFLAGS -D_REENTRANT -DUSE_MMAP -D_GNU_SOURCE -DNO_UNALIGNED_ACCESS -s WASM=1 -DWASM -Os" +CFLAGS="$CFLAGS -D_REENTRANT -D_GNU_SOURCE -DNO_UNALIGNED_ACCESS -s WASM=1" +CPPFLAGS="$CPPFLAGS -D_REENTRANT -DUSE_MMAP -D_GNU_SOURCE -DNO_UNALIGNED_ACCESS -s WASM=1" libdl="-ldl" libgc_threads=pthreads @@ -555,7 +555,18 @@ AC_CHECK_FUNCS(_finite, , AC_MSG_CHECKING(for _finite in math.h) AC_CHECK_HEADERS(linux/magic.h) # not 64 bit clean in cross-compile -AC_CHECK_SIZEOF(void *, 4) +if test "x$enable_wasm" = "xyes"; then +AC_DEFINE(SIZEOF_VOID_P,4) +AC_DEFINE(SIZEOF_LONG,4) +ac_cv_sizeof_void_p="4" +ac_cv_sizeof_long="4" +else +AC_CHECK_SIZEOF(void *) +AC_CHECK_SIZEOF(long) +fi + +AC_CHECK_SIZEOF(int) +AC_CHECK_SIZEOF(long long) AC_CACHE_CHECK([for clang], mono_cv_clang,[ @@ -3067,6 +3078,7 @@ TARGET=WASM HOST=WASM arch_target=wasm AC_DEFINE(TARGET_WASM, 1, [Target wasm]) +AC_DEFINE(HOST_WASM, 1, [Host wasm]) BTLS_SUPPORTED=no with_tls=pthread target_mach=no @@ -3752,10 +3764,6 @@ AC_SUBST(PIDTYPE) 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) -AC_CHECK_SIZEOF(long long) AC_CHECK_FUNCS(strlcpy stpcpy strtok_r rewinddir vasprintf strerror_r) AC_CHECK_FUNCS(getrlimit) AC_CHECK_FUNCS(fork execv execve) @@ -4342,6 +4350,7 @@ AM_CONDITIONAL(POWERPC64, test x$TARGET = xPOWERPC64) AM_CONDITIONAL(ARM, test x$TARGET = xARM) AM_CONDITIONAL(ARM64, test x$TARGET = xARM64) AM_CONDITIONAL(S390X, test x$TARGET = xS390X) +AM_CONDITIONAL(WASM, test x$TARGET = xWASM) AM_CONDITIONAL(HOST_X86, test x$HOST = xX86) AM_CONDITIONAL(HOST_AMD64, test x$HOST = xAMD64) AM_CONDITIONAL(HOST_ARM, test x$HOST = xARM) |