From 0a41bf5d0db7f49de4e12b193cf0246f825d68f6 Mon Sep 17 00:00:00 2001 From: Bryan Wilder Field Lozano Date: Fri, 22 Nov 2024 17:01:06 -0800 Subject: [PATCH] Make uv and nng private and static (#323) --- cmake/dependencies.cmake | 10 ++++++++-- device/CMakeLists.txt | 5 ++--- tests/CMakeLists.txt | 1 + 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/cmake/dependencies.cmake b/cmake/dependencies.cmake index 96ebbaf5..14c9aed5 100644 --- a/cmake/dependencies.cmake +++ b/cmake/dependencies.cmake @@ -56,7 +56,6 @@ function(fetch_dependencies) GITHUB_REPOSITORY nanomsg/nng GIT_TAG v1.8.0 OPTIONS - "BUILD_SHARED_LIBS ON" "NNG_TESTS OFF" "NNG_TOOLS OFF" ) @@ -97,7 +96,14 @@ function(fetch_dependencies) ############################################################################################################################ # libuv (for process management) ############################################################################################################################ - CPMAddPackage(NAME libuv GITHUB_REPOSITORY libuv/libuv GIT_TAG v1.48.0 OPTIONS "LIBUV_BUILD_TESTS OFF") + CPMAddPackage( + NAME libuv + GITHUB_REPOSITORY libuv/libuv + GIT_TAG v1.48.0 + OPTIONS + "LIBUV_BUILD_TESTS OFF" + "LIBUV_BUILD_SHARED OFF" + ) ############################################################################################################################ # fmt : https://github.com/fmtlib/fmt diff --git a/device/CMakeLists.txt b/device/CMakeLists.txt index 499e521e..a21d7d81 100644 --- a/device/CMakeLists.txt +++ b/device/CMakeLists.txt @@ -41,16 +41,15 @@ target_include_directories( ) # flatbuffers is public - exposed to tt_metal by tt_simulation_device_generated.h -# nng is public - exposed to tt_metal by tt_simulation_host.hpp target_link_libraries( device PUBLIC - nng flatbuffers - uv PRIVATE hwloc + nng rt + uv_a Boost::interprocess fmt::fmt-header-only yaml-cpp::yaml-cpp diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 6829c91b..f7524f36 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -13,6 +13,7 @@ target_link_libraries( gtest pthread fmt::fmt-header-only + nng ) target_include_directories( test_common