  
  #define TLS_DEFAULT_ALLOC_MAP       0x0000001F
  
+diff --git a/libdl/libdl.c b/libdl/libdl.c
+index b36af16..ad6d4b4 100644
+--- a/libdl/libdl.c
++++ b/libdl/libdl.c
+@@ -24,6 +24,8 @@ void *dlsym(void *handle, const char *symbol) { return 0; }
+ int dladdr(void *addr, Dl_info *info) { return 0; }
+ int dlclose(void *handle) { return 0; }
+ 
++int *__errno() { return 0; };
++void __set_errno(int f) {};
+ #ifdef __arm__
+ void *dl_unwind_find_exidx(void *pc, int *pcount) { return 0; }
+ #elif defined(__i386__) || defined(__sh__)

diff --git a/libc/bionic/pthread.c b/libc/bionic/pthread.c
index 6b01830..fe45028 100644
--- a/libc/bionic/pthread.c
+++ b/libc/bionic/pthread.c
@@ -177,7 +177,8 @@ __get_stack_base(int  *p_stack_size)

 }
 
 
@@ -1662,6 +1663,7 @@ static int tlsmap_alloc(tlsmap_t*  m, tls_dtor_t  dtor)
 
 int pthread_key_create(pthread_key_t *key, void (*destructor_function)(void *))
 {
+    abort();
     uint32_t   err = ENOMEM;
     tlsmap_t*  map = tlsmap_lock();
     int        k   = tlsmap_alloc(map, destructor_function);
@@ -1686,6 +1688,7 @@ int pthread_key_create(pthread_key_t *key, void (*destructor_function)(void *))
  */
 int pthread_key_delete(pthread_key_t key)
 {
+    abort();
     uint32_t             err;
     pthread_internal_t*  thr;
     tlsmap_t*            map;
@@ -1730,6 +1733,7 @@ err1:
 
 int pthread_setspecific(pthread_key_t key, const void *ptr)
 {
+    abort();
     int        err = EINVAL;
     tlsmap_t*  map;
 
@@ -1747,6 +1751,7 @@ int pthread_setspecific(pthread_key_t key, const void *ptr)
 
 void * pthread_getspecific(pthread_key_t key)
 {
+    abort();
     if (!TLSMAP_VALIDATE_KEY(key)) {
         return NULL;
     }
@@ -1775,6 +1780,7 @@ void * pthread_getspecific(pthread_key_t key)
  */
 static void pthread_key_clean_all(void)
 {
+    abort();
     tlsmap_t*    map;
     void**       tls = (void**)__get_tls();
     int          rounds = PTHREAD_DESTRUCTOR_ITERATIONS;
@@ -1830,6 +1836,7 @@ extern int tkill(int tid, int sig);
 
 int pthread_kill(pthread_t tid, int sig)
 {
+    abort();
     int  ret;
     int  old_errno = errno;
     pthread_internal_t * thread = (pthread_internal_t *)tid;
@@ -1847,6 +1854,7 @@ extern int __rt_sigprocmask(int, const sigset_t *, sigset_t *, size_t);
 
 int pthread_sigmask(int how, const sigset_t *set, sigset_t *oset)
 {
+    abort();
     /* pthread_sigmask must return the error code, but the syscall
      * will set errno instead and return 0/-1
      */
@@ -1863,6 +1871,7 @@ int pthread_sigmask(int how, const sigset_t *set, sigset_t *oset)
 
 int pthread_getcpuclockid(pthread_t  tid, clockid_t  *clockid)
 {
+     abort();
     const int            CLOCK_IDTYPE_BITS = 3;
     pthread_internal_t*  thread = (pthread_internal_t*)tid;
 
@@ -1879,6 +1888,7 @@ int pthread_getcpuclockid(pthread_t  tid, clockid_t  *clockid)
  */
 int  pthread_once( pthread_once_t*  once_control,  void (*init_routine)(void) )
 {
+    abort();
     static pthread_mutex_t   once_lock = PTHREAD_RECURSIVE_MUTEX_INITIALIZER;
 
     if (*once_control == PTHREAD_ONCE_INIT) {
@@ -1898,6 +1908,7 @@ int  pthread_once( pthread_once_t*  once_control,  void (*init_routine)(void) )
 
 int pthread_setname_np(pthread_t thid, const char *thname)
 {
+    abort();
     size_t thname_len;
     int saved_errno, ret;
 
diff --git a/libc/private/bionic_tls.h b/libc/private/bionic_tls.h
index 94a81cd..81c5e16 100644
--- a/libc/private/bionic_tls.h
+++ b/libc/private/bionic_tls.h
@@ -55,17 +55,17 @@ __BEGIN_DECLS
 /* Well known TLS slots */
 #define TLS_SLOT_SELF               0
 #define TLS_SLOT_THREAD_ID          1
-#define TLS_SLOT_ERRNO              2
+#define TLS_SLOT_ERRNO              4
 
-#define TLS_SLOT_OPENGL_API         3
-#define TLS_SLOT_OPENGL             4
+#define TLS_SLOT_OPENGL_API         5
+#define TLS_SLOT_OPENGL             6
 
 /* this slot is only used to pass information from the dynamic linker to
  * libc.so when the C library is loaded in to memory. The C runtime init
  * function will then clear it. Since its use is extremely temporary,
  * we reuse an existing location.
  */
