Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build(deps): Update protobuf to v22.5 #1166

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:


env:
PROTOC_VERSION: '3.20.3'
PROTOC_VERSION: '3.22.5'
clippy_rust_version: '1.80'

jobs:
Expand Down
23 changes: 1 addition & 22 deletions protobuf/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use std::fs;
use std::path::{Path, PathBuf};
use std::process::Command;

use anyhow::{ensure, Context, Result};
use anyhow::{Context, Result};

fn main() -> Result<()> {
let out_dir =
Expand All @@ -20,8 +20,6 @@ fn main() -> Result<()> {
let protobuf_dir = &out_dir.join(format!("protobuf-{}", version));

if !protobuf_dir.exists() {
apply_patches(&src_dir)?;

let build_dir = &out_dir.join(format!("build-protobuf-{}", version));
fs::create_dir_all(build_dir).expect("failed to create build directory");

Expand Down Expand Up @@ -90,25 +88,6 @@ fn git_describe(src_dir: &Path) -> Result<String> {
Ok(stdout.trim().to_string())
}

/// Apply patches to the protobuf source directory
fn apply_patches(src_dir: &Path) -> Result<()> {
let mut patch_src = env::current_dir().context("failed to get current working directory")?;
patch_src.push("src");
patch_src.push("fix-conformance_test_runner-cmake-build.patch");

let rc = Command::new("patch")
.arg("-p1")
.arg("-i")
.arg(patch_src)
.current_dir(src_dir)
.status()
.context("failed to apply patch")?;
// exit code: 0 means success; 1 means already applied
ensure!(rc.code().unwrap() <= 1, "protobuf patch failed");

Ok(())
}

fn install_protoc_and_conformance_test_runner(
src_dir: &Path,
build_dir: &Path,
Expand Down
41 changes: 0 additions & 41 deletions protobuf/src/fix-conformance_test_runner-cmake-build.patch

This file was deleted.

2 changes: 1 addition & 1 deletion third_party/protobuf
Submodule protobuf updated 2619 files
Loading