Was always including malloc.h - this is now only done on Linux. It was for malloc_usable_size().
diff --git a/transcoder/basisu_containers.h b/transcoder/basisu_containers.h
index a42bde9..9a31766 100644
--- a/transcoder/basisu_containers.h
+++ b/transcoder/basisu_containers.h
@@ -5,7 +5,12 @@
 #include <stdint.h>
 #include <assert.h>
 #include <algorithm>
+
+#ifdef __linux__
+// Only for malloc_usable_size() in basisu_containers_impl.h
 #include <malloc.h>
+#define HAS_MALLOC_USABLE_SIZE 1
+#endif
 
 #ifdef _MSC_VER
 #define BASISU_FORCE_INLINE __forceinline
diff --git a/transcoder/basisu_containers_impl.h b/transcoder/basisu_containers_impl.h
index 1a0d7cb..6555171 100644
--- a/transcoder/basisu_containers_impl.h
+++ b/transcoder/basisu_containers_impl.h
@@ -57,10 +57,10 @@
 
 #ifdef _MSC_VER
          actual_size = _msize(new_p);
-//#elif defined(__EMSCRIPTEN__)
-//         actual_size = desired_size;
-#else
+#elif HAS_MALLOC_USABLE_SIZE
          actual_size = malloc_usable_size(new_p);
+#else
+         actual_size = desired_size;
 #endif
          m_p = new_p;
       }
@@ -84,10 +84,10 @@
 
 #ifdef _MSC_VER
          actual_size = _msize(new_p);
-//#elif defined(__EMSCRIPTEN__)
-//         actual_size = desired_size;
-#else
+#elif HAS_MALLOC_USABLE_SIZE
          actual_size = malloc_usable_size(new_p);
+#else
+         actual_size = desired_size;
 #endif
 
          (*pMover)(new_p, m_p, m_size);