--- /dev/null
+diff -pruN openturns_ref/CMakeLists.txt openturns_dev/CMakeLists.txt
+--- openturns_ref/CMakeLists.txt 2021-02-19 15:46:57.077060192 +0100
++++ openturns_dev/CMakeLists.txt 2021-02-19 15:46:46.576956703 +0100
+@@ -125,6 +125,10 @@ set (OPENTURNS_TEMPDIR
+ set (TEMPDIR ${OPENTURNS_TEMPDIR})
+
+ set (CMAKE_CXX_STANDARD 11)
++SET(LAPACK_ROOT_DIR $ENV{LAPACK_ROOT_DIR})
++IF(LAPACK_ROOT_DIR)
++ LIST(APPEND CMAKE_PREFIX_PATH "${LAPACK_ROOT_DIR}")
++ENDIF(LAPACK_ROOT_DIR)
+
+ if (NOT DEFINED LAPACK_LIBRARIES)
+ find_package (LAPACK REQUIRED)
+@@ -156,7 +160,11 @@ if (USE_FLEX)
+ endif ()
+ endif ()
+
+-if (USE_TBB)
++if (USE_TBB)
++ SET(TBB_ROOT_DIR $ENV{TBB_ROOT_DIR})
++ if(TBB_ROOT_DIR)
++ LIST(APPEND CMAKE_PREFIX_PATH "${TBB_ROOT_DIR}")
++ endif(TBB_ROOT_DIR)
+ find_package (TBB)
+ endif ()
+ if (TBB_FOUND)
+@@ -200,6 +208,10 @@ if (USE_DOXYGEN)
+ endif ()
+
+ if (USE_LIBXML2)
++ SET(LIBXML2_ROOT_DIR $ENV{LIBXLM2_ROOT_DIR})
++ if(LIBXML2_ROOT_DIR)
++ LIST(APPEND CMAKE_PREFIX_PATH "${LIBXML2_ROOT_DIR}")
++ endif(LIBXML2_ROOT_DIR)
+ find_package (LibXml2)
+ endif ()
+ if (LIBXML2_FOUND)
+@@ -210,7 +222,7 @@ if (LIBXML2_FOUND)
+ endif ()
+
+ if (USE_HDF5)
+- find_package(HDF5 COMPONENTS CXX)
++ find_package(HDF5 COMPONENTS CXX HL)
+ endif ()
+ if (HDF5_FOUND)
+ set (OPENTURNS_HAVE_HDF5 TRUE)
+@@ -218,7 +230,6 @@ if (HDF5_FOUND)
+ list (APPEND OPENTURNS_PRIVATE_INCLUDE_DIRS ${HDF5_INCLUDE_DIRS})
+ list (APPEND OPENTURNS_PRIVATE_LIBRARIES ${HDF5_LIBRARIES})
+ endif ()
+-
+ if (MSVC OR WINTEL)
+ set (CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES} ${CMAKE_CURRENT_SOURCE_DIR}/lib/include/pthread_win32 ${CMAKE_CURRENT_SOURCE_DIR}/lib/include)
+ include_directories (${PROJECT_SOURCE_DIR}/lib/include/pthread_win32 ${CMAKE_CURRENT_SOURCE_DIR}/lib/include)
+
+diff -pruN openturns_ref/cmake/FindTBB.cmake openturns_dev/cmake/FindTBB.cmake
+--- openturns_ref/cmake/FindTBB.cmake 2021-02-19 15:46:57.058060005 +0100
++++ openturns_dev/cmake/FindTBB.cmake 2021-02-19 15:51:59.654083375 +0100
+@@ -27,6 +27,11 @@
+ # (To distributed this file outside of CMake, substitute the full
+ # License text for the above reference.)
+
++SET(TBB_ROOT_DIR $ENV{TBB_ROOT_DIR})
++IF(TBB_ROOT_DIR)
++ LIST(APPEND CMAKE_PREFIX_PATH "${TBB_ROOT_DIR}")
++ENDIF(TBB_ROOT_DIR)
++
+ find_path (TBB_INCLUDE_DIR NAMES tbb/tbb.h DOC "TBB include directory")
+
+ set (TBB_INCLUDE_DIRS ${TBB_INCLUDE_DIR})
+
+diff -pruN openturns_ref/cmake/FindNLopt.cmake openturns_dev/cmake/FindNLopt.cmake
+--- openturns_ref/cmake/FindNLopt.cmake 2021-02-19 15:46:57.064060064 +0100
++++ openturns_dev/cmake/FindNLopt.cmake 2021-02-19 15:53:27.134956381 +0100
+@@ -11,10 +11,21 @@
+ # NLOPT_ROOT_DIR - root dir (ex. /usr/local)
+
+ # set NLOPT_INCLUDE_DIR
++SET(NLOPT_ROOT_DIR $ENV{NLOPT_ROOT_DIR})
++
++IF(NLOPT_ROOT_DIR)
++ LIST(APPEND CMAKE_PREFIX_PATH "${NLOPT_ROOT_DIR}")
++ LIST(APPEND CMAKE_PREFIX_PATH "${NLOPT_ROOT_DIR}/include")
++ LIST(APPEND CMAKE_PREFIX_PATH "${NLOPT_ROOT_DIR}/lib")
++ELSE(NLOPT_ROOT_DIR)
++ MESSAGE(FATAL_ERROR "PLEASE SET ENVIRONMENT VARIABLE NLOPT_ROOT_DIR")
++ENDIF(NLOPT_ROOT_DIR)
++
+ find_path (NLOPT_INCLUDE_DIR
+ NAMES nlopt.hpp
++ HINTS ${NLOPT_ROOT_DIR}/include
+ DOC
+- "Nlopt include directory"
++ "Nlopt include directory"
+ )
+
+ # set NLOPT_INCLUDE_DIRS
+@@ -22,9 +33,10 @@ set (NLOPT_INCLUDE_DIRS ${NLOPT_INCLUDE_
+
+ # set NLOPT_LIBRARY
+ find_library (NLOPT_LIBRARY
+- NAMES nlopt_cxx nlopt
++ NAMES nlopt
++ HINTS ${NLOPT_ROOT_DIR}/lib
+ DOC
+- "Nlopt library location"
++ "Nlopt library location"
+ )
+
+ # set NLOPT_LIBRARIES
+
+diff -pruN openturns_ref/lib/src/CMakeLists.txt openturns_dev/lib/src/CMakeLists.txt
+--- openturns_ref/lib/src/CMakeLists.txt 2021-02-19 15:46:49.880989268 +0100
++++ openturns_dev/lib/src/CMakeLists.txt 2021-02-19 16:12:54.874714974 +0100
+@@ -80,15 +80,15 @@ if (BISON_FOUND AND FLEX_FOUND)
+ add_dependencies (OT generate_csv_parser)
+ endif ()
+
+-target_link_libraries (OT PUBLIC ${OPENTURNS_LIBRARIES})
+-target_link_libraries (OT PRIVATE ${OPENTURNS_PRIVATE_LIBRARIES})
++target_link_libraries (OT PUBLIC ${OPENTURNS_LIBRARIES} ${HDF5_LIBRARIES} ${TBB_LIBRARIES})
++target_link_libraries (OT PRIVATE ${OPENTURNS_PRIVATE_LIBRARIES} ${HDF5_LIBRARIES} ${TBB_LIBRARIES})
+
+ target_include_directories (OT INTERFACE $<INSTALL_INTERFACE:include>)
+ target_include_directories (OT PUBLIC ${OPENTURNS_INCLUDE_DIRS})
+
+ # Build an empty executable to check link dependencies and completeness
+ add_executable (linktest main.cxx)
+-target_link_libraries (linktest OT)
++target_link_libraries (linktest OT ${TBB_LIBRARIES} ${HDF5_LIBRARIES})
+ set_target_properties (linktest PROPERTIES
+ INSTALL_RPATH "${CMAKE_INSTALL_RPATH};${CMAKE_BINARY_DIR}/lib/src")
+
+@@ -109,5 +109,5 @@ install (TARGETS OT
+ if (UNIX AND BUILD_SHARED_LIBS)
+ set (OT_GDB_PY ${CMAKE_SHARED_LIBRARY_PREFIX}OT${CMAKE_SHARED_LIBRARY_SUFFIX}.${LIB_VERSION}-gdb.py)
+ execute_process (COMMAND ${CMAKE_COMMAND} -E create_symlink ${CMAKE_CURRENT_SOURCE_DIR}/libOT-gdb.py ${CMAKE_CURRENT_BINARY_DIR}/${OT_GDB_PY})
+- install (FILES libOT-gdb.py DESTINATION ${OPENTURNS_DATA_PATH}/gdb/auto-load/${LIBRARY_PATH} RENAME ${OT_GDB_PY})
++ install (FILES libOT-gdb.py DESTINATION ${OPENTURNS_DATA_PATH}/gdb/auto-load RENAME ${OT_GDB_PY})
+ endif ()
+
+diff -pruN openturns_ref/lib/src/Base/Common/openturns/TBB.hxx openturns_dev/lib/src/Base/Common/openturns/TBB.hxx
+--- openturns_ref/lib/src/Base/Common/openturns/TBB.hxx 2021-02-19 15:46:48.419974868 +0100
++++ openturns_dev/lib/src/Base/Common/openturns/TBB.hxx 2021-02-19 15:46:37.804870246 +0100
+@@ -35,6 +35,7 @@
+ # define __TBBMALLOC_NO_IMPLICIT_LINKAGE 1
+ # endif
+ #endif
++#define TBB_PREVIEW_TASK_ARENA 1
+ #include <tbb/task_arena.h>
+ #include <tbb/parallel_sort.h>
+ #include <tbb/parallel_reduce.h>