google/novm

Can't build on Ubuntu 20.04 x86_64 (with gollvm)

advancedwebdeveloper opened this issue · 2 comments

Hi.
Can't build your project:

$ make
make[1]: Entering directory '/home/oceanfish81/go_projects/novm'
make[1]: Leaving directory '/home/oceanfish81/go_projects/novm'
make[1]: Entering directory '/home/oceanfish81/go_projects/novm'

novmm/platform

kvm_run.c:133:1: warning: non-void function does not return a value [-Wreturn-type]

novmm/platform

src/novmm/platform/kvm_apic.go:186:4: error: integer constant overflow
src/novmm/platform/kvm_apic.go:246:4: error: integer constant overflow
src/novmm/platform/kvm_apic.go:264:3: error: integer constant overflow
src/novmm/platform/kvm_clock.go:46:3: error: integer constant overflow
src/novmm/platform/kvm_cpuid.go:54:4: error: integer constant overflow
src/novmm/platform/kvm_events.go:63:3: error: integer constant overflow
src/novmm/platform/kvm_fpu.go:54:3: error: integer constant overflow
src/novmm/platform/kvm_memory.go:84:3: error: integer constant overflow
src/novmm/platform/kvm_mpstate.go:74:3: error: integer constant overflow
src/novmm/platform/kvm_msrs.go:51:4: error: integer constant overflow
src/novmm/platform/kvm_msrs.go:95:3: error: integer constant overflow
src/novmm/platform/kvm_pit.go:79:3: error: integer constant overflow
src/novmm/platform/kvm_x86.go:57:4: error: integer constant overflow
src/novmm/platform/kvm_x86.go:95:4: error: integer constant overflow
src/novmm/platform/kvm_xcrs.go:46:3: error: integer constant overflow
src/novmm/platform/kvm_xsave.go:45:3: error: integer constant overflow
make[1]: *** [Makefile:55: go-test] Error 2
make[1]: Leaving directory '/home/oceanfish81/go_projects/novm'
make: *** [Makefile:77: dist] Error 2

$ go version
go version go1.15.2 gollvm LLVM 12.0.0git linux/amd64

$ go env
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/oceanfish81/.cache/go-build"
GOENV="/home/oceanfish81/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GOMODCACHE="/home/oceanfish81/go/pkg/mod"
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/home/oceanfish81/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/home/oceanfish81/gollvm_dist"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/home/oceanfish81/gollvm_dist/tools"
GCCGO="/home/oceanfish81/gollvm_dist/bin/llvm-goc"
AR="ar"
CC="/usr/bin/clang"
CXX="/usr/bin/clang++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build759872561=/tmp/go-build -gno-record-gcc-switches -funwind-tables"

I just cleaned up all Golang source and pre-compiled/pre-linked packages - and tried again.
My result is the same.

pipul commented

use go 1.2 to compile this project