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

[vcpkg/script] get infos from installed ports #17029

Closed
wants to merge 3 commits into from

Conversation

Neumann-A
Copy link
Contributor

@Neumann-A Neumann-A commented Apr 1, 2021

some ports require insight into their dependent ports to be configured correctly. One such example is pcl

closes #8269

@@ -39,17 +39,20 @@ vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
opengl WITH_OPENGL
vtk WITH_VTK
)

x_vcpkg_get_port_info(PORTS qhull flann boost-system)
string(COMPARE EQUAL "${boost-system_LIBRARY_LINKAGE}" "dynamic" BOOST_LINKAGE)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This (boost) needs to be checked by someone.

@PhoebeHui PhoebeHui added the category:vcpkg-feature The issue is a new capability of the tool that doesn’t already exist and we haven’t committed label Apr 2, 2021
@ras0219-msft
Copy link
Contributor

Usually, this is to set macros for the headers or to change searched-for library names -- in both these cases, we should be solving the problem in the dependency (hardcoding the correct macro setting or using an indirection layer like pkg-config/find_package()/??? to get the full list of needed libraries, including transitive dependencies). Do you know what PCL uses it for?

@Neumann-A
Copy link
Contributor Author

I just checked the variable for boost and it was setting up the find_package call + adding some compile definitions.
At least for plugins which don't use cmake there is no way for the consumer to know if it is static or dynamic and thus needs special handling any way.

Also there are more ports than pcl requiring the information since I can remember saying 'this won't work correctly in a custom triplet a few times in different prs'

@BillyONeal
Copy link
Member

I added requires:discussion back so that we look at Neumann-A's reply to Robert

@BillyONeal
Copy link
Member

To our understanding, there are 2 expected use cases for this proposal:

We admit that there may be other use cases than enumerated above which might argue to revisit this. However. we believe the above cases are better served as enumerated above.

@BillyONeal BillyONeal closed this Apr 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:vcpkg-feature The issue is a new capability of the tool that doesn’t already exist and we haven’t committed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[vcpkg] Make information about dependent ports available to currently building port
5 participants