diff --git a/miniupnpc/CMakeLists.txt b/miniupnpc/CMakeLists.txt index 37d6ccf..29886f8 100644 --- a/miniupnpc/CMakeLists.txt +++ b/miniupnpc/CMakeLists.txt @@ -117,7 +117,7 @@ if (UPNPC_BUILD_STATIC) set (UPNPC_INSTALL_TARGETS ${UPNPC_INSTALL_TARGETS} libminiupnpc-static) set (UPNPC_LIBRARY_TARGET libminiupnpc-static) add_executable (upnpc-static upnpc.c) - target_link_libraries (upnpc-static PRIVATE libminiupnpc-static) + target_link_libraries (upnpc-static LINK_PRIVATE libminiupnpc-static) endif (UPNPC_BUILD_STATIC) if (UPNPC_BUILD_SHARED) @@ -129,7 +129,7 @@ if (UPNPC_BUILD_SHARED) set (UPNPC_INSTALL_TARGETS ${UPNPC_INSTALL_TARGETS} libminiupnpc-shared) set (UPNPC_LIBRARY_TARGET libminiupnpc-shared) add_executable (upnpc-shared upnpc.c) - target_link_libraries (upnpc-shared PRIVATE libminiupnpc-shared) + target_link_libraries (upnpc-shared LINK_PRIVATE libminiupnpc-shared) endif (UPNPC_BUILD_SHARED) if (UPNPC_BUILD_TESTS)