Skip to content

cmake: improve dependency processing#2331

Merged
sporksmith merged 3 commits intoshadow:mainfrom
sporksmith:guix
Aug 8, 2022
Merged

cmake: improve dependency processing#2331
sporksmith merged 3 commits intoshadow:mainfrom
sporksmith:guix

Conversation

@sporksmith
Copy link
Copy Markdown
Contributor

  • Use pkg-config instead of a custom module to find GLIB. Latter didn't work in a guix pure environment, and potentially other "unusual" directory layouts.
  • Improve how we process dependencies for our Rust project, removing some accumulated hard-coded workarounds.

Progress on #2304

@sporksmith sporksmith added this to the Code health and maintenance milestone Aug 6, 2022
@github-actions github-actions bot added Component: Build Build/install tools and dependencies Component: Libraries Support functions like LD_PRELOAD and logging Component: Main Composing the core Shadow executable Component: Testing Unit and integration tests and frameworks labels Aug 6, 2022
@sporksmith sporksmith requested a review from stevenengler August 6, 2022 22:49
@sporksmith sporksmith marked this pull request as ready for review August 6, 2022 22:49
@github-actions github-actions bot added the Component: Documentation In-repository documentation, under docs/ label Aug 8, 2022
@sporksmith sporksmith requested a review from stevenengler August 8, 2022 20:11
This is more portable than the custom FindGLIB that was previously used.
In particular it can correctly locate GLIB in a pure guix (and
presumably nix, but untested) environment.

Progress on shadow#2304
This allows extending the pkg-config search path, and supersedes
--library and --include.

fixup! squash! Make Rust target compiler flag generation more robust
* Used the IMPORTED_TARGET feature in pkg_check_modules to get a cmake
target for glib, which can be queried for more metadata.
* Made the dependency-processing loop check target type to determine how
to handle correctly, and recurse into additional dependencies.
* Removed some previous hard-coded workarounds.
@sporksmith sporksmith enabled auto-merge August 8, 2022 21:10
@sporksmith sporksmith merged commit 2e4347a into shadow:main Aug 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Component: Build Build/install tools and dependencies Component: Documentation In-repository documentation, under docs/ Component: Libraries Support functions like LD_PRELOAD and logging Component: Main Composing the core Shadow executable Component: Testing Unit and integration tests and frameworks

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants