Commit 201abd9
committed
Merge #289: cmake: make target_capnp_sources use CURRENT dirs
615a94f cmake: document ONLY_CAPNP option in target_capnp_sources (Ryan Ofsky)
620f297 cmake: make target_capnp_sources use CURRENT dirs (Ryan Ofsky)
Pull request description:
Tweak `target_capnp_sources` to use `CMAKE_CURRENT_SOURCE_DIR` and `CMAKE_CURRENT_BINARY_DIR` instead of `CMAKE_SOURCE_DIR` and `CMAKE_BINARY_DIR` to compute include directory paths.
This allows `target_capnp_sources` to work properly inside libmultiprocess when libmultiprocess is used as a subproject and `CMAKE_SOURCE_DIR` point somewhere outside of it, as happens in support branch used by #287.
This is also a good change to make more generally because `CMAKE_CURRENT_SOURCE_DIR` is a more predictable path than `CMAKE_SOURCE_DIR` and is passed in by all current `target_capnp_sources` callers.
ACKs for top commit:
hebasto:
re-ACK 615a94f.
Tree-SHA512: 978a3172dee80cff4dd2afb4858347216c9211a6f182b6b0b9ad71641f30ccaea619d5ddd61484cd08375dd21c290b8fb5b52307baadc8042443b12bd6c3b9081 file changed
Lines changed: 13 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
| 30 | + | |
| 31 | + | |
34 | 32 | | |
35 | 33 | | |
36 | 34 | | |
| |||
43 | 41 | | |
44 | 42 | | |
45 | 43 | | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
46 | 51 | | |
47 | 52 | | |
48 | 53 | | |
49 | | - | |
| 54 | + | |
50 | 55 | | |
51 | | - | |
| 56 | + | |
52 | 57 | | |
53 | 58 | | |
54 | 59 | | |
| |||
98 | 103 | | |
99 | 104 | | |
100 | 105 | | |
101 | | - | |
102 | | - | |
| 106 | + | |
| 107 | + | |
103 | 108 | | |
104 | 109 | | |
105 | 110 | | |
| |||
0 commit comments