Skip to content

Install protoc and libclang in Windows bootstrap#11536

Open
SATYAM-PRATIBHAN wants to merge 3 commits into
warpdotdev:masterfrom
SATYAM-PRATIBHAN:satyam/fix-windows-bootstrap-deps
Open

Install protoc and libclang in Windows bootstrap#11536
SATYAM-PRATIBHAN wants to merge 3 commits into
warpdotdev:masterfrom
SATYAM-PRATIBHAN:satyam/fix-windows-bootstrap-deps

Conversation

@SATYAM-PRATIBHAN
Copy link
Copy Markdown

@SATYAM-PRATIBHAN SATYAM-PRATIBHAN commented May 22, 2026

Description

This PR addresses missing build dependencies in the Windows bootstrap script. It adds automated installation of protoc (via protobuf) and libclang (via LLVM) using winget.

These tools are hard dependencies for prost-build and bindgen, respectively. Without them, a fresh cargo build on Windows fails on crates like warp_multi_agent_api. This change aligns the Windows bootstrap experience with the Linux improvements previously made in #9527.

Linked Issue

Fixes #11301

  • The linked issue is labeled ready-to-spec or ready-to-implement.
  • Where appropriate, screenshots or a short video of the implementation are included below (especially for user-visible or UI changes).

Testing

Manual verification was performed by:

  1. Reviewing script/windows/bootstrap.ps1 to ensure correct winget IDs are used (protobuf and LLVM.LLVM).
  2. Verifying that Show-BootstrapPreview correctly advertises the new installation steps.
  3. Testing on a Windows environment to confirm winget successfully identifies and installs these packages when they are missing.
  4. Confirming that after installation and a shell restart, protoc --version and clang --version are available in the PATH.
  • I have manually tested my changes locally with ./script/run

Screenshots / Videos

N/A - scripting change for build environment setup.

Agent Mode

  • Warp Agent Mode - This PR was created via Warp's AI Agent Mode

@cla-bot
Copy link
Copy Markdown

cla-bot Bot commented May 22, 2026

Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement, and we don't seem to have the users @SATYAM-PRATIBHAN on file. In order for us to review and merge your code, each contributor must visit https://cla.warp.dev to read and agree to our CLA. Once you have done so, please comment @cla-bot check to trigger another check.

@oz-for-oss
Copy link
Copy Markdown
Contributor

oz-for-oss Bot commented May 22, 2026

@SATYAM-PRATIBHAN

This PR is not linked to an issue that is marked with ready-to-implement.

Issue-state enforcement details:

  • Associated same-repo issues checked: none

  • Required readiness label: ready-to-implement

To continue, link this PR to a same-repo issue such as Closes #123 in the PR description, and make sure that issue has ready-to-implement.

Powered by Oz

@github-actions github-actions Bot added the external-contributor Indicates that a PR has been opened by someone outside the Warp team. label May 22, 2026
Copy link
Copy Markdown
Contributor

@oz-for-oss oz-for-oss Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@SATYAM-PRATIBHAN

This PR is not linked to an issue that is marked with ready-to-implement.

Issue-state enforcement details:

  • Associated same-repo issues checked: none

  • Required readiness label: ready-to-implement

To continue, link this PR to a same-repo issue such as Closes #123 in the PR description, and make sure that issue has ready-to-implement.

Powered by Oz

@SATYAM-PRATIBHAN
Copy link
Copy Markdown
Author

@cla-bot check

@cla-bot cla-bot Bot added the cla-signed label May 22, 2026
@cla-bot
Copy link
Copy Markdown

cla-bot Bot commented May 22, 2026

The cla-bot has been summoned, and re-checked this pull request!

@SATYAM-PRATIBHAN
Copy link
Copy Markdown
Author

/oz-review

@oz-for-oss
Copy link
Copy Markdown
Contributor

oz-for-oss Bot commented May 22, 2026

@SATYAM-PRATIBHAN

I'm re-reviewing this pull request in response to a review request.

You can view the conversation on Warp.

I completed the review and no human review was requested for this pull request.

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

Copy link
Copy Markdown
Contributor

@oz-for-oss oz-for-oss Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overview

This PR updates the Windows bootstrap script to advertise and install protoc and LLVM so fresh Windows builds have the tools needed by prost-build and bindgen.

Concerns

  • The LLVM install step does not make libclang discoverable to the current bootstrap environment, so bindgen can still fail after the script completes unless the script updates PATH or LIBCLANG_PATH.
  • The protobuf install should use the exact WinGet package ID to avoid query ambiguity and match the other automated installs.

Verdict

Found: 0 critical, 1 important, 1 suggestions

Request changes

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

Comment thread script/windows/bootstrap.ps1 Outdated
winget install -e --id JRSoftware.InnoSetup

# protoc (Protocol Buffers compiler) is required by prost-build.
winget install protobuf
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 [SUGGESTION] Use the exact WinGet package ID so the bootstrap stays non-interactive and consistent with the other package installs.

Suggested change
winget install protobuf
winget install -e --id Google.Protobuf

winget install protobuf

# LLVM provides libclang, which is required by bindgen.
winget install -e --id LLVM.LLVM
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [IMPORTANT] LLVM.LLVM installs LLVM, but the silent WinGet install does not guarantee C:\Program Files\LLVM\bin is available to this PowerShell session, so bindgen can still fail to load libclang after bootstrap. Append the LLVM bin directory to $env:PATH or set LIBCLANG_PATH after installation.

@SATYAM-PRATIBHAN
Copy link
Copy Markdown
Author

/oz-review

@oz-for-oss
Copy link
Copy Markdown
Contributor

oz-for-oss Bot commented May 22, 2026

@SATYAM-PRATIBHAN

I'm re-reviewing this pull request in response to a review request.

You can view the conversation on Warp.

I completed the review and no human review was requested for this pull request.

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

Copy link
Copy Markdown
Contributor

@oz-for-oss oz-for-oss Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overview

This PR updates the Windows bootstrap script to install protoc via Google.Protobuf and LLVM/libclang via LLVM.LLVM, and updates the bootstrap preview text.

Concerns

  • The Protobuf PATH fallback points at a hardcoded %ProgramFiles%\protobuf\bin location that does not match where winget installs the Google.Protobuf portable package, so a fresh bootstrap can still leave protoc unavailable in the current shell.

Verdict

Found: 0 critical, 1 important, 0 suggestions

Request changes

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

Comment thread script/windows/bootstrap.ps1 Outdated
# protoc (Protocol Buffers compiler) is required by prost-build.
winget install -e --id Google.Protobuf
if (-not (Get-Command -Name protoc -Type Application -ErrorAction SilentlyContinue)) {
$env:PATH += ";$env:ProgramFiles\protobuf\bin"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [IMPORTANT] Google.Protobuf is installed by winget as a portable package under WinGet's package/link directories, not $env:ProgramFiles\protobuf\bin; this fallback can still leave protoc unavailable in the current shell, so resolve and append the actual package bin path.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed external-contributor Indicates that a PR has been opened by someone outside the Warp team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Windows bootstrap missing libclang and protoc; cargo build fails

1 participant