Commit ea3888b
committed
fix(build): break cyclic dep between
`target_link_libraries(infiniops_torch_objs PUBLIC infiniops)` and
`target_sources(infiniops PRIVATE $<TARGET_OBJECTS:...>)` form a
cycle that cmake rejects on cambricon
("Cyclic dependencies are allowed only among static libraries").
Inherit `infiniops`'s include directories, compile definitions, and
compile options via `$<TARGET_PROPERTY>` generator expressions
instead of linking, so the object library compiles with the same
settings without a back-edge to `infiniops`.infiniops and torch object lib1 parent c739b19 commit ea3888b
1 file changed
Lines changed: 11 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
353 | 353 | | |
354 | 354 | | |
355 | 355 | | |
356 | | - | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
357 | 359 | | |
358 | | - | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
359 | 368 | | |
360 | 369 | | |
361 | 370 | | |
| |||
0 commit comments