diff --git src/util.c src/util.c
index f2141bd..10e1549 100644
--- a/src/util.c
+++ b/src/util.c
@@ -2,8 +2,9 @@
 
 #include <openssl/md5.h>
 #include <uuid/uuid.h>
-
+#ifdef __GLIBC__
 #include <execinfo.h>
+#endif
 #include <unistd.h>
 #include <stdlib.h>
 #include <string.h>
@@ -147,13 +148,15 @@ void exit_failure(void)
 {
     int nptrs;
     void *buffer[BT_BUF_SIZE];
-
+#ifdef __GLIBC__
     nptrs = backtrace(buffer, BT_BUF_SIZE);
+#endif
     fprintf(stderr, "\nOops! HTTPDirFS crashed! :(\n");
+#ifdef __GLIBC__
     fprintf(stderr, "backtrace() returned the following %d addresses:\n",
             nptrs);
     backtrace_symbols_fd(buffer, nptrs, STDERR_FILENO);
-
+#endif
     exit(EXIT_FAILURE);
 }
 
