go-notifier icon indicating copy to clipboard operation
go-notifier copied to clipboard

issue building: invalid flag in #cgo LDFLAGS: -sectcreate

Open tmc opened this issue 7 years ago • 2 comments

~/go/src/github.com/keybase/go-notifier(master) $ go build
go build github.com/keybase/go-notifier: invalid flag in #cgo LDFLAGS: -sectcreate
~/go/src/github.com/keybase/go-notifier(master) $ go version
go version go1.11.1 darwin/amd64

MacOS version: 10.13.6 (17G2307)

tmc avatar Oct 14 '18 17:10 tmc

I'm seeing this too.

↳ go install github.com/keybase/go-notifier/notifier
go build github.com/keybase/go-notifier: invalid flag in #cgo LDFLAGS: -sectcreate

↳ go version
go version go1.11.1 darwin/amd64

↳ system_profiler SPSoftwareDataType
Software:

    System Software Overview:

      System Version: macOS 10.14 (18A391)
      Kernel Version: Darwin 18.0.0
      <snip>

AaronOmanLendesk avatar Jan 02 '19 21:01 AaronOmanLendesk

Me too, please advise

go version go1.13.3 darwin/amd64
macOS 10.14.6

I tried the workaround here: https://forum.golangbridge.org/t/invalid-flag-in-cgo-ldflags/10020 but that results in a whole bunch of this:

# github.com/keybase/go-notifier
../../../../pkg/mod/github.com/keybase/[email protected]/corefoundation.go:25:9: cannot convert nil to type _Ctype_CFTypeRef
../../../../pkg/mod/github.com/keybase/[email protected]/corefoundation.go:34:3: cannot use nil as type _Ctype_CFDataRef in return argument
../../../../pkg/mod/github.com/keybase/[email protected]/corefoundation.go:40:26: cannot use nil as type _Ctype_CFAllocatorRef in argument to _Cfunc_CFDataCreate
../../../../pkg/mod/github.com/keybase/[email protected]/corefoundation.go:41:12: cannot convert nil to type _Ctype_CFDataRef
../../../../pkg/mod/github.com/keybase/[email protected]/corefoundation.go:42:3: cannot use nil as type _Ctype_CFDataRef in return argument
../../../../pkg/mod/github.com/keybase/[email protected]/corefoundation.go:66:47: cannot use nil as type _Ctype_CFAllocatorRef in assignment
../../../../pkg/mod/github.com/keybase/[email protected]/corefoundation.go:67:12: cannot convert nil to type _Ctype_CFDictionaryRef
../../../../pkg/mod/github.com/keybase/[email protected]/corefoundation.go:68:3: cannot use nil as type _Ctype_CFDictionaryRef in return argument
../../../../pkg/mod/github.com/keybase/[email protected]/corefoundation.go:79:88: cannot convert &(*_cgoIndex2)[0] (type *_Ctype_CFTypeRef) to type *unsafe.Pointer
../../../../pkg/mod/github.com/keybase/[email protected]/corefoundation.go:79:59: cannot convert &(*_cgoIndex1)[0] (type *_Ctype_CFTypeRef) to type *unsafe.Pointer
../../../../pkg/mod/github.com/keybase/[email protected]/corefoundation.go:79:88: too many errors

advdv avatar Feb 05 '20 10:02 advdv