]> git.proxmox.com Git - wasi-libc.git/commitdiff
Remove more unsupported headers. (#123)
authorDan Gohman <sunfish@mozilla.com>
Mon, 4 Nov 2019 21:17:03 +0000 (13:17 -0800)
committerGitHub <noreply@github.com>
Mon, 4 Nov 2019 21:17:03 +0000 (13:17 -0800)
utime.h, sysmacros.h, and libintl.h are all currently unsupported.
Removing them helps programs that autodetect features based on the
existence of headers.

Makefile
expected/wasm32-wasi/include-all.c
expected/wasm32-wasi/predefined-macros.txt

index ee8e8e8437e912b5a7fd3a22915c6bc175d06a88..1670153633e8463b108d0999fce19f4c3ab54fb9 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -305,7 +305,10 @@ override MUSL_OMIT_HEADERS += \
     "net/route.h" \
     "netinet/if_ether.h" \
     "netinet/ether.h" \
-    "sys/timerfd.h"
+    "sys/timerfd.h" \
+    "libintl.h" \
+    "sys/sysmacros.h" \
+    "utime.h"
 
 ifeq ($(THREAD_MODEL), single)
 # Remove headers not supported in single-threaded mode.
index 535c920ee3488eafb59d7333b735da644e6c14ed..c9b6fa084f9d13793d369797e2eaf5631be63a7b 100644 (file)
@@ -94,7 +94,6 @@
 #include <iso646.h>
 #include <langinfo.h>
 #include <libgen.h>
-#include <libintl.h>
 #include <limits.h>
 #include <locale.h>
 #include <malloc.h>
 #include <sys/stropts.h>
 #include <sys/syscall.h>
 #include <sys/sysinfo.h>
-#include <sys/sysmacros.h>
 #include <sys/time.h>
 #include <sys/timeb.h>
 #include <sys/times.h>
 #include <time.h>
 #include <uchar.h>
 #include <unistd.h>
-#include <utime.h>
 #include <values.h>
 #include <wasi/core.h>
 #include <wasi/libc-find-relpath.h>
index b4c9fcca9ba784313e5d938172f3dd2e740eab28..52ce3ceeb35d15151fb13e7c58691280000a452f 100644 (file)
 #define _ISO646_H 
 #define _LANGINFO_H 
 #define _LIBGEN_H 
-#define _LIBINTL_H 
 #define _LIMITS_H 
 #define _LOCALE_H 
 #define _MALLOC_H 
 #define _SYS_STAT_H 
 #define _SYS_SYSCALL_H 
 #define _SYS_SYSINFO_H 
-#define _SYS_SYSMACROS_H 
 #define _SYS_TIMEB_H 
 #define _SYS_TIMES_H 
 #define _SYS_TIMEX_H 
 #define _TIME_H 
 #define _UCHAR_H 
 #define _UNISTD_H 
-#define _UTIME_H 
 #define _VALUES_H 
 #define _VA_LIST 
 #define _WCHAR_H 
 #define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2
 #define __GNUC_STDC_INLINE__ 1
 #define __GNUC_VA_LIST 1
-#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 1 : -1)
 #define __GXX_ABI_VERSION 1002
 #define __ILP32__ 1
 #define __INT16_C_SUFFIX__ 
 #define __UINT_LEAST8_MAX__ 255
 #define __UINT_LEAST8_TYPE__ unsigned char
 #define __USER_LABEL_PREFIX__ 
-#define __USE_GNU_GETTEXT 1
 #define __WASI_ADVICE_DONTNEED (UINT8_C(4))
 #define __WASI_ADVICE_NOREUSE (UINT8_C(5))
 #define __WASI_ADVICE_NORMAL (UINT8_C(0))
 #define lseek(fd,offset,whence) ({ off_t __f = (fd); off_t __o = (offset); off_t __w = (whence); __builtin_constant_p((offset)) && __builtin_constant_p((whence)) && __o == 0 && __w == SEEK_CUR ? __wasilibc_tell(__f) : lseek(__f, __o, __w); })
 #define lseek64 lseek
 #define lstat64 lstat
-#define major(x) ((unsigned)( (((x)>>31>>1) & 0xfffff000) | (((x)>>8) & 0x00000fff) ))
-#define makedev(x,y) ( (((x)&0xfffff000ULL) << 32) | (((x)&0x00000fffULL) << 8) | (((y)&0xffffff00ULL) << 12) | (((y)&0x000000ffULL)) )
 #define math_errhandling 2
-#define minor(x) ((unsigned)( (((x)>>12) & 0xffffff00) | ((x) & 0x000000ff) ))
 #define mld_cksum mld_icmp6_hdr.icmp6_cksum
 #define mld_code mld_icmp6_hdr.icmp6_code
 #define mld_maxdelay mld_icmp6_hdr.icmp6_data16[0]