hashicorp / vagrant

Vagrant is a tool for building and distributing development environments.
https://www.vagrantup.com
Other
26.02k stars 4.42k forks source link

Alpine ARM64 build fails because of old grpc version #13353

Open z0rb opened 4 months ago

z0rb commented 4 months ago

Debug output

14 1041.2 In file included from third_party/re2/util/pcre.cc:21:

14 1041.2 third_party/re2/util/pcre.h:503:11: error: 'int32_t' does not name a type

14 1041.2 503 | mutable int32_t hitlimit; // Hit limit during execution

1041.2 An error occurred while installing grpc (1.56.2), and Bundler cannot continue. 1041.2 1041.2 In Gemfile: 1041.2 vagrant was resolved to 2.3.8.dev, which depends on 1041.2 grpc

Expected behavior

Build should succeed in container for alpine:3.19.1.

Actual behavior

Build failed.

Reproduction information

Vagrant version

2.4.1

Host operating system

GNU/Linux

Guest operating system

Steps to reproduce

  1. Clone repository in alpine:3.19.1 based Dockerfile with required dependencies.
  2. Clone Vagrant repo and execute bundle install.

I have traced the failure to the following diff where grpc has been pinned to 1.56: https://github.com/hashicorp/vagrant/compare/2.3.8.dev+000094-a7135c00...2.3.8.dev+000098-91191982#diff-93a1ba7172ffd60d0dda0a39a5c3538c0ca7b1b30efe1996c9dd38e2c78253d9R23

Before that change the builds were using grpc > 1.60 and there was no issue building in Alpine ARM64.

The core cause comes from google/re2 which has been fixed in the more recent releases, e.g.: https://github.com/google/re2/blob/main/util/pcre.h

Here is the change that was made: https://groups.google.com/g/re2-dev/c/HrOT3p8dNPw

Would it be possible to update grpc in main/nightly/next-release?