Skip to content

Commit f89bd92

Browse files
Prepare for Go 1.26
1 parent e96bddf commit f89bd92

File tree

8 files changed

+616
-3
lines changed

8 files changed

+616
-3
lines changed

.github/dependabot.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# To get started with Dependabot version updates, you'll need to specify which
2+
# package ecosystems to update and where the package manifests are located.
3+
# Please see the documentation for all configuration options:
4+
# https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
5+
6+
version: 2
7+
updates:
8+
- package-ecosystem: "github-actions"
9+
directory: "/"
10+
schedule:
11+
interval: "weekly"

.github/workflows/test-go1_24.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ name: Build patched Go 1.24 for tests
22

33
on:
44
workflow_dispatch:
5-
schedule:
6-
- cron: '10 0 * * 6'
5+
#schedule:
6+
#- cron: '0 0 * * 6'
77
push:
88
branches:
99
- build

.github/workflows/test-go1_25.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Build patched Go 1.25 for tests
33
on:
44
workflow_dispatch:
55
schedule:
6-
- cron: '20 0 * * 6'
6+
- cron: '10 0 * * 6'
77
push:
88
branches:
99
- build

.github/workflows/test-go1_26.yml

Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
name: Build patched Go 1.25 for tests
2+
3+
on:
4+
workflow_dispatch:
5+
schedule:
6+
- cron: '20 0 * * 6'
7+
push:
8+
branches:
9+
- build
10+
- "release-branch.go1.26"
11+
paths:
12+
- ".github/workflows/test-go1_26.yml"
13+
- "**/*.go"
14+
pull_request:
15+
types: [opened, synchronize, reopened]
16+
branches:
17+
- build
18+
- "release-branch.go1.26"
19+
paths:
20+
- ".github/workflows/test-go1_26.yml"
21+
- "**/*.go"
22+
23+
jobs:
24+
build:
25+
runs-on: ubuntu-latest
26+
permissions:
27+
contents: write
28+
strategy:
29+
matrix:
30+
goos: [windows]
31+
goarch: [amd64, 386]
32+
buildtarget: ['release-branch.go1.26']
33+
fail-fast: false
34+
env:
35+
GOOS: ${{ matrix.goos }}
36+
GOARCH: ${{ matrix.goarch }}
37+
CGO_ENABLED: 0
38+
steps:
39+
- name: Show workflow information
40+
run: |
41+
_NAME="$GOOS-$GOARCH"
42+
echo "GOOS: $GOOS, GOARCH: $GOARCH, APPLY-BRANCH: ${{ matrix.buildtarget }}"
43+
echo "ASSET_NAME=$_NAME" >> $GITHUB_ENV
44+
45+
- name: Download source
46+
uses: actions/checkout@v4
47+
with:
48+
repository: 'golang/go'
49+
ref: ${{ matrix.buildtarget }}
50+
51+
# Patches for Go 1.25.x before more minor changes introduces.
52+
- name: Apply patch
53+
run: |
54+
curl -L -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" https://github.com/XTLS/go-win7/raw/refs/heads/build/unified-1-26-patch.diff | patch --verbose -p 1
55+
56+
- name: Set-up Go
57+
uses: actions/setup-go@v5
58+
with:
59+
go-version-file: 'src/go.mod'
60+
check-latest: true
61+
62+
- name: Build patched Go
63+
shell: bash
64+
run: |
65+
cd ./src
66+
. ./make.bash "$@" --no-banner
67+
../bin/go tool dist banner
68+
cd ..
69+
70+
- name: Copy binaries into bin
71+
if: matrix.goos != 'linux' || matrix.goarch != 'amd64'
72+
shell: bash
73+
run: |
74+
cd ./bin
75+
DIR="${GOOS}_${GOARCH}"
76+
if [ -d "${DIR}" ]; then
77+
echo "Found ${DIR} copying binaries"
78+
rm ./go*
79+
for BINARY in "${DIR}"/*
80+
do
81+
echo "mv ./${BINARY} ./"
82+
mv ./${BINARY} ./
83+
done
84+
rm -r ./"${DIR}"
85+
rm -r ../pkg/tool/linux_amd64/
86+
fi
87+
cd ..
88+
ls -al ./bin
89+
90+
- name: Upload package to Artifacts
91+
uses: actions/upload-artifact@v4
92+
with:
93+
name: go-for-win7-${{ env.ASSET_NAME }}
94+
path: |
95+
./*

LOG-RRB

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,8 @@ Go 1.24
1414
Go 1.25
1515
2025-03-31 https://github.com/golang/go/commit/6d418096b2dfe2a2e47b7aa83b46748fb301e6cb os: avoid symlink races in RemoveAll on Windows [affected]
1616
2025-05-21 https://github.com/golang/go/commit/896097000912761dbd31cead2bec99f17534f521 os: add Root.RemoveAll [related 6d418096b2dfe2a2e47b7aa83b46748fb301e6cb] [affected]
17+
18+
Go 1.26
19+
2025-09-12
20+
2025-08-01 https://github.com/golang/go/commit/ef4054978692bd934eb575d0027c1c5476af9931 runtime,syscall: move loadlibrary and getprocaddress to syscall [related a17d959debdb04cd550016a3501dd09d50cd62e7] [partial affected]
21+
2025-09-12 https://github.com/golang/go/commit/889e71c2ac43f22dbd41c0b935acac2e778c8f87 runtime: move Windows types and consts to internal/runtime/syscall/windows [related 48042aa09c2f878c4faa576948b07fe625c4707a] [patch reconstruct needed]

README-eng.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,3 +100,17 @@ These patches must be applied from up to down:
100100
1. https://github.com/XTLS/go-win7/commit/b5e4a6d5b3d0b076414d04cc3d6002f816bc0c25 / [Git diff](https://github.com/XTLS/go-win7/commit/b5e4a6d5b3d0b076414d04cc3d6002f816bc0c25.diff)
101101
1. https://github.com/XTLS/go-win7/commit/949393bde276adbeaf41688f086feb23e24abe88 / [Git diff](https://github.com/XTLS/go-win7/commit/949393bde276adbeaf41688f086feb23e24abe88.diff)
102102
1. https://github.com/XTLS/go-win7/commit/fc29c4ae1cd53d6761d4324c4625cc8a149c55d3 / [Git diff](https://github.com/XTLS/go-win7/commit/fc29c4ae1cd53d6761d4324c4625cc8a149c55d3.diff)
103+
104+
## Go 1.26
105+
106+
- Windows 8.1 Update 3 / Windows Server 2012 R2: Can run official distributed Go SDK and binaries built from official SDK, but a problem may occur when removing files, so now it is also in the range of this repository.
107+
- Windows 7 SP1 / Windows Server 2008 R2: Require KB4474419 installed, require patches in SDK, and binaries must be built with patched SDK.
108+
109+
#### Patches for Windows 7 / Windows Server 2008 R2
110+
111+
These patches must be applied from up to down:
112+
113+
1. https://github.com/XTLS/go-win7/commit/86eda38dabd1753092f64de7dcd2050d346c89b4 / [Git diff](https://github.com/XTLS/go-win7/commit/86eda38dabd1753092f64de7dcd2050d346c89b4.diff)
114+
1. https://github.com/XTLS/go-win7/commit/c3e5e430625ba7ab5d638c753f94cc52253793f5 / [Git diff](https://github.com/XTLS/go-win7/commit/c3e5e430625ba7ab5d638c753f94cc52253793f5.diff)
115+
1. https://github.com/XTLS/go-win7/commit/d72cb94820d800b72f4c7a018f3948908b876460 / [Git diff](https://github.com/XTLS/go-win7/commit/d72cb94820d800b72f4c7a018f3948908b876460.diff)
116+
1. https://github.com/XTLS/go-win7/commit/0d36c60d2c0754fde7e4e7e4773e0349527cff08 / [Git diff](https://github.com/XTLS/go-win7/commit/0d36c60d2c0754fde7e4e7e4773e0349527cff08.diff)

README-zho-hans.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,3 +100,17 @@
100100
1. https://github.com/XTLS/go-win7/commit/b5e4a6d5b3d0b076414d04cc3d6002f816bc0c25 / [Git diff](https://github.com/XTLS/go-win7/commit/b5e4a6d5b3d0b076414d04cc3d6002f816bc0c25.diff)
101101
1. https://github.com/XTLS/go-win7/commit/949393bde276adbeaf41688f086feb23e24abe88 / [Git diff](https://github.com/XTLS/go-win7/commit/949393bde276adbeaf41688f086feb23e24abe88.diff)
102102
1. https://github.com/XTLS/go-win7/commit/fc29c4ae1cd53d6761d4324c4625cc8a149c55d3 / [Git diff](https://github.com/XTLS/go-win7/commit/fc29c4ae1cd53d6761d4324c4625cc8a149c55d3.diff)
103+
104+
## Go 1.26
105+
106+
- Windows 8.1 Update 3 / Windows Server 2012 R2: 可直接运行官方 Go SDK 及其构建的二进制文件,但是可能会在文件删除操作上出现问题,因此纳入本仓库管理范围。
107+
- Windows 7 SP1 / Windows Server 2008 R2:需要系统已安装 KB4474419,SDK 中已植入补丁,并且只能运行用修补后的 SDK 构建的二进制。
108+
109+
#### 用于 Windows 7 / Windows Server 2008 R2 的补丁
110+
111+
这些补丁必须按照从上到下的顺序来修补:
112+
113+
1. https://github.com/XTLS/go-win7/commit/86eda38dabd1753092f64de7dcd2050d346c89b4 / [Git diff](https://github.com/XTLS/go-win7/commit/86eda38dabd1753092f64de7dcd2050d346c89b4.diff)
114+
1. https://github.com/XTLS/go-win7/commit/c3e5e430625ba7ab5d638c753f94cc52253793f5 / [Git diff](https://github.com/XTLS/go-win7/commit/c3e5e430625ba7ab5d638c753f94cc52253793f5.diff)
115+
1. https://github.com/XTLS/go-win7/commit/d72cb94820d800b72f4c7a018f3948908b876460 / [Git diff](https://github.com/XTLS/go-win7/commit/d72cb94820d800b72f4c7a018f3948908b876460.diff)
116+
1. https://github.com/XTLS/go-win7/commit/0d36c60d2c0754fde7e4e7e4773e0349527cff08 / [Git diff](https://github.com/XTLS/go-win7/commit/0d36c60d2c0754fde7e4e7e4773e0349527cff08.diff)

0 commit comments

Comments
 (0)