--- memkind-1.10.0.orig/include/memkind_allocator.h
+++ memkind-1.10.0/include/memkind_allocator.h
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2019 Intel Corporation.
+ * Copyright (C) 2019 - 2020 Intel Corporation.
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -31,6 +31,7 @@
 #include <exception>
 #include <type_traits>
 #include <cstddef>
+#include <stdexcept>
 
 #include "memkind.h"
 
--- memkind-1.10.0.orig/include/pmem_allocator.h
+++ memkind-1.10.0/include/pmem_allocator.h
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2018 - 2019 Intel Corporation.
+ * Copyright (C) 2018 - 2020 Intel Corporation.
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -30,6 +30,7 @@
 #include <type_traits>
 #include <atomic>
 #include <cstddef>
+#include <stdexcept>
 
 #include "memkind.h"
 
--- memkind-1.10.0.orig/test/alloc_benchmark.c
+++ memkind-1.10.0/test/alloc_benchmark.c
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2016 - 2018 Intel Corporation.
+ * Copyright (C) 2016 - 2020 Intel Corporation.
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -38,6 +38,10 @@
 #define FREE_FN hbw_free
 #elif defined (TBBMALLOC)
 #include "tbbmalloc.h"
+void *(*scalable_malloc)(size_t);
+void *(*scalable_realloc)(void *, size_t);
+void *(*scalable_calloc)(size_t, size_t);
+void  (*scalable_free)(void *);
 #define MALLOC_FN scalable_malloc
 #define FREE_FN scalable_free
 #elif defined (PMEMMALLOC)
--- memkind-1.10.0.orig/test/tbbmalloc.h
+++ memkind-1.10.0/test/tbbmalloc.h
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2016 - 2018 Intel Corporation.
+ * Copyright (C) 2016 - 2020 Intel Corporation.
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -25,9 +25,9 @@
 #include <stdio.h>
 #include <dlfcn.h>
 
-void *(*scalable_malloc)(size_t);
-void *(*scalable_realloc)(void *, size_t);
-void *(*scalable_calloc)(size_t, size_t);
-void  (*scalable_free)(void *);
+extern void *(*scalable_malloc)(size_t);
+extern void *(*scalable_realloc)(void *, size_t);
+extern void *(*scalable_calloc)(size_t, size_t);
+extern void  (*scalable_free)(void *);
 
 int load_tbbmalloc_symbols();
