diff --git a/buildtools/bdwgc/Dockerfile b/buildtools/bdwgc/Dockerfile index 293eb26..b2c0ffa 100644 --- a/buildtools/bdwgc/Dockerfile +++ b/buildtools/bdwgc/Dockerfile @@ -5,15 +5,13 @@ FROM ghcr.io/webassembly/wasi-sdk:wasi-sdk-20 RUN apt-get -y update && apt-get -y install curl patch -RUN mkdir -p /bdwgc && curl -L https://github.com/ivmai/bdwgc/archive/1d9826992aa2a2783c9badbacddae70fdf7fffee.tar.gz | tar -xz --strip-components 1 -C /bdwgc +RUN mkdir -p /bdwgc && curl -L https://github.com/ivmai/bdwgc/archive/a753bcb459649d20331d9c9f1dba94588ef56829.tar.gz | tar -xz --strip-components 1 -C /bdwgc WORKDIR /bdwgc ADD bdwgc.patch bdwgc.patch RUN patch -p1 < bdwgc.patch RUN ./autogen.sh -# While signals aren't actually used the header file is included unconditionally. We can enable the header file -# without linking the actual signals library because the functions aren't called. -ENV CFLAGS -O3 -D_WASI_EMULATED_SIGNAL ${CFLAGS} +ENV CFLAGS -O3 ${CFLAGS} # host is required by configure but not used so set it arbitrarily RUN ./configure --disable-threads --disable-shared --disable-gcj-support --disable-java-finalization --disable-atomic-uncollectible --host=i686-pc-linux-gnu diff --git a/buildtools/bdwgc/bdwgc.patch b/buildtools/bdwgc/bdwgc.patch index eaacd31..f5ff9df 100644 --- a/buildtools/bdwgc/bdwgc.patch +++ b/buildtools/bdwgc/bdwgc.patch @@ -11,16 +11,3 @@ index 6970e6f2..a3af3824 100644 # if defined(GC_THREADS) && !defined(CPPCHECK) # error No threads support yet # endif -@@ -3008,10 +3010,10 @@ EXTERN_C_BEGIN - - /* Whether GC_page_size is to be set to a value other than page size. */ - #if defined(CYGWIN32) && (defined(MPROTECT_VDB) || defined(USE_MUNMAP)) \ -- || (!defined(ANY_MSWIN) && !defined(USE_MMAP) \ -+ || (!defined(ANY_MSWIN) && !defined(WASI) && !defined(USE_MMAP) \ - && (defined(GC_DISABLE_INCREMENTAL) || defined(DEFAULT_VDB))) - /* Cygwin: use the allocation granularity instead. */ -- /* Other than Windows: use HBLKSIZE instead (unless mmap() is used). */ -+ /* Other than Windows or WASI: use HBLKSIZE instead (unless mmap() is used). */ - # define ALT_PAGESIZE_USED - # ifndef GC_NO_VALLOC - /* Nonetheless, we need the real page size is some extra functions. */ diff --git a/wasm/libgc.a b/wasm/libgc.a index e29744a..f7ed771 100644 Binary files a/wasm/libgc.a and b/wasm/libgc.a differ