Skip to content

Commit 0d8564b

Browse files
committed
Fix rust build with target-level dependency on binaryninjaapi.
1 parent abfd08f commit 0d8564b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

rust/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ endif()
3030

3131
# TODO : RUSTDOCFLAGS="--theme binja-dark.css --default-theme=binja-dark"
3232
add_custom_target(rust_api ALL DEPENDS ${PROJECT_BINARY_DIR}/rust_api.stamp)
33+
add_dependencies(rust_api binaryninjaapi)
3334

3435
add_custom_target(rust_docs ALL DEPENDS ${PROJECT_BINARY_DIR}/target/doc)
3536
add_dependencies(rust_docs binaryninjaapi rust_api)
@@ -49,7 +50,7 @@ add_custom_command(
4950
COMMAND ${CMAKE_COMMAND} -E env BINARYNINJADIR=${BN_INSTALL_BIN_DIR} ${RUSTUP_CHECK_COMMAND} ${CARGO_CHECK_OPTS}
5051
COMMAND ${CMAKE_COMMAND} -E touch ${PROJECT_BINARY_DIR}/rust_api.stamp
5152
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
52-
DEPENDS ${RUST_API_SOURCES} $<TARGET_FILE:binaryninjaapi>
53+
DEPENDS ${RUST_API_SOURCES}
5354
COMMENT "Checking Rust API"
5455
VERBATIM
5556
)

0 commit comments

Comments
 (0)