Merge "Add the glibc-compatible names to <sys/endian.h>."
diff --git a/libc/arch-x86/string/bcmp.S b/libc/arch-x86/string/bcmp.S
deleted file mode 100644
index 4a88f66..0000000
--- a/libc/arch-x86/string/bcmp.S
+++ /dev/null
@@ -1,33 +0,0 @@
-/* $OpenBSD: bcmp.S,v 1.3 2005/08/07 11:30:38 espie Exp $ */
-/*
- * Written by J.T. Conklin <jtc@netbsd.org>.
- * Public domain.
- */
-
-#include <machine/asm.h>
-
-ENTRY(bcmp)
- pushl %edi
- pushl %esi
- movl 12(%esp),%edi
- movl 16(%esp),%esi
- xorl %eax,%eax /* clear return value */
- cld /* set compare direction forward */
-
- movl 20(%esp),%ecx /* compare by words */
- shrl $2,%ecx
- repe
- cmpsl
- jne L1
-
- movl 20(%esp),%ecx /* compare remainder by bytes */
- andl $3,%ecx
- repe
- cmpsb
- je L2
-
-L1: incl %eax
-L2: popl %esi
- popl %edi
- ret
-END(bcmp)
diff --git a/libc/arch-x86/string/rindex.S b/libc/arch-x86/string/rindex.S
deleted file mode 100644
index 0260d38..0000000
--- a/libc/arch-x86/string/rindex.S
+++ /dev/null
@@ -1,29 +0,0 @@
-/* $OpenBSD: rindex.S,v 1.3 2005/08/07 11:30:38 espie Exp $ */
-/*
- * Written by J.T. Conklin <jtc@netbsd.org>.
- * Public domain.
- */
-
-#include <machine/asm.h>
-
-#ifdef STRRCHR
-ENTRY(strrchr)
-#else
-ENTRY(rindex)
-#endif
- pushl %ebx
- movl 8(%esp),%edx
- movb 12(%esp),%cl
- xorl %eax,%eax /* init pointer to null */
- .align 2,0x90
-L1:
- movb (%edx),%bl
- cmpb %bl,%cl
- jne L2
- movl %edx,%eax
-L2:
- incl %edx
- testb %bl,%bl /* null terminator??? */
- jnz L1
- popl %ebx
- ret
diff --git a/libc/arch-x86/string/strrchr.S b/libc/arch-x86/string/strrchr.S
deleted file mode 100644
index 4ee153f..0000000
--- a/libc/arch-x86/string/strrchr.S
+++ /dev/null
@@ -1,3 +0,0 @@
-/* $OpenBSD: strrchr.S,v 1.3 2005/08/07 11:30:38 espie Exp $ */
-#define STRRCHR
-#include "rindex.S"
diff --git a/libc/include/memory.h b/libc/include/memory.h
index e69de29..3b2f590 100644
--- a/libc/include/memory.h
+++ b/libc/include/memory.h
@@ -0,0 +1 @@
+#include <string.h>
diff --git a/libc/include/string.h b/libc/include/string.h
index 70e0042..63e768e 100644
--- a/libc/include/string.h
+++ b/libc/include/string.h
@@ -45,7 +45,6 @@
extern void memswap(void *, void *, size_t);
extern char* index(const char *, int) __purefunc;
-extern char* rindex(const char *, int) __purefunc;
extern char* strchr(const char *, int) __purefunc;
extern char* strrchr(const char *, int) __purefunc;
diff --git a/libc/include/strings.h b/libc/include/strings.h
index db2aa3a..0ee691d 100644
--- a/libc/include/strings.h
+++ b/libc/include/strings.h
@@ -43,12 +43,10 @@
#include <sys/cdefs.h>
__BEGIN_DECLS
-int bcmp(const void *, const void *, size_t);
void bcopy(const void *, void *, size_t);
void bzero(void *, size_t);
int ffs(int);
char *index(const char *, int);
-char *rindex(const char *, int);
int strcasecmp(const char *, const char *);
int strncasecmp(const char *, const char *, size_t);
diff --git a/libc/include/sys/signal.h b/libc/include/sys/signal.h
new file mode 100644
index 0000000..2e602da
--- /dev/null
+++ b/libc/include/sys/signal.h
@@ -0,0 +1 @@
+#include <signal.h>