Repository navigation
Support pkg-config-rs link_files on static/target builds - #137
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #137 +/- ##
==========================================
+ Coverage 92.40% 92.64% +0.23%
==========================================
Files 8 8
Lines 3412 3564 +152
==========================================
+ Hits 3153 3302 +149
- Misses 259 262 +3 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
gdesmott
left a comment
There was a problem hiding this comment.
Thanks for your patch!
I'm happy to integrate this feature but ideally would prefer to avoid copying all this code from pkg-config-rs if possible.
| } | ||
| } | ||
|
|
||
| // Copied from pkg-config-rs: |
There was a problem hiding this comment.
It's not great to have so many tricky logic copied from pkg-config-rs.
It would be great if this could be exposed as part of their API somehow. Can you open a ticket there asking if that's something they would consider?
There was a problem hiding this comment.
Yeah, I agree. I was going back and forth on whether or not to ask them to expose it, and ended up not, but you're right that it would be much better if they said "yes".
ba1c1f4 to
a91dff7
Compare
|
(Since clippy was failing, I added an |
a91dff7 to
f5f4499
Compare
cole-h
left a comment
There was a problem hiding this comment.
@gdesmott Thanks again for the review, and sorry for letting this languish for so long... I completely forgot about it. However, I think I've addressed all your comments at this point. Unfortunately, there's been no movement upstream on exposing this function, though...
I submitted a PR just now that would fix the issue I submitted earlier; maybe that will be more successful: rust-lang/pkg-config-rs#192
@sdroege : I see you are a maintainer of |
…t arg to gen_flags
884e179 to
84872d3
Compare
|
rust-lang/pkg-config-rs#184 has been fixed (thanks @sdroege !) so we can use this once released. |
|
I hope to have time to review some more PRs and possibly merge them before making a new release. |
|
pkg-config v0.3.34 was released earlier (thanks, @/sdroege!), which |
|
@cole-h @thiblahute rust-lang/pkg-config-rs#185 might also be of interest for the things you're doing btw |
I was recently working on a project that was trying to link to another project statically. The build was failing because it couldn't link to boost; when building statically, the parts of boost that were used were propagated in the
Libs:of the library as a.astatic archive. However, if I usedpkg_configdirectly to directly probe libraries depending on these static archives from boost, the build started succeeding. That's when I noticed thatpkg-config-rshandles this via thelink_filespart of theirConfig, butsystem-depsdidn't!There are a few things here that are maybe not quite Super Awesome (like the test needing to dig so deep into the test setup functions, and having to add the target arg to the
gen_flagsfunction), so if you have thoughts or opinions on how to make them better, I'd be happy to fix them!