Skip to content

Commit

Permalink
Fix rust deps for gui + nogui.
Browse files Browse the repository at this point in the history
  • Loading branch information
vladfi1 committed Sep 9, 2024
1 parent 833772a commit 615b74c
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 21 deletions.
11 changes: 11 additions & 0 deletions Source/Core/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,14 @@ add_subdirectory(VideoBackends)
if(ENABLE_QT)
add_subdirectory(DolphinQt)
endif()

# Build SlippiRustExtensions for DolphinWX and DolphinNoGui.
#
# (This doesn't feel perfect here, but truth be told I can't think offhand of
# a better location for it at the moment.)
set(RUST_FEATURES "")
if(DIS_PLAYBACK)
set(RUST_FEATURES "playback")
endif()

corrosion_import_crate(MANIFEST_PATH ${CMAKE_SOURCE_DIR}/Externals/SlippiRustExtensions/Cargo.toml ${RUST_FEATURES})
10 changes: 0 additions & 10 deletions Source/Core/DolphinNoGUI/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,6 @@ target_link_libraries(dolphin-nogui PRIVATE
${LIBS}
)

# Link SlippiRustExtensions in.
#
# (This doesn't feel perfect here, but truth be told I can't think offhand of
# a better location for it at the moment.)
set(RUST_FEATURES "")
if(DIS_PLAYBACK)
set(RUST_FEATURES "playback")
endif()

corrosion_import_crate(MANIFEST_PATH ${CMAKE_SOURCE_DIR}/Externals/SlippiRustExtensions/Cargo.toml ${RUST_FEATURES})
target_link_libraries(dolphin-nogui PUBLIC slippi-rust-extensions)

set(CPACK_PACKAGE_EXECUTABLES ${CPACK_PACKAGE_EXECUTABLES} dolphin-nogui)
Expand Down
12 changes: 1 addition & 11 deletions Source/Core/DolphinWX/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -133,16 +133,6 @@ if(wxWidgets_FOUND)
add_executable("${DOLPHIN_EXE}" ${SRCS} ${GUI_SRCS})
target_link_libraries("${DOLPHIN_EXE}" ${LIBS} ${WXLIBS})

# Link SlippiRustExtensions in.
#
# (This doesn't feel perfect here, but truth be told I can't think offhand of
# a better location for it at the moment.)
set(RUST_FEATURES "")
if(DIS_PLAYBACK)
set(RUST_FEATURES "playback")
endif()

corrosion_import_crate(MANIFEST_PATH ${CMAKE_SOURCE_DIR}/Externals/SlippiRustExtensions/Cargo.toml ${RUST_FEATURES})
target_link_libraries("${DOLPHIN_EXE}" PUBLIC slippi-rust-extensions)

if(APPLE)
Expand All @@ -155,7 +145,7 @@ if(wxWidgets_FOUND)
MACOSX_BUNDLE true
MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist.in
)

# Link MoltenVK for the Vulkan (experimental) backend; the framework is
# added into the bundle in Tools/deploy-mac.py due to legacy build reasons.
find_library(MOLTENVK libvulkan.dylib PATHS ${CMAKE_SOURCE_DIR}/Externals/MoltenVK)
Expand Down

0 comments on commit 615b74c

Please sign in to comment.