diff --git a/CMakeLists.txt b/CMakeLists.txt
index 47740a58b627098a93210e6ad429105e467c1d8f..ec0da0d6cf46eee9d0436c6c4c556a3fcc2f7a77 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -11,7 +11,13 @@ set (libdir "${CMAKE_INSTALL_FULL_LIBDIR}")
 set (includedir "${CMAKE_INSTALL_FULL_INCLUDEDIR}")
 
 find_package (PkgConfig REQUIRED)
-find_package(msgpack REQUIRED QUIET CONFIG NAMES msgpack msgpack-cxx)
+find_package(msgpackc-cxx QUIET CONFIG)
+if(msgpackc-cxx_FOUND)
+  add_library(msgpack-cxx ALIAS msgpackc-cxx)
+else()
+  find_package(msgpack-cxx CONFIG REQUIRED)
+endif()
+
 find_package(fmt)
 pkg_check_modules (opendht REQUIRED IMPORTED_TARGET opendht>=2.6.0)
 pkg_check_modules (pjproject REQUIRED IMPORTED_TARGET libpjproject)
@@ -54,7 +60,7 @@ list (APPEND dhtnet_HEADERS
 )
 
 add_library(dhtnet ${dhtnet_SOURCES})
-target_link_libraries(dhtnet PUBLIC PkgConfig::opendht PkgConfig::pjproject fmt::fmt msgpackc)
+target_link_libraries(dhtnet PUBLIC PkgConfig::opendht PkgConfig::pjproject fmt::fmt msgpack-cxx)
 target_include_directories(dhtnet PUBLIC
     $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
     $<INSTALL_INTERFACE:include>
diff --git a/include/upnp/mapping.h b/include/upnp/mapping.h
index ebcbdaa6b090b65faf4853dced6ca65a9c67340b..19e6421c005caac9182c907ee5672daaf3892916 100644
--- a/include/upnp/mapping.h
+++ b/include/upnp/mapping.h
@@ -21,7 +21,7 @@
 
 #pragma once
 
-#include "ip_utils.h"
+#include "../ip_utils.h"
 
 #include <map>
 #include <string>
diff --git a/include/upnp/upnp_context.h b/include/upnp/upnp_context.h
index 57b45d6f679d20a6c48825f7f1129e8fb1177f50..2ac63cd10a86311872fce8a8c25d3ac288d96a4d 100644
--- a/include/upnp/upnp_context.h
+++ b/include/upnp/upnp_context.h
@@ -31,10 +31,10 @@
 #endif
 #include "igd.h"*/
 
-#include "ip_utils.h"
+#include "../ip_utils.h"
 
 #include "upnp_thread_util.h"
-#include "upnp/mapping.h"
+#include "mapping.h"
 
 #include <opendht/rng.h>
 #include <opendht/logger.h>
diff --git a/include/upnp/upnp_control.h b/include/upnp/upnp_control.h
index c9949b4a1f4379f032f76ff2cdec4005648d10ae..236c0c7fde2a5212e0f7deeaa983e1a91e284ce3 100644
--- a/include/upnp/upnp_control.h
+++ b/include/upnp/upnp_control.h
@@ -23,7 +23,7 @@
 #pragma once
 
 #include "mapping.h"
-#include "ip_utils.h"
+#include "../ip_utils.h"
 
 #include <memory>
 #include <chrono>