awslabs / aws-c-common

Core c99 package for AWS SDK for C. Includes cross-platform primitives, configuration, data structures, and error handling.
Apache License 2.0
263 stars 159 forks source link

Forward CMake variables to prebuilding dependencies #1161

Closed sfod closed 2 days ago

sfod commented 1 month ago

Issue #, if available:

When prebuilding dependencies, we need to pass certain CMake variables from parent cmake process to child cmake process (e.g. toolchain file or path to C compiler). CMake doesn't provide this functionality out of the box.

Description of changes:

This PR implements a new CMake function that checks CMake cache file and collects variables that may affect build process. aws_prebuild_dependency uses this new function, so no changes are required in the downstream projects.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

codecov-commenter commented 1 month ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 83.63%. Comparing base (252e8c2) to head (8f8067c).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1161 +/- ## ======================================= Coverage 83.63% 83.63% ======================================= Files 57 57 Lines 5953 5953 ======================================= Hits 4979 4979 Misses 974 974 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.