From 81aa5f6ead7a2cdd5b78db00ea7527fb54638504 Mon Sep 17 00:00:00 2001 From: root Date: Tue, 19 May 2026 01:45:03 +0000 Subject: [PATCH 1/2] fix(autopatch): auto-fix for golang on c10s Rewrote config.yaml to remove obsolete actions. The c10s spec was already updated upstream to include '%if %{race}' wrappers and changed 'GOAMD64=v3' to 'GOAMD64=v1' for the amd64v1 tsan build, and re --- config.yaml | 130 ++-------------------------------------------------- 1 file changed, 3 insertions(+), 127 deletions(-) diff --git a/config.yaml b/config.yaml index 3ae2495..4fbaa3e 100644 --- a/config.yaml +++ b/config.yaml @@ -8,123 +8,9 @@ actions: sed -i 's/^GOAMD64=v3$/GOAMD64=v2/' ./go.env grep -q '^GOAMD64=v2$' ./go.env %endif - + %build count: 1 - - target: "spec" - find: | - %global fail_on_tests 1 - replace: | - %global fail_on_tests 1 - - %global race 1 - %ifarch riscv64 - %global race 0 - %endif - count: 1 - - target: "spec" - find: | - %package race - Summary: Race detetector library object files. - Requires: %{name} = %{version}-%{release} - - %description race - Binary library objects for Go's race detector. - replace: | - %if %{race} - %package race - Summary: Race detetector library object files. - Requires: %{name} = %{version}-%{release} - - %description race - Binary library objects for Go's race detector. - %endif - count: 1 - find: | - %ifarch x86_64 - pushd "${tsan_go_dir}" - CFLAGS="%{tsan_buildflags} %{tsan_optflag}" CC=clang GOAMD64=v3 ./buildgo.sh - popd - cp "${tsan_go_dir}"/race_linux_amd64.syso ./src/runtime/race/internal/amd64v3/race_linux.syso - - pushd "${tsan_go_dir}" - CFLAGS="%{tsan_buildflags} %{tsan_optflag}" CC=clang GOAMD64=v3 ./buildgo.sh - popd - cp "${tsan_go_dir}"/race_linux_amd64.syso ./src/runtime/race/internal/amd64v1/race_linux.syso - - %else - pushd "${tsan_go_dir}" - CFLAGS="%{tsan_buildflags} %{tsan_optflag}" CC=clang ./buildgo.sh - popd - cp "${tsan_go_dir}"/race_linux_%{gohostarch}.syso ./src/runtime/race/race_linux_%{gohostarch}.syso - %endif - replace: | - %if %{race} - %ifarch x86_64 - pushd "${tsan_go_dir}" - CFLAGS="%{tsan_buildflags} %{tsan_optflag}" CC=clang GOAMD64=v3 ./buildgo.sh - popd - cp "${tsan_go_dir}"/race_linux_amd64.syso ./src/runtime/race/internal/amd64v3/race_linux.syso - - pushd "${tsan_go_dir}" - CFLAGS="%{tsan_buildflags} %{tsan_optflag}" CC=clang GOAMD64=v3 ./buildgo.sh - popd - cp "${tsan_go_dir}"/race_linux_amd64.syso ./src/runtime/race/internal/amd64v1/race_linux.syso - - %else - pushd "${tsan_go_dir}" - CFLAGS="%{tsan_buildflags} %{tsan_optflag}" CC=clang ./buildgo.sh - popd - cp "${tsan_go_dir}"/race_linux_%{gohostarch}.syso ./src/runtime/race/race_linux_%{gohostarch}.syso - %endif - %endif - count: 1 - - target: "spec" - find: | - GOROOT=$(pwd) PATH=$(pwd)/bin:$PATH go install -race std - replace: | - %if %{race} - GOROOT=$(pwd) PATH=$(pwd)/bin:$PATH go install -race std - %endif - count: 1 - - target: "spec" - find: | - %ifarch x86_64 - %exclude %{goroot}/src/runtime/race/internal/amd64v1/race_linux.syso - %exclude %{goroot}/src/runtime/race/internal/amd64v3/race_linux.syso - %else - %exclude %{goroot}/src/runtime/race/race_linux_%{gohostarch}.syso - %endif - replace: | - %if %{race} - %ifarch x86_64 - %exclude %{goroot}/src/runtime/race/internal/amd64v1/race_linux.syso - %exclude %{goroot}/src/runtime/race/internal/amd64v3/race_linux.syso - %else - %exclude %{goroot}/src/runtime/race/race_linux_%{gohostarch}.syso - %endif - %endif - count: 1 - - target: "spec" - find: | - %files race - %ifarch x86_64 - %{goroot}/src/runtime/race/internal/amd64v1/race_linux.syso - %{goroot}/src/runtime/race/internal/amd64v3/race_linux.syso - %else - %{goroot}/src/runtime/race/race_linux_%{gohostarch}.syso - %endif - replace: | - %if %{race} - %files race - %ifarch x86_64 - %{goroot}/src/runtime/race/internal/amd64v1/race_linux.syso - %{goroot}/src/runtime/race/internal/amd64v3/race_linux.syso - %else - %{goroot}/src/runtime/race/race_linux_%{gohostarch}.syso - %endif - %endif - count: 1 - target: "spec" find: | CFLAGS="%{tsan_buildflags} %{tsan_optflag}" CC=clang GOAMD64=v3 ./buildgo.sh @@ -134,18 +20,8 @@ actions: %else CFLAGS="%{tsan_buildflags} %{tsan_optflag}" CC=clang GOAMD64=v3 ./buildgo.sh %endif - count: 2 - - target: "spec" - find: | - export GOAMD64=v3 - replace: | - %ifarch x86_64_v2 - export GOAMD64=v2 - %else - export GOAMD64=v3 - %endif - count: -1 - + count: 1 + - modify_release: - suffix: ".alma.1" From 363afb03a087e2fde177f268d037d24c5da36574 Mon Sep 17 00:00:00 2001 From: eabdullin Date: Tue, 19 May 2026 14:03:39 +0300 Subject: [PATCH 2/2] Fix x86_64_v2 support --- config.yaml | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/config.yaml b/config.yaml index 4fbaa3e..ad13162 100644 --- a/config.yaml +++ b/config.yaml @@ -2,14 +2,15 @@ actions: - replace: - target: "spec" find: | - %build + %global goamd64 v3 + %global goppc64 power9 replace: | %ifarch x86_64_v2 - sed -i 's/^GOAMD64=v3$/GOAMD64=v2/' ./go.env - grep -q '^GOAMD64=v2$' ./go.env + %global goamd64 v2 + %else + %global goamd64 v3 %endif - - %build + %global goppc64 power9 count: 1 - target: "spec" find: | @@ -31,5 +32,5 @@ actions: - name: "Eduard Abdullin" email: "eabdullin@almalinux.org" line: - - "Update env var for v2" + - "Add x86_64_v2 support" - "Disable race for riscv64"