Get Windows Scons build working#34
Open
slipher wants to merge 11 commits into
Open
Conversation
This reverts commit 1d34ecb7cdd1e5b295ac107107abc09b22e866d8. That commit made it so that MSVC builds could only be done on Google's build bot. DEPS and buildbot/ changes were left out the revert. buildbot/ is not used by us and has a conflict.
Now I can build the loader and IRT with VS 2022, and external SCons (with pywin32 module installed), e.g. scons.exe platform=x86-64 saigo=1 werror=0 --no-clang --mode=opt-host,nacl irt_core sel_ldr
The 32-bit Windows exit codes are interpreted as signed in Python 2 and unsigned in Python 3.
The Windows builds are mostly based on MSVC, but they use the MinGW assembler. Also use this to provide readelf for the run.py test.
In run.py, on Windows add the extension to search for readelf.exe rather than readelf. It worked by accident upstream since there was a bash script named readelf in the same directory as readelf.exe.
This reverts commit 5361d3c. Makes platform_qual_test fail. I think it would be better to remove the check in production but keep it in the test.
The test target run_redir_test breaks if files are checked out with CRLF line endings. Note: Chromium suggests that you should set core.autocrlf = false in Git for working with any of their repositories.
If you had scons.exe installed in the PATH (as opposed to doing python -m SCons), it would be annoying that typing `scons` finds scons.bat before scons.exe.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Get the native Windows build with Scons working. All targets build, and (on 64-bit at least) most tests pass. You need MSVC and also MinGW (just to use the GNU assembler). In the Scons command line you must pass
saigo=1(as always),--no-clang, andmingw_dir=....