diff --git a/Makefile b/Makefile index e56447d..e0f25cb 100644 --- a/Makefile +++ b/Makefile @@ -243,6 +243,11 @@ override MUSL_OMIT_HEADERS += \ "bits/alltypes.h.in" \ "alltypes.h.in" +# Use the compiler's version of these headers. +override MUSL_OMIT_HEADERS += \ + "stdarg.h" \ + "stddef.h" + # Use the WASI errno definitions. override MUSL_OMIT_HEADERS += \ "bits/errno.h" diff --git a/expected/wasm32-wasi/include-all.c b/expected/wasm32-wasi/include-all.c index 3ca0641..535c920 100644 --- a/expected/wasm32-wasi/include-all.c +++ b/expected/wasm32-wasi/include-all.c @@ -120,10 +120,8 @@ #include #include #include -#include #include #include -#include #include #include #include diff --git a/expected/wasm32-wasi/predefined-macros.txt b/expected/wasm32-wasi/predefined-macros.txt index 77b965a..87bdca0 100644 --- a/expected/wasm32-wasi/predefined-macros.txt +++ b/expected/wasm32-wasi/predefined-macros.txt @@ -2370,7 +2370,6 @@ #define _STDALIGN_H #define _STDBOOL_H #define _STDC_PREDEF_H -#define _STDDEF_H #define _STDINT_H #define _STDIO_EXT_H #define _STDIO_H diff --git a/libc-top-half/musl/include/stdarg.h b/libc-top-half/musl/include/stdarg.h index 0c69316..3256f80 100644 --- a/libc-top-half/musl/include/stdarg.h +++ b/libc-top-half/musl/include/stdarg.h @@ -1,4 +1,3 @@ -#ifdef __wasilibc_unmodified_upstream /* Use the compiler's stdarg.h */ #ifndef _STDARG_H #define _STDARG_H @@ -20,7 +19,3 @@ extern "C" { #endif #endif -#else -/* Just use the compiler's stdarg.h. */ -#include_next -#endif diff --git a/libc-top-half/musl/include/stddef.h b/libc-top-half/musl/include/stddef.h index 9cad1af..bd75385 100644 --- a/libc-top-half/musl/include/stddef.h +++ b/libc-top-half/musl/include/stddef.h @@ -1,4 +1,3 @@ -#ifdef __wasilibc_unmodified_upstream /* Use the compiler's stddef.h */ #ifndef _STDDEF_H #define _STDDEF_H @@ -24,14 +23,3 @@ #endif #endif -#else - -/* Just use the compiler's stddef.h. */ -#include_next - -/* Define musl's include guard, in case any code depends on that. */ -#if defined(__STDDEF_H) && !defined(_STDDEF_H) -#define _STDDEF_H -#endif - -#endif