Add grpc package (v1.83.0) - #555
Conversation
📝 WalkthroughWalkthroughAdds a gRPC 1.83.0 package definition. The package fetches a verified GitHub archive, declares dependencies and outputs, builds with CMake into ChangesgRPC package
Estimated code review effort: 3 (Moderate) | ~20 minutes Sequence Diagram(s)sequenceDiagram
participant BuildSpec
participant build.sh
participant CMake
participant OUTPUT_DIR
participant PackageTests
BuildSpec->>build.sh: pass package version
build.sh->>CMake: configure gRPC with packaged dependencies
CMake->>CMake: compile shared libraries
CMake->>OUTPUT_DIR: install package outputs
PackageTests->>OUTPUT_DIR: link against gRPC and run plugin and proto checks
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 3
🧹 Nitpick comments (1)
packages/grpc/build.sh (1)
1-2: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winUse the repository shell convention.
Use
#!/bin/shandset -e. This script does not use Bash-specific syntax.Proposed fix
-#!/bin/bash -set -euo pipefail +#!/bin/sh +set -eBased on learnings,
packages/*/build.shscripts use#!/bin/shandset -e; individual packages must not switch to Bash strict mode.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@packages/grpc/build.sh` around lines 1 - 2, Update the `packages/grpc/build.sh` shell setup to use the repository convention: replace the Bash shebang with `#!/bin/sh` and use `set -e` instead of `set -euo pipefail`, preserving the script’s existing commands.Source: Learnings
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@packages/grpc/build.ncl`:
- Around line 1-10: Update the import bindings in the minimal.ncl destructuring
so lowercase identifiers come first in alphabetical order, followed by
alphabetized uppercase identifiers; specifically place gcc before glibc and
order BuildSpec, Local, OutputBin, OutputData, OutputLib, Source, and Test
accordingly.
- Around line 58-64: Update the outputs declaration to explicitly capture gRPC’s
installed root certificate at usr/share/grpc/etc/roots.pem, using the
appropriate OutputData type alongside the existing bins, libs, headers, cmake,
and pkgconfig outputs.
In `@packages/grpc/build.sh`:
- Around line 10-23: Update the cmake configuration in build.sh to disable
gRPC’s implicit archive downloads while retaining the existing
gRPC_*_PROVIDER=package settings and GitHub tag archive behavior. Add the
appropriate gRPC CMake option alongside the other gRPC configuration flags.
---
Nitpick comments:
In `@packages/grpc/build.sh`:
- Around line 1-2: Update the `packages/grpc/build.sh` shell setup to use the
repository convention: replace the Bash shebang with `#!/bin/sh` and use `set
-e` instead of `set -euo pipefail`, preserving the script’s existing commands.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 32cbc01e-1a4f-4396-a113-066aaff4b61b
📒 Files selected for processing (2)
packages/grpc/build.nclpackages/grpc/build.sh
|
/build |
|
/build |
|
Lovel, do you have time to add an exec test for each executable this package produces? For example, see what we do for This makes catching issues easier when we bump up the src version in the future. |
Yes, I'll add it. |
|
/build |
|
Run |
|
/build |
Summary
Adds a new package for
grpc(gRPC Core), a high-performance, open-source universal RPC framework. This allows downstream C++ projects (and other languages) in the Minimal ecosystem to consume gRPC and its plugins natively.Changes
grpc.1.83.0abseil-cpp,protobuf,c-ares,openssl,re2,zlib) via CMake package providers (-DgRPC_*_PROVIDER=package).BUILD_SHARED_LIBS=ONandCMAKE_INSTALL_LIBDIR=/usr/libto consistently emit.soartifacts alongside standard CMake/pkgconfig data.glibcandgccsubsets forlibgcc/libstdcpp) so downstream consumers can successfully link and load the shared libraries.Checklist
min checkpasses for the affected packages/harnesses.min patched-build <name>succeeds for any package I added or modified.source_provenancepoints to the canonical upstream and the source builds from source (not a prebuilt release binary) where the required toolchain is available.sha256against the upstream archive.Notes for reviewers
Summary by CodeRabbit