Skip to content

Commit 2f424b5

Browse files
committed
Fix missing cmake_deps.toml dep from size_test to extension_data_loader
Missing deps like this causes executorch_srcs.cmake to just roll the sources into the would-be-depending target, which is bad. ghstack-source-id: c7e1598 ghstack-comment-id: 3105633149 Pull-Request: #12744
1 parent e96600d commit 2f424b5

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

test/CMakeLists.txt

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ list(TRANSFORM _size_test__srcs PREPEND "${EXECUTORCH_ROOT}/")
5151
# TODO(larryliu0820): Add EXECUTORCH_BUILD_EXECUTABLES to not build executable
5252
# when we cross compile to ios
5353
add_executable(size_test ${_size_test__srcs})
54-
target_link_libraries(size_test executorch)
54+
target_link_libraries(size_test executorch extension_data_loader)
5555
if(NOT CMAKE_BUILD_TYPE STREQUAL "Debug")
5656
target_link_options_gc_sections(size_test)
5757
endif()
@@ -62,7 +62,8 @@ endif()
6262
add_executable(size_test_all_ops ${_size_test__srcs})
6363
executorch_target_link_options_shared_lib(portable_ops_lib)
6464
target_link_libraries(
65-
size_test_all_ops executorch portable_ops_lib portable_kernels
65+
size_test_all_ops executorch extension_data_loader portable_ops_lib
66+
portable_kernels
6667
)
6768
if(NOT CMAKE_BUILD_TYPE STREQUAL "Debug")
6869
target_link_options_gc_sections(size_test_all_ops)
@@ -75,7 +76,8 @@ if(EXECUTORCH_BUILD_KERNELS_OPTIMIZED)
7576
add_executable(size_test_all_optimized_ops ${_size_test__srcs})
7677
executorch_target_link_options_shared_lib(optimized_native_cpu_ops_lib)
7778
target_link_libraries(
78-
size_test_all_optimized_ops executorch optimized_native_cpu_ops_lib
79+
size_test_all_optimized_ops executorch extension_data_loader
80+
optimized_native_cpu_ops_lib
7981
)
8082
if(NOT CMAKE_BUILD_TYPE STREQUAL "Debug")
8183
target_link_options_gc_sections(size_test_all_optimized_ops)

tools/cmake/cmake_deps.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -373,6 +373,7 @@ excludes = [
373373
deps = [
374374
"executorch_core",
375375
"executorch",
376+
"extension_data_loader",
376377
]
377378
# ---------------------------------- binary end ----------------------------------
378379
# ---------------------------------- MPS start ----------------------------------

0 commit comments

Comments
 (0)