Introduce out_pc_dir attribute to expose pkgconfig files #1448
+17
−1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Whilst working on migrating https://github.com/DataDog/datadog-agent to bazel we currently have to maintain a hybrid approach and use several build systems simultaneously. We use
rules_foreign_ccto buildopensslthat is then used as a dependency to buildxmlsecthat requires presence of.pcfiles to pick up includes and shared libraries properly. This PR introduces a new attributeout_pc_dirforconfigure_makerule in order to expose a new output group to make pkgconfig files available. It works exactly the same way as in case ofout_include_direxcept the default value isn't set and the attribute is optionalExample usage can be found here:
https://github.com/DataDog/datadog-agent/pull/42930/files#diff-f3181df6a22b232f1fd24950e2b261f083553ea0b4006233952d6efc9916ec1c
I have validated functionality of
configure_makerule by running multiple builds with and withoutout_pc_dirattribute set.