File tree Expand file tree Collapse file tree 2 files changed +93
-3
lines changed Expand file tree Collapse file tree 2 files changed +93
-3
lines changed Original file line number Diff line number Diff line change 1+ name : Go CI
2+
3+ on :
4+ push :
5+ pull_request :
6+
7+ jobs :
8+ ubuntu :
9+ name : Build and Test on Ubuntu
10+ runs-on : ubuntu-latest
11+
12+ steps :
13+ - uses : actions/checkout@v4
14+
15+ - name : Set up Go
16+ uses : actions/setup-go@v5
17+ with :
18+ go-version : ' 1.23.3'
19+
20+ - name : Install Boost library
21+ run : |
22+ sudo apt-get update
23+ sudo apt-get install -y libboost-all-dev
24+
25+ - name : Build Kernel
26+ run : make build-kernel
27+
28+ - name : Build
29+ run : make build
30+
31+ - name : Run tests
32+ run : make test
33+
34+ macos :
35+ name : Build and Test on macOS
36+ runs-on : macos-latest
37+
38+ steps :
39+ - uses : actions/checkout@v4
40+
41+ - name : Set up Go
42+ uses : actions/setup-go@v5
43+ with :
44+ go-version : ' 1.23.3'
45+
46+ - name : Install Boost library
47+ run : |
48+ brew install boost
49+
50+ - name : Build Kernel
51+ run : make build-kernel
52+
53+ - name : Build
54+ run : make build
55+
56+ - name : Run tests
57+ run : make test
58+
59+ lint :
60+ name : Lint
61+ runs-on : ubuntu-latest
62+
63+ steps :
64+ - uses : actions/checkout@v4
65+
66+ - name : Set up Go
67+ uses : actions/setup-go@v5
68+ with :
69+ go-version : ' 1.23.3'
70+
71+ - name : Run linter
72+ uses : golangci/golangci-lint-action@v4
73+ with :
74+ version : latest
Original file line number Diff line number Diff line change 11# Makefile for go-bitcoinkernel
22
3- .PHONY : all build-kernel test clean help
3+ .PHONY : all build-kernel build test clean help
44
55all : build-kernel test
66
77build-kernel :
88 cd depend/bitcoin && \
9- cmake -B build -DBUILD_SHARED_LIBS=ON -DBUILD_KERNEL_LIB=ON -DBUILD_BENCH=OFF -DBUILD_CLI=OFF -DBUILD_DAEMON=OFF -DBUILD_FOR_FUZZING=OFF -DBUILD_FUZZ_BINARY=OFF -DBUILD_GUI=OFF -DBUILD_KERNEL_TEST=OFF -DBUILD_TESTS=OFF -DBUILD_TX=OFF -DBUILD_UTIL=OFF -DBUILD_UTIL_CHAINSTATE=OFF -DBUILD_WALLET_TOOL=OFF -DENABLE_WALLET=OFF && \
9+ cmake -B build \
10+ -DBUILD_SHARED_LIBS=ON \
11+ -DBUILD_KERNEL_LIB=ON \
12+ -DBUILD_TESTS=OFF \
13+ -DBUILD_TX=OFF \
14+ -DBUILD_WALLET_TOOL=OFF \
15+ -DENABLE_WALLET=OFF \
16+ -DENABLE_EXTERNAL_SIGNER=OFF \
17+ -DBUILD_UTIL=OFF \
18+ -DBUILD_BITCOIN_BIN=OFF \
19+ -DBUILD_DAEMON=OFF \
20+ -DBUILD_UTIL_CHAINSTATE=OFF \
21+ -DBUILD_CLI=OFF && \
1022 cmake --build build --target bitcoinkernel -j $(shell nproc 2>/dev/null || echo 4)
1123
12- test : build-kernel
24+ build :
25+ go build ./...
26+
27+ test :
1328 go test -v ./...
1429
1530clean :
2641 @echo " Available targets:"
2742 @echo " all - Build kernel library and run tests (default)"
2843 @echo " build-kernel - Build Bitcoin kernel library"
44+ @echo " build - Compile Go code"
2945 @echo " test - Run Go tests"
3046 @echo " clean - Clean build artifacts"
3147 @echo " lint - Lint Go code"
You can’t perform that action at this time.
0 commit comments