diff options
Diffstat (limited to 'google-guest-agent.spec')
| -rw-r--r-- | google-guest-agent.spec | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/google-guest-agent.spec b/google-guest-agent.spec index c1a4e77..ddef508 100644 --- a/google-guest-agent.spec +++ b/google-guest-agent.spec @@ -21,7 +21,7 @@ %endif %define _version 20260309.00 -%define _go /usr/bin/go +%define _go /usr/local/go/bin/go %define _gopath /tmp Name: google-guest-agent @@ -44,7 +44,7 @@ BuildArch: %{_arch} BuildRequires: systemd %endif -BuildRequires: go +BuildRequires: curl Obsoletes: python-google-compute-engine, python3-google-compute-engine @@ -52,6 +52,10 @@ Obsoletes: python-google-compute-engine, python3-google-compute-engine Contains the Google guest agent binary. %prep +curl -L -o /tmp/go.tar.gz https://go.dev/dl/go1.25.0.linux-amd64.tar.gz +rm -rf /usr/local/go +tar -C /usr/local -xzf /tmp/go.tar.gz +rm -f /tmp/go.tar.gz %if 0%{?build_plugin_manager} %autosetup -a 1 @@ -59,9 +63,8 @@ Contains the Google guest agent binary. %autosetup %endif -find . -name "go.mod" -exec sed -i 's/^go 1\.[0-9]\+$/go 1.21/' {} \; - %build +export GOROOT=/usr/local/go export GOPROXY=https://goproxy.cn,direct export GOSUMDB=sum.golang.org |
