Skip to content

cmake: find zlib using PkgConfig#39

Merged
davvid merged 2 commits into
wdas:masterfrom
davvid:zlib
Mar 8, 2019
Merged

cmake: find zlib using PkgConfig#39
davvid merged 2 commits into
wdas:masterfrom
davvid:zlib

Conversation

@davvid

@davvid davvid commented Mar 8, 2019

Copy link
Copy Markdown
Member

Build against zlib using an imported target that can be reused by downstream dependents.

davvid added 2 commits March 8, 2019 09:37
Resolve symlinks to their physical location when using find_package() to
find external packages.
FindZlib burns in a path to zlib in the Ptex exported targets,
which is undesirable since it make packages unrelocatable.

Use pkg-config to find zlib and setup an imported target.  Using
the imported target handles setting up library and include paths
so that we don't have to manually setup zlib beyond mentioning
PkgConfig::Ptex_ZLIB in target_link_libraries().

Setup PkgConfig::Ptex_ZLIB in Ptex's exported targets file so
that downstream consumers will have PkgConfig::Ptex_ZLIB too.
@davvid davvid merged commit 1b8bc98 into wdas:master Mar 8, 2019
@davvid davvid deleted the zlib branch June 30, 2021 02:40
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.

1 participant