pico-sdk icon indicating copy to clipboard operation
pico-sdk copied to clipboard

Add a Github action in CI to check for a working bazel build

Open cramertj opened this issue 1 year ago • 1 comments

Adding a minimal check that does something like:

  • Do the bazel setup https://pigweed.dev/docs/get_started/github_actions.html
  • Grab HEAD of Picotool
  • run ./tools/run_all_bazel_checks.py --picotool-dir=./tmp/picotool

Would help to track when the Bazel build is broken and needs fixing, as well as helping after-the-fact to figure out what ranges have a known-working Bazel build.

cramertj avatar Sep 25 '24 23:09 cramertj

I put together a presubmit in #1973 that covers the following:

  • Pico SDK Bazel build covering RP2040, RP2350, and a few extra configuration flavors (clang, Pico W) for macOS, Linux, and Windows.
  • Host build of the few compatible tests macOS, Linux, and Windows.
  • Pico SDK + Picotool build at HEAD of develop branch for macOS, Linux, and Windows.
  • Pico SDK + Picotool build at current minimum BCR version of Picotool (i.e. oldest backwards-compatible release) for macOS, Linux, and Windows.
  • Various other checks (check to ensure all files are enumerated in the Bazel build, ensure configuration options available in CMake are available in Bazel).

Currently, the macOS and Linux builds are passing. Windows is hitting some issues when building Picotool (unsurprisingly). The "other" check is failing right now since new Pico W-related configuration options were added that I haven't hooked up yet.

A few checks I'd also like to add eventually:

  • Verify submodule pins match pins in MODULE.bazel.
  • Verify project version strings match those in CMake.

armandomontanez avatar Oct 04 '24 16:10 armandomontanez

moving to 2.2.0 as this is now partially done in 2.1.0

kilograham avatar Nov 18 '24 23:11 kilograham

@armandomontanez I think these

A few checks I'd also like to add eventually:

  • Verify submodule pins match pins in MODULE.bazel.
  • Verify project version strings match those in CMake.

were both done in #2039 , right?

lurch avatar Nov 19 '24 00:11 lurch

Yep, we can close this one. We've got a pretty nice set of automated checks now.

armandomontanez avatar Nov 19 '24 00:11 armandomontanez