fix: Add RUSTFLAGS for Windows platform to prevent stack overflow issues#206
fix: Add RUSTFLAGS for Windows platform to prevent stack overflow issues#206felix-schultz merged 2 commits intoalphafrom
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR adds platform-specific build configuration to prevent stack overflow issues during Windows compilation in the alpha release workflow. The change sets custom RUSTFLAGS to increase stack size when building on Windows platforms.
- Added conditional RUSTFLAGS environment variable for Windows builds with increased stack size configuration
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
You can also share your feedback on Copilot code review for a chance to win a $100 gift card. Take the survey.
.github/workflows/alpha-release.yml
Outdated
| SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }} | ||
| PUBLIC_SENTRY_ENDPOINT: ${{ secrets.PUBLIC_SENTRY_ENDPOINT }} | ||
| APPLE_SIGNING_IDENTITY: ${{ env.CERT_ID }} | ||
| RUSTFLAGS: ${{ matrix.platform == 'windows-latest' && '-C link-args=/STACK:8388608 -C link-args=-Wl,--stack,8388608' || '' }} |
There was a problem hiding this comment.
The RUSTFLAGS contains conflicting linker arguments. /STACK:8388608 is MSVC-style syntax while -Wl,--stack,8388608 is GNU-style syntax. On Windows, you should use only the MSVC syntax: -C link-args=/STACK:8388608 or only the GNU syntax if using GNU toolchain.
| RUSTFLAGS: ${{ matrix.platform == 'windows-latest' && '-C link-args=/STACK:8388608 -C link-args=-Wl,--stack,8388608' || '' }} | |
| RUSTFLAGS: ${{ matrix.platform == 'windows-latest' && '-C link-args=/STACK:8388608' || '' }} |
This pull request introduces a platform-specific build configuration for Windows in the alpha release workflow. The main change is the addition of custom
RUSTFLAGSto increase the stack size when building on Windows, which can help prevent stack overflow issues during compilation.Build configuration update:
.github/workflows/alpha-release.yml: Added a conditionalRUSTFLAGSenvironment variable to set increased stack size for Windows builds.