yangbongsoo / blockStudy

1 stars 0 forks source link

이더리움 geth 설치 #11

Closed yangbongsoo closed 1 year ago

yangbongsoo commented 2 years ago
$ git clone -b release/1.9 https://github.com/ethereum/go-ethereum.git

에러 발생

env GO111MODULE=on go run build/ci.go install
env: go: No such file or directory
make: *** [all] Error 127

go 설치함

$ brew install go

에러 발생

 ~/Documents/study/graduate/1학기/ethereum/go-ethereum   release/1.9  make all
env GO111MODULE=on go run build/ci.go install
go: downloading github.com/cespare/cp v0.1.0
go: downloading github.com/Azure/azure-storage-blob-go v0.7.0
go: downloading golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9
go: downloading github.com/Azure/azure-pipeline-go v0.2.2
go: downloading github.com/mattn/go-ieproxy v0.0.0-20190702010315-6dee0af9227d
...
util.go:47: exit status 2
exit status 1
make: *** [all] Error 1

go-ethereum build 가이드 보면 C compiler 도 설치하라고 함

Building geth requires both a Go (version 1.16 or later) and a C compiler.

$ brew install glib

그래도 안됌

/Users/user/go/pkg/mod/golang.org/x/sys@v0.0.0-20200824131525-c12d262b63d8/unix/zsyscall_darwin_arm64.go:121:3: too many errors
util.go:47: exit status 2
exit status 1
make: *** [all] Error 1

구글링해서 https://www.sakishum.com/2022/04/07/golang-1-18-%E6%8A%A5%E9%94%99-linkname-must-refer-to-declared-function-or-variable/#/%E9%97%AE%E9%A2%98 따라해봄

$ go get -u golang.org/x/sys

에러 발생안함. 빌드완료

 ~/Documents/study/graduate/1학기/ethereum/go-ethereum   release/1.9 ±  ./build/bin/geth version
Geth
Version: 1.9.25-stable
Git Commit: e7872729012a4871397307b12cc3f4772ffcbec6
Git Commit Date: 20201211
Architecture: arm64
Protocol Versions: [65 64 63]
Go Version: go1.19.1
Operating System: darwin
GOPATH=
GOROOT=

TODO: GOPATH, GOROOT 추가하기 TODO: geth path 추가하기

cf) 최후보루 brew 이용해서 설치

$ brew tap ethereum/ethereum
$ brew install ethereum

https://geth.ethereum.org/docs/install-and-build/installing-geth

yangbongsoo commented 2 years ago

아래 그림에서 Ethereum 클라이언트쪽 작업중이라 보면됌

스크린샷 2022-09-21 오전 1 16 52
yangbongsoo commented 2 years ago

install ubuntu on utm mac m1

https://antdev.tistory.com/84 https://mac.getutm.app/gallery/ubuntu-20-04

yangbongsoo commented 2 years ago

초기화 완료 후 geth 실행까지 해봄.

스크린샷 2022-09-24 오전 12 31 29