You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This probably makes sense on a general basis, but can cause some issues for crates whose C dependencies get grumpy if the install path is very long (e.g., jonhoo/rust-ibverbs#41). While callers can always set CMAKE_INSTALL_PREFIX to something shorter (e.g., jonhoo/rust-ibverbs#44), especially since chances are no install step is executed, it may be preferable to allow bypassing the logic in cmake entirely somehow and let the guest project's CMake rules (including the built-in ones) take effect. A bool option on the builder should probably be sufficient.
It's worth pointing out that the current logic isn't as obviously correct if the calling code exports binary artifacts from the C build, because those built artifacts may in turn rely on CMAKE_INSTALL_PREFIX in some way, which is unlikely to match the Rust build directory on whatever the intended runtime target system is.
The text was updated successfully, but these errors were encountered:
Currently,
cmake
will auto-setCMAKE_INSTALL_PREFIX
to the output directory if it's not already setcmake-rs/src/lib.rs
Lines 699 to 703 in 94da9de
This probably makes sense on a general basis, but can cause some issues for crates whose C dependencies get grumpy if the install path is very long (e.g., jonhoo/rust-ibverbs#41). While callers can always set
CMAKE_INSTALL_PREFIX
to something shorter (e.g., jonhoo/rust-ibverbs#44), especially since chances are no install step is executed, it may be preferable to allow bypassing the logic incmake
entirely somehow and let the guest project's CMake rules (including the built-in ones) take effect. Abool
option on the builder should probably be sufficient.It's worth pointing out that the current logic isn't as obviously correct if the calling code exports binary artifacts from the C build, because those built artifacts may in turn rely on
CMAKE_INSTALL_PREFIX
in some way, which is unlikely to match the Rust build directory on whatever the intended runtime target system is.The text was updated successfully, but these errors were encountered: