Allow applying patches before BUILD file generation
This adds support for patching Go dependencies before BUILD file generation and
also plumbs that support into fietsje. No actual prepatching is done in this revision.
Test Plan: This has been used successfully in code built on top of it.
X-Origin-Diff: phab/D612
GitOrigin-RevId: 7013e5f98feb57ac64ff3dc79d1a9bb94e4152a8
diff --git a/build/fietsje/dependency.go b/build/fietsje/dependency.go
index e12e272..8644bc4 100644
--- a/build/fietsje/dependency.go
+++ b/build/fietsje/dependency.go
@@ -48,6 +48,7 @@
forceBazelGeneration bool
buildTags []string
patches []string
+ prePatches []string
buildExtraArgs []string
// replace is an importpath that this dependency will replace. If this is set, this dependency will be visible
// in the build as 'importpath', but downloaded at 'replace'/'version'. This might be slighly confusing, but