From f1be7cd4a0b1ba2b755182eb4e0f2fa0a8c418f0 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Sat, 7 Apr 2018 19:53:19 -0400 Subject: [PATCH] CMakeLists: Link bochs in privately where applicable Everything that links in core doesn't need to see anything related to bochs, because it's only used internally. Anything else that relies on bochs should be linking it in explicitly. --- Source/Core/Core/CMakeLists.txt | 2 +- Source/Core/DolphinWX/CMakeLists.txt | 1 + Source/Core/UICommon/CMakeLists.txt | 1 + Source/UnitTests/CMakeLists.txt | 2 +- Source/UnitTests/Common/CMakeLists.txt | 2 ++ 5 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Source/Core/Core/CMakeLists.txt b/Source/Core/Core/CMakeLists.txt index aca7f15e81..d42c959bc1 100644 --- a/Source/Core/Core/CMakeLists.txt +++ b/Source/Core/Core/CMakeLists.txt @@ -276,7 +276,6 @@ endif() target_link_libraries(core PUBLIC audiocommon - bdisasm common cubeb discio @@ -292,6 +291,7 @@ PUBLIC z PRIVATE + bdisasm ${LZO} ) diff --git a/Source/Core/DolphinWX/CMakeLists.txt b/Source/Core/DolphinWX/CMakeLists.txt index 2641d490f3..8ce2d700bf 100644 --- a/Source/Core/DolphinWX/CMakeLists.txt +++ b/Source/Core/DolphinWX/CMakeLists.txt @@ -85,6 +85,7 @@ add_executable(dolphin-emu target_link_libraries(dolphin-emu PRIVATE + bdisasm core uicommon cpp-optparse diff --git a/Source/Core/UICommon/CMakeLists.txt b/Source/Core/UICommon/CMakeLists.txt index fc1cf234d6..ed94341182 100644 --- a/Source/Core/UICommon/CMakeLists.txt +++ b/Source/Core/UICommon/CMakeLists.txt @@ -15,6 +15,7 @@ PUBLIC cpp-optparse PRIVATE + bdisasm $<$:${IOK_LIBRARY}> ) diff --git a/Source/UnitTests/CMakeLists.txt b/Source/UnitTests/CMakeLists.txt index 649c802830..50167617a0 100644 --- a/Source/UnitTests/CMakeLists.txt +++ b/Source/UnitTests/CMakeLists.txt @@ -16,7 +16,7 @@ macro(add_dolphin_test target) $ ) set_target_properties(${target} PROPERTIES FOLDER Tests) - target_link_libraries(${target} core uicommon gtest_main) + target_link_libraries(${target} PRIVATE core uicommon gtest_main) add_dependencies(unittests ${target}) add_test(NAME ${target} COMMAND ${target}) endmacro() diff --git a/Source/UnitTests/Common/CMakeLists.txt b/Source/UnitTests/Common/CMakeLists.txt index 6736348c8b..7154e86131 100644 --- a/Source/UnitTests/Common/CMakeLists.txt +++ b/Source/UnitTests/Common/CMakeLists.txt @@ -12,4 +12,6 @@ add_dolphin_test(NandPathsTest NandPathsTest.cpp) add_dolphin_test(SPSCQueueTest SPSCQueueTest.cpp) add_dolphin_test(StringUtilTest StringUtilTest.cpp) add_dolphin_test(SwapTest SwapTest.cpp) + add_dolphin_test(x64EmitterTest x64EmitterTest.cpp) +target_link_libraries(x64EmitterTest PRIVATE bdisasm)