Commit af1ab5f
cmake: build shared libexecutorch_portable_ops when EXECUTORCH_BUILD_SHARED=ON
Create a single libexecutorch_portable_ops.so that bundles
portable_ops_lib and portable_kernels, allowing consumers to link
portable op implementations via a shared library.
portable_ops_lib already has --whole-archive as an INTERFACE link
option from Codegen.cmake, so we do not wrap it in
$<LINK_LIBRARY:WHOLE_ARCHIVE,...> to avoid pulling the registration
constructor in twice. Link against executorch_shared (not
executorch_core) to share a single operator registry.
Co-authored-by: Claude <noreply@anthropic.com>1 parent 6902161 commit af1ab5f
2 files changed
Lines changed: 30 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
106 | 106 | | |
107 | 107 | | |
108 | 108 | | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
109 | 115 | | |
110 | 116 | | |
111 | 117 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
211 | 211 | | |
212 | 212 | | |
213 | 213 | | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
0 commit comments