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

meson: Override dependency to improve usage as a subproject #282

Merged
merged 1 commit into from
Dec 18, 2022

Conversation

nirbheek
Copy link
Contributor

With this change, libepoxy can be consumed as a subproject without making any changes to the build files of a project. All you need to do is provide a wrap file with a [provide] section:

https://mesonbuild.com/Wrap-dependency-system-manual.html#provide-section

This is also necessary because otherwise projects need to hard-code the subproject name, which might be libepoxy when using wrap-git or libepoxy-1.5.10 when using wrap-file (to build from a release tarball). This can cause conflicts between different subprojects that consume libepoxy differently.

Other projects like glib, cairo, pango, etc already do this.

With this change, libepoxy can be consumed as a subproject without
making any changes to the build files of a project. All you need to do
is provide a wrap file with a `[provide]` section:

https://mesonbuild.com/Wrap-dependency-system-manual.html#provide-section

This is also necessary because otherwise projects need to hard-code
the subproject name, which might be `libepoxy` when using `wrap-git` or
`libepoxy-1.5.10` when using `wrap-file` (to build from a release
tarball). This can cause conflicts between different subprojects that
consume libepoxy differently.

Other projects like glib, cairo, pango, etc already do this.
@ebassi ebassi merged commit 2df68f8 into anholt:master Dec 18, 2022
@nirbheek nirbheek deleted the improve-subproj-usage branch December 18, 2022 17:43
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.

2 participants