-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
pkgconfig: Pull dependencies of static dependencies #6393
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -120,8 +120,15 @@ def _process_libs(self, libs, public): | |
processed_reqs.append(obj.generated_pc) | ||
elif isinstance(obj, dependencies.PkgConfigDependency): | ||
if obj.found(): | ||
processed_reqs.append(obj.name) | ||
self.add_version_reqs(obj.name, obj.version_reqs) | ||
if obj.static: | ||
# in case of embedded static dependency | ||
for arg in obj.link_args: | ||
if not os.sep in arg: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why this check? I guess it's because static libs are replaced by full path to .a file, and shared libraries are kept as -lfoo arg? Please add a comment explaining it. I would rather check with |
||
# pull external dependencies | ||
processed_reqs.append(arg) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Since it's a link_arg, it should go to processed_libs, I think. processed_reqs is for pkg-config names. |
||
else: | ||
processed_reqs.append(obj.name) | ||
self.add_version_reqs(obj.name, obj.version_reqs) | ||
elif isinstance(obj, dependencies.ThreadDependency): | ||
processed_libs += obj.get_compiler().thread_link_flags(obj.env) | ||
processed_cflags += obj.get_compiler().thread_flags(obj.env) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[Flake8] test for membership should be 'not in' (see on Sider)