Skip to content

Add Clang support on Windows for FIPS shared build#2982

Open
aminya wants to merge 7 commits intoaws:mainfrom
aminya:llvm
Open

Add Clang support on Windows for FIPS shared build#2982
aminya wants to merge 7 commits intoaws:mainfrom
aminya:llvm

Conversation

@aminya
Copy link
Copy Markdown

@aminya aminya commented Feb 3, 2026

Issues:

Fixes #2981

Description of changes:

This fixes building aws-lc on Windows when using Clang as the compiler.

Instead of using the non-supported linker flags with clang on Windows, the bcm compilation is handled with the correct flags and markers

Call-outs:

N/A minor build change

Testing:

Build with Cmake or Cargo as normal

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.

@aminya aminya requested a review from a team as a code owner February 3, 2026 11:24
aminya added a commit to aminya/aws-lc-rs that referenced this pull request Feb 3, 2026
Instead of using the non-supported linker flags with clang on Windows, the bcm compilation is handled with the correct flags and markers

Includes the commit from aws/aws-lc#2982
@justsmth
Copy link
Copy Markdown
Contributor

justsmth commented Feb 3, 2026

Hello! Thanks for the PR!

We have a CI workflow for testing alternative (non-MSVC) compilers on Windows. With this change, should we be able to add a "FIPS" variant for the clang jobs in this workflow?

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Feb 3, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.34%. Comparing base (0628190) to head (7751e94).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2982      +/-   ##
==========================================
- Coverage   78.35%   78.34%   -0.01%     
==========================================
  Files         689      689              
  Lines      121010   121010              
  Branches    16992    16992              
==========================================
- Hits        94813    94802      -11     
- Misses      25302    25313      +11     
  Partials      895      895              

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@aminya
Copy link
Copy Markdown
Author

aminya commented Feb 4, 2026

Hello! Thanks for the PR!

We have a CI workflow for testing alternative (non-MSVC) compilers on Windows. With this change, should we be able to add a "FIPS" variant for the clang jobs in this workflow?

Hi, you're welcome!

I created a PR for the addition of CI jobs:
#2984 (comment)

P.S: I'd rather keep the CI PR separate, as making it work requires some work.

justsmth added a commit to aws/aws-lc-rs that referenced this pull request Feb 10, 2026
Instead of using the non-supported linker flags with clang on Windows, the bcm compilation is handled with the correct flags and markers

Includes the commit from aws/aws-lc#2982

Co-authored-by: Justin W Smith <103147162+justsmth@users.noreply.github.com>
@justsmth
Copy link
Copy Markdown
Contributor

P.S: I'd rather keep the CI PR separate, as making it work requires some work.

Yeah, I've been trying to make the tests pass but am not having much luck so far. I combined the two PRs b/c the tests on the 2nd PR are needed to confirm that the first PR's changes are correct. I'll keep poking at this change till the tests pass.

aminya and others added 5 commits February 13, 2026 14:29
This fixes building aws-lc on Windows when using Clang as the compiler.

Instead of using the non-supported linker flags with clang on Windows, the bcm compilation is handled with the correct flags and markers
@aminya
Copy link
Copy Markdown
Author

aminya commented Feb 17, 2026

P.S: I'd rather keep the CI PR separate, as making it work requires some work.

Yeah, I've been trying to make the tests pass but am not having much luck so far. I combined the two PRs b/c the tests on the 2nd PR are needed to confirm that the first PR's changes are correct. I'll keep poking at this change till the tests pass.

Thanks. The build is successful, which is great.
My use case (Rustls) doesn't need FIPs, but the build failure was problematic.

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.

Compilation failure with Clang on Windows

4 participants