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

Won't compile on Mavericks 10.9.3 #9

Closed
vessenes opened this issue Jun 6, 2014 · 7 comments
Closed

Won't compile on Mavericks 10.9.3 #9

vessenes opened this issue Jun 6, 2014 · 7 comments

Comments

@vessenes
Copy link

vessenes commented Jun 6, 2014

I get lots of these with either 'go build' or 'sh test.sh'

Undefined symbols for architecture x86_64:
"_addControl", referenced from:
__cgo_4736bf25ed3f_Cfunc_addControl in sysdata_darwin.cgo2.o
(maybe you meant: __cgo_4736bf25ed3f_Cfunc_addControl)
"_applyStandardControlFont", referenced from:
__cgo_4736bf25ed3f_Cfunc_applyStandardControlFont in sysdata_darwin.cgo2.o
(maybe you meant: __cgo_4736bf25ed3f_Cfunc_applyStandardControlFont)

@vessenes vessenes changed the title WOn't compile on Mavericks 10.9.3 Won't compile on Mavericks 10.9.3 Jun 6, 2014
@cryptix
Copy link

cryptix commented Jun 6, 2014

What go version are you trying? I just build
go version devel +c8e9255aed3f Thu Jun 05 16:40:23 2014 -0400 darwin/amd64

and all i get is this during go get github.com/andlabs/ui

# github.com/andlabs/ui
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xb code=0x1 addr=0x0 pc=0x1a2fd]

goroutine 16 [running]:
runtime.panic(0x268ce0, 0x40afc4)
    /Users/cryptix/gotip/src/pkg/runtime/panic.c:279 +0xf5
main.(*typeConv).Type(0xc2080502c0, 0x4bf6d8, 0xc20810c5d0, 0x1e3a, 0x1)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1288 +0x1f2d
main.(*typeConv).Type(0xc2080502c0, 0x4bf630, 0xc20810c570, 0x1e3a, 0xc208190101)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1189 +0x5a8e
main.(*typeConv).Type(0xc2080502c0, 0x4bf840, 0xc208103f40, 0x1e3a, 0x0)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1075 +0x5268
main.(*typeConv).Struct(0xc2080502c0, 0xc2081724e0, 0x1e3a, 0x6, 0x0, 0x0, 0x8)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1551 +0x8e9
main.(*typeConv).Type(0xc2080502c0, 0x4bf770, 0xc2081724e0, 0x1e3a, 0xc208190201)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1234 +0x4646
main.(*typeConv).Type(0xc2080502c0, 0x4bf630, 0xc20810c420, 0x1e3a, 0x0)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1189 +0x5a8e
main.(*typeConv).Struct(0xc2080502c0, 0xc208005e00, 0x1e3a, 0x6, 0x0, 0x0, 0x8)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1551 +0x8e9
main.(*typeConv).Type(0xc2080502c0, 0x4bf770, 0xc208005e00, 0x1e3a, 0xe5101)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1234 +0x4646
main.(*typeConv).Type(0xc2080502c0, 0x4bf630, 0xc208092c30, 0x1e3a, 0xc2080fb070)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1189 +0x5a8e
main.(*typeConv).Type(0xc2080502c0, 0x4bf6d8, 0xc208092a20, 0x1e3a, 0x32c200)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1269 +0x194e
main.(*typeConv).Struct(0xc2080502c0, 0xc208005ce0, 0x1e3a, 0x6, 0x0, 0x0, 0x0)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1551 +0x8e9
main.(*typeConv).Type(0xc2080502c0, 0x4bf770, 0xc208005ce0, 0x1e3a, 0x32c201)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1234 +0x4646
main.(*typeConv).Type(0xc2080502c0, 0x4bf630, 0xc2080926f0, 0x1e3a, 0xc2080fb060)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1189 +0x5a8e
main.(*typeConv).Type(0xc2080502c0, 0x4bf6d8, 0xc2080925d0, 0x1e3a, 0x4aa000)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1269 +0x194e
main.(*typeConv).FuncArg(0xc2080502c0, 0x4bf6d8, 0xc2080925d0, 0x1e3a, 0x1)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1405 +0x6a
main.(*typeConv).FuncType(0xc2080502c0, 0xc2081033c0, 0x1e3a, 0xc2081033c0)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:1458 +0x7b2
main.(*Package).loadDWARF(0xc208001e10, 0xc20804c080, 0xc20800ef00, 0x19, 0x20)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:539 +0x19cf
main.(*Package).Translate(0xc208001e10, 0xc20804c080)
    /Users/cryptix/gotip/src/cmd/cgo/gcc.go:182 +0x1f0
main.main()
    /Users/cryptix/gotip/src/cmd/cgo/main.go:259 +0x1393

goroutine 19 [finalizer wait]:
runtime.park(0x60890, 0x410500, 0x40e849)
    /Users/cryptix/gotip/src/pkg/runtime/proc.c:1369 +0x89
runtime.parkunlock(0x410500, 0x40e849)
    /Users/cryptix/gotip/src/pkg/runtime/proc.c:1385 +0x3b
runfinq()
    /Users/cryptix/gotip/src/pkg/runtime/mgc0.c:2644 +0xcf
runtime.goexit()
    /Users/cryptix/gotip/src/pkg/runtime/proc.c:1445

@vessenes
Copy link
Author

vessenes commented Jun 6, 2014

go version go1.2 darwin/amd64

@andlabs
Copy link
Owner

andlabs commented Jun 6, 2014

Right, package ui won't work with Go 1.2 because Go 1.3 is the one that added Objective-C support. I'll make that clear when updating the README.

@cryptix's panic is coming from cgo itself; I'll need to update and investigate myself, but that'll likely be moved over to the Go issue tracker itself.

@andlabs andlabs closed this as completed Jun 6, 2014
@ghost
Copy link

ghost commented Jun 18, 2014

It doesn't work on OSX with Go 1.3r2, either; same error as @cryptix

1205)~ % go version
go version go1.3rc2 darwin/amd64
1205)~ % go get github.com/andlabs/ui
# github.com/andlabs/ui
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xb code=0x1 addr=0x0 pc=0x15672]

goroutine 16 [running]:
runtime.panic(0x1da9c0, 0x31a9e4)
        /Users/ser/Software/go/src/pkg/runtime/panic.c:279 +0xf5
...

@emilgpa
Copy link

emilgpa commented Jun 19, 2014

Same error here as @cryptix @serussell, with go 1.3 stable and OS X 10.9.3.

@andlabs
Copy link
Owner

andlabs commented Jun 19, 2014

Can reproduce on 10.8. Crash in cgo; will investigate now.

@andlabs
Copy link
Owner

andlabs commented Jun 19, 2014

Upon further investigation this is a cgo bug. From what I can tell, everything on the offending line is valid at the time of the crash, except for the full result of the typedef[...] expression, which is nil...

Go bug filed: https://code.google.com/p/go/issues/detail?id=8238

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants