Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No CMake required for non-FIPS #317

Merged
merged 29 commits into from
Apr 10, 2024
Merged

No CMake required for non-FIPS #317

merged 29 commits into from
Apr 10, 2024

Conversation

justsmth
Copy link
Contributor

@justsmth justsmth commented Jan 24, 2024

Issues:

Addresses Issues:

Description of changes:

  • Allow for non-FIPS build requiring only a C compiler.
  • Extended existing bindgen automation to also collect require information for no-CMake build.
  • Cleaned up build logic around platform detection.
  • Re-aligned aws-lc-fips-sys builder/main.rs with aws-lc-sys.

Call-outs:

  • The change allows the build to be performed w/o CMake on the same platforms for which we pre-generate the bindings: i686-unknown-linux-gnu, x86_64-unknown-linux-gnu, aarch64-unknown-linux-gnu, x86_64-unknown-linux-musl, aarch64-unknown-linux-musl, x86_64-apple-darwin, aarch64-apple-darwin
  • The AWS_LC_SYS_CMAKE_BUILDER environment variable can be used to force the build to use, or not use, CMake.

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

@codecov-commenter
Copy link

codecov-commenter commented Jan 24, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 95.82%. Comparing base (a29a615) to head (b6d06c8).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #317   +/-   ##
=======================================
  Coverage   95.82%   95.82%           
=======================================
  Files          60       60           
  Lines        7865     7865           
=======================================
  Hits         7537     7537           
  Misses        328      328           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@camshaft
Copy link
Collaborator

One thing to note that we need to replicate (and maintain) the build-time checks here:

https://github.com/aws/aws-lc/blob/37708f52446ee727ebeea6beaba75baf0588593b/CMakeLists.txt#L426-L430
https://github.com/aws/aws-lc/blob/37708f52446ee727ebeea6beaba75baf0588593b/CMakeLists.txt#L311-L317

@justsmth justsmth merged commit 564b3c7 into aws:main Apr 10, 2024
166 checks passed
@justsmth justsmth deleted the no-cmake-build branch April 10, 2024 20:05
@pronebird
Copy link

pronebird commented Apr 17, 2024

What do you refer to when you say FIPS? Federal Information Processing Standards? Apologize for being silly, not familiar with the abbreviation.

@justsmth
Copy link
Contributor Author

Yeah, "FIPS" stands for "Federal Information Processing Standards". We perform a special build process for AWS-LC when the "fips" feature is enabled. There is more information and links in this blog post about it: https://aws.amazon.com/blogs/security/aws-lc-is-now-fips-140-3-certified/

@@ -54,6 +54,7 @@ bindgen = ["dep:bindgen"] # Generate the bindings on the targetted platform as a
cmake = "0.1.48"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does cmake have to be a part of build-dependencies?

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.

5 participants