Repository navigation
Conversation
libqatzip calls into libnuma, libzstd, libqat and libusdm, but qatzip.pc only lists zlib and liblz4. As a result, a static link using "pkg-config --static --libs qatzip" fails with undefined references to the cpaDc*, ZSTD_* and libnuma functions. Fix this by adding -lnuma and PTHREAD_LIBS to Libs.private, and libzstd to Requires.private. When building against qatlib, also require qatlib, which pulls in libqat and libusdm in the order a static link needs, along with their own dependencies. The out-of-tree driver ships no .pc file, so that build is left unchanged. Signed-off-by: Kefu Chai <k.chai@proxmox.com>
Contributor
|
Thanks for the PR. We will check and merge into our upcoming release. |
There was a problem hiding this comment.
🟢 Approval recommended
The pkg-config dependency updates have no active review issues.
No open issues 🎉
What changed in this PR
This PR updates QATzip’s pkg-config metadata to supply missing dependencies for static linking.
Changes:
- Adds NUMA and pthread linker flags to
Libs.private. - Adds
libzstdas a private package dependency. - Requires
qatlibfor qatlib-backed builds, without adding that requirement for out-of-tree driver builds.
| File | Description |
|---|---|
qatzip.pc.in |
Declares private libraries and package dependencies needed for static linking. |
configure.ac |
Sets and exports the conditional qatlib pkg-config requirement. |
Review effort: Balanced
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
libqatzip calls into libnuma, libzstd, libqat and libusdm, but qatzip.pc only lists zlib and liblz4. As a result, a static link using "pkg-config --static --libs qatzip" fails with undefined references to the cpaDc*, ZSTD_* and libnuma functions.
Fix this by adding
-lnumaandPTHREAD_LIBStoLibs.private, and libzstd to Requires.private. When building against qatlib, also require qatlib, which pulls in libqat and libusdm in the order a static link needs, along with their own dependencies. The out-of-tree driver ships no .pc file, so that build is left unchanged.