Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove logic for explicitly setting INCLUDE_DIRECTORIES from INTERFACE_INCLUDE_DIRECTORIES of LINK_LIBRARIES passed to libmexclass_client_add_proxy_library #57

Open
kevingurney opened this issue Apr 24, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@kevingurney
Copy link
Member

kevingurney commented Apr 24, 2023

In libmexclass_client_add_proxy_library, the LINK_LIBRARIES argument allows clients to specify additional libraries to link against.

Currently, libmexclass_client_add_proxy_library has custom logic for manually adding the INTERFACE_INCLUDE_DIRECTORIES of all LINK_LIBRARIES to the INCLUDE_DIRECTORIES property of the client Proxy library target.

However, CMake does this automatically by default when target_link_libraries is called (i.e. CMake propagates the "usage requirements" of dependencies). Therefore, this custom logic can be removed.

Included below is a relevant excerpt from the CMake documentation for "Transitive Usage Requirements":

Usage requirements are propagated by reading the INTERFACE_ variants of target properties from dependencies and appending the values to the non-INTERFACE_ variants of the operand. For example, the INTERFACE_INCLUDE_DIRECTORIES of dependencies is read and appended to the INCLUDE_DIRECTORIES of the operand.

@kevingurney
Copy link
Member Author

Please refer to this discussion on apache/arrow#34563 for more information.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant