Skip to content

Draft: ExternalDependency: add get_runtime_paths method#14713

Open
lb90 wants to merge 2 commits intomesonbuild:masterfrom
lb90:dependency-objects-get-bindir
Open

Draft: ExternalDependency: add get_runtime_paths method#14713
lb90 wants to merge 2 commits intomesonbuild:masterfrom
lb90:dependency-objects-get-bindir

Conversation

@lb90
Copy link
Copy Markdown
Contributor

@lb90 lb90 commented Jun 17, 2025

Still very draft, but works!

Fixes #14712

@lb90 lb90 requested a review from jpakkane as a code owner June 17, 2025 08:12
@boimart1
Copy link
Copy Markdown

boimart1 commented Jun 17, 2025

This seems like a reasonable solution! And it looks like the same idea could be applied to PkgConfigDependency to remove the if dep.type_name == 'pkgconfig' block. Thank you!

@bruchar1 bruchar1 added dependencies modules:python Issues specific to the python module labels Jun 17, 2025
raise DependencyException(m.format(self.name, not_found, self.version))
return

def get_runtime_paths(self) -> T.Optional[T.List[str]]:
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

You should probably add this to the Dependency class instead, to make mypy happy, and to remove the need to test for existence using hasattr

@bruchar1
Copy link
Copy Markdown
Member

Would it be possible to add a test for this?

@lb90
Copy link
Copy Markdown
Contributor Author

lb90 commented Jun 25, 2025

Sorry for the delay, will get back to this very soon!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies modules:python Issues specific to the python module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Python module: installation path not added to tests extra_paths when using MSVC

3 participants