Skip to content

Commit 739f6f4

Browse files
gballetfjl
andauthored
.github: add 32-bit CI targets (ethereum#32911)
This adds two new CI targets. One is for building all supported keeper executables, the other is for running unit tests on 32-bit Linux. --------- Co-authored-by: Felix Lange <[email protected]>
1 parent 59d08c6 commit 739f6f4

File tree

4 files changed

+56
-12
lines changed

4 files changed

+56
-12
lines changed

.github/workflows/go.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,47 @@ jobs:
3434
go run build/ci.go check_generate
3535
go run build/ci.go check_baddeps
3636
37+
keeper:
38+
name: Keeper Builds
39+
needs: test
40+
runs-on: [self-hosted-ghr, size-l-x64]
41+
steps:
42+
- uses: actions/checkout@v4
43+
with:
44+
submodules: true
45+
46+
- name: Set up Go
47+
uses: actions/setup-go@v5
48+
with:
49+
go-version: '1.25'
50+
cache: false
51+
52+
- name: Build
53+
run: go run build/ci.go keeper
54+
55+
test-32bit:
56+
name: "32bit tests"
57+
needs: test
58+
runs-on: [self-hosted-ghr, size-l-x64]
59+
steps:
60+
- uses: actions/checkout@v4
61+
with:
62+
submodules: false
63+
64+
- name: Set up Go
65+
uses: actions/setup-go@v5
66+
with:
67+
go-version: '1.25'
68+
cache: false
69+
70+
- name: Install cross toolchain
71+
run: |
72+
apt-get update
73+
apt-get -yq --no-install-suggests --no-install-recommends install gcc-multilib
74+
75+
- name: Build
76+
run: go run build/ci.go test -arch 386 -short -p 8
77+
3778
test:
3879
name: Test
3980
needs: lint

appveyor.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,4 @@ for:
3636
- go run build/ci.go archive -arch %GETH_ARCH% -type zip -signer WINDOWS_SIGNING_KEY -upload gethstore/builds
3737
- go run build/ci.go nsis -arch %GETH_ARCH% -signer WINDOWS_SIGNING_KEY -upload gethstore/builds
3838
test_script:
39-
- go run build/ci.go test -dlgo -arch %GETH_ARCH% -cc %GETH_CC% -short -skip-spectests
39+
- go run build/ci.go test -dlgo -arch %GETH_ARCH% -cc %GETH_CC% -short

beacon/params/config.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,8 @@ func (c *ChainConfig) LoadForks(file []byte) error {
108108
switch version := value.(type) {
109109
case int:
110110
versions[name] = new(big.Int).SetUint64(uint64(version)).FillBytes(make([]byte, 4))
111+
case int64:
112+
versions[name] = new(big.Int).SetUint64(uint64(version)).FillBytes(make([]byte, 4))
111113
case uint64:
112114
versions[name] = new(big.Int).SetUint64(version).FillBytes(make([]byte, 4))
113115
case string:
@@ -125,6 +127,8 @@ func (c *ChainConfig) LoadForks(file []byte) error {
125127
switch epoch := value.(type) {
126128
case int:
127129
epochs[name] = uint64(epoch)
130+
case int64:
131+
epochs[name] = uint64(epoch)
128132
case uint64:
129133
epochs[name] = epoch
130134
case string:

build/ci.go

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -348,24 +348,23 @@ func buildFlags(env build.Environment, staticLinking bool, buildTags []string) (
348348

349349
func doTest(cmdline []string) {
350350
var (
351-
dlgo = flag.Bool("dlgo", false, "Download Go and build with it")
352-
arch = flag.String("arch", "", "Run tests for given architecture")
353-
cc = flag.String("cc", "", "Sets C compiler binary")
354-
coverage = flag.Bool("coverage", false, "Whether to record code coverage")
355-
verbose = flag.Bool("v", false, "Whether to log verbosely")
356-
race = flag.Bool("race", false, "Execute the race detector")
357-
short = flag.Bool("short", false, "Pass the 'short'-flag to go test")
358-
cachedir = flag.String("cachedir", "./build/cache", "directory for caching downloads")
359-
skipspectests = flag.Bool("skip-spectests", false, "Skip downloading execution-spec-tests fixtures")
360-
threads = flag.Int("p", 1, "Number of CPU threads to use for testing")
351+
dlgo = flag.Bool("dlgo", false, "Download Go and build with it")
352+
arch = flag.String("arch", "", "Run tests for given architecture")
353+
cc = flag.String("cc", "", "Sets C compiler binary")
354+
coverage = flag.Bool("coverage", false, "Whether to record code coverage")
355+
verbose = flag.Bool("v", false, "Whether to log verbosely")
356+
race = flag.Bool("race", false, "Execute the race detector")
357+
short = flag.Bool("short", false, "Pass the 'short'-flag to go test")
358+
cachedir = flag.String("cachedir", "./build/cache", "directory for caching downloads")
359+
threads = flag.Int("p", 1, "Number of CPU threads to use for testing")
361360
)
362361
flag.CommandLine.Parse(cmdline)
363362

364363
// Load checksums file (needed for both spec tests and dlgo)
365364
csdb := download.MustLoadChecksums("build/checksums.txt")
366365

367366
// Get test fixtures.
368-
if !*skipspectests {
367+
if !*short {
369368
downloadSpecTestFixtures(csdb, *cachedir)
370369
}
371370

0 commit comments

Comments
 (0)