Skip to content

Conversation

@ethanmusser
Copy link
Contributor

@ethanmusser ethanmusser commented Nov 13, 2025

Description

@swift-nav/algint-team

Resolves #1532.

API compatibility

Does this change introduce a API compatibility risk?

No, the API is unchanged. It does introduce a build compatibility risk depending on how consumers use the configured install interface.

API compatibility plan

If the above is "Yes", please detail the compatibility (or migration) plan:

The change should be documented in the release notes with instructions that consumers will need to reconfigure their existing build caches.

JIRA Reference

N/A

@BillyONeal
Copy link

One thing to point out:

The headers are installed to CMAKE_INSTALL_INCLUDEDIR here:

INCLUDES DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
)
install(DIRECTORY ${PROJECT_SOURCE_DIR}/include/libsbp/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/libsbp)

target_include_directories(sbp
PUBLIC
$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/include>
$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>
Copy link
Contributor

@martin4861 martin4861 Nov 14, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am wondering whether this line is still needed?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see any reason you would need it. But I didn't want to break any of your existing tooling/setups that might depend on it in an unexpected way.

$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/include>
$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>
$<INSTALL_INTERFACE:${CMAKE_INSTALL_LIBDIR}>
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Copy link
Contributor

@martin4861 martin4861 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix 👍

@martin4861 martin4861 merged commit 6fd9e0a into swift-nav:master Nov 14, 2025
18 of 21 checks passed
@ethanmusser ethanmusser deleted the ethanmusser/bug/1532-install-interface-libdir branch November 14, 2025 19:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[C/C++] CMake: Install interface is relative to the lib directory

3 participants