 +#define _SYS_UTSNAME_H_
 +
 +#endif  // _SYS_UTSNAME_H_
+diff -Naur ../newlib-2.5.0.20170922/newlib/libc/sys/enclave/include/sys/xattr.h ./newlib/libc/sys/enclave/include/sys/xattr.h
+--- ../newlib-2.5.0.20170922/newlib/libc/sys/enclave/include/sys/xattr.h
++++ ./newlib/libc/sys/enclave/include/sys/xattr.h
+@@ -0,0 +1,32 @@
++#ifndef _XATTR_H_
++#define _XATTR_H_
++
++#include <sys/types.h>
++
++#define XATTR_CREATE 1
++#define XATTR_REPLACE 2
++
++#ifdef __cplusplus
++extern "C" {
++#endif
++
++ssize_t getxattr(const char *path, const char *name, void *value, size_t size);
++ssize_t lgetxattr(const char *path, const char *name, void *value, size_t size);
++ssize_t fgetxattr(int fd, const char *name, void *value, size_t size);
++
++int setxattr(const char *path, const char *name, const void *value, size_t size,
++             int flags);
++int lsetxattr(const char *path, const char *name, const void *value,
++              size_t size, int flags);
++int fsetxattr(int fd, const char *name, const void *value, size_t size,
++              int flags);
++
++ssize_t listxattr(const char *path, char *list, size_t size);
++ssize_t llistxattr(const char *path, char *list, size_t size);
++ssize_t flistxattr(int fd, char *list, size_t size);
++
++#ifdef __cplusplus
++}  // extern "C"
++#endif
++
++#endif  // _XATTR_H_
 diff -Naur ../newlib-2.5.0.20170922/newlib/libc/sys/enclave/include/ucontext.h ./newlib/libc/sys/enclave/include/ucontext.h
 --- ../newlib-2.5.0.20170922/newlib/libc/sys/enclave/include/ucontext.h
 +++ ./newlib/libc/sys/enclave/include/ucontext.h

+                #name " is not implemented and will always fail")
+
+#endif /* __WARNING_H__ */
diff -Naur ../newlib-2.5.0.20170922/newlib/configure.host ./newlib/configure.host
--- ../newlib-2.5.0.20170922/newlib/configure.host
+++ ./newlib/configure.host

+	else t='$(program_transform_name)'; echo objcopy | sed -e $$t ; fi`
+
+# object files needed
+OBJS = enclave.o mman.o xattr.o
+
+# Object files specific to particular targets.
+EVALOBJS = ${OBJS}
