Skip to content

use s.Rdev (type uint32) as type uint64--mips64el #28058

@vans88

Description

@vans88

Recently I am building kubernetes on mips64el platform and getting the following error. Through googling , I find the source from https://github.com/docker/docker/blob/master/pkg/system/stat_linux.go line 13. Any suggestions for me?

The error info:

test/e2e_node/e2e_node.test
k8s.io/kubernetes/vendor/github.com/google/cadvisor/fs
k8s.io/kubernetes/vendor/github.com/docker/docker/pkg/system
k8s.io/kubernetes/vendor/github.com/google/certificate-transparency/go/x509
# k8s.io/kubernetes/vendor/github.com/docker/docker/pkg/system
vendor/github.com/docker/docker/pkg/system/stat_linux.go:13: cannot use s.Rdev (type uint32) as type uint64 in field value
# k8s.io/kubernetes/vendor/github.com/google/cadvisor/fs
vendor/github.com/google/cadvisor/fs/fs.go:422: cannot use buf.Dev (type uint32) as type uint64 in argument to major
vendor/github.com/google/cadvisor/fs/fs.go:423: cannot use buf.Dev (type uint32) as type uint64 in argument to minor
# k8s.io/kubernetes/vendor/github.com/google/certificate-transparency/go/x509
vendor/github.com/google/certificate-transparency/go/x509/x509.go:342: undefined: elliptic.P224
vendor/github.com/google/certificate-transparency/go/x509/x509.go:355: undefined: elliptic.P224
vendor/github.com/google/certificate-transparency/go/x509/x509.go:1461: undefined: elliptic.P224
Makefile:79: recipe for target 'all' failed
make: *** [all] Error 1

**segment of the source file stat_linux.go:

// fromStatT converts a syscall.Stat_t type to a system.Stat_t type
func fromStatT(s *syscall.Stat_t) (*StatT, error) {
	return &StatT{size: s.Size,
		mode: s.Mode,
		uid:  s.Uid,
		gid:  s.Gid,
		rdev: s.Rdev,
		mtim: s.Mtim}, nil
}

my platform info

[root@dscn2 kubernetes]# uname -a
Linux dscn2 4.4.21+ #3 SMP PREEMPT Wed Oct 12 09:14:23 CST 2016 mips64 mips64 mips64 GNU/Linux
[root@dscn2 kubernetes]# go env
GOARCH="mips64le"
GOBIN=""
GOEXE=""
GOHOSTARCH="mips64le"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/root/mygo"
GORACE=""
GOROOT="/usr/lib/golang"
GOTOOLDIR="/usr/lib/golang/pkg/tool/linux_mips64le"
CC="gcc"
GOGCCFLAGS="-fPIC -mabi=64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build115989482=/tmp/go-build -gno-record-gcc-switches"
CXX="g++"
CGO_ENABLED="1"

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/enhancementEnhancements are not bugs or new features but can improve usability or performance.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions