Support .syso files in the srcs
lists for go_library
and go_test
rules.
#4151
+157
−9
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.
What type of PR is this?
Feature
What does this PR do? Why is it needed?
Essentially,
go build ./...
andgo test ./...
allow having.syso
files in the packages and it includes them in the packages it creates so that functions defined therein can be called from Go code.Bazel didn't allow them to be among the
srcs
in these rules until this PR.Which issues(s) does this PR fix?
Fixes #4148
Other notes for review
I also added a bunch of tests and ran them on both linux (amd64) and Mac OS (arm64).
It's quite possible that I need to add some more things to get these tests to work on other platforms which are in the CI system.