Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

runtime/cgo: mips64le undefined reference to `_cgo_sys_thread_start' #15168

Closed
vanloswang opened this issue Apr 7, 2016 · 3 comments
Closed

Comments

@vanloswang
Copy link

Please answer these questions before submitting your issue. Thanks!

  1. What version of Go are you using (go version)?
    go version go1.6 linux/mips64le

  2. What operating system and processor architecture are you using (go env)?
    GOARCH="mips64le"
    GOBIN=""
    GOEXE=""
    GOHOSTARCH="mips64le"
    GOHOSTOS="linux"
    GOOS="linux"
    GOPATH=""
    GORACE=""
    GOROOT="/usr/lib/golang"
    GOTOOLDIR="/usr/lib/golang/pkg/tool/linux_mips64le"
    GO15VENDOREXPERIMENT="1"
    CC="gcc"
    GOGCCFLAGS="-fPIC -fmessage-length=0"
    CXX="g++"
    CGO_ENABLED="0"

  3. What did you do?
    download http://dl.fedoraproject.org/pub/fedora/linux/updates/23/SRPMS/r/runc-0.0.8-0.1.git1a124e9.fc23.src.rpm and build it. The build process is exit by ld returned 1 exit status.
    The full error msg is as follow:
    gcc -I . -fPIC -pthread -fmessage-length=0 -o $WORK/runtime/cgo/_obj/cgo.o $WORK/runtime/cgo/_obj/_cgo_main.o $WORK/runtime/cgo/_obj/_cgo_export.o $WORK/runtime/cgo/_obj/cgo.cgo2.o $WORK/runtime/cgo/_obj/gcc_fatalf.o $WORK/runtime/cgo/_obj/gcc_libinit.o $WORK/runtime/cgo/_obj/gcc_setenv.o $WORK/runtime/cgo/_obj/gcc_util.o -g -O2 -lpthread

    runtime/cgo

    /tmp/go-build507880994/runtime/cgo/_obj/gcc_util.o: In function x_cgo_thread_start': /usr/lib/golang/src/runtime/cgo/gcc_util.c:42: undefined reference to_cgo_sys_thread_start'
    /usr/lib/golang/src/runtime/cgo/gcc_util.c:48: undefined reference to `_cgo_sys_thread_start'
    collect2: error: ld returned 1 exit status

  4. What did you expect to see?
    build pass and no such error report.

  5. What did you see instead?

@mwhudson
Copy link
Contributor

mwhudson commented Apr 7, 2016

I didn't think mips had cgo support at all, sort of surprised it got that far...

@vanloswang
Copy link
Author

I found some one got support for cgo externel link @ #14126

@bradfitz bradfitz added this to the Unplanned milestone Apr 7, 2016
@bradfitz bradfitz changed the title undefined reference to `_cgo_sys_thread_start' runtime/cgo: mips64le undefined reference to `_cgo_sys_thread_start' Apr 7, 2016
@minux
Copy link
Member

minux commented Apr 7, 2016 via email

@bradfitz bradfitz closed this as completed Apr 8, 2016
@golang golang locked and limited conversation to collaborators Apr 8, 2017
@rsc rsc unassigned minux Jun 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants