progrium / darwinkit

Native Mac APIs for Go. Previously known as MacDriver
MIT License
5.04k stars 160 forks source link

ignoring duplicate libraries warning #262

Open progrium opened 5 months ago

progrium commented 5 months ago

Although we fixed these warnings in the preview release, newer versions of Go cause this warning to show up when compiling DarwinKit programs:

# command-line-arguments
ld: warning: ignoring duplicate libraries: '-lobjc'

This is a known issue upstream in cgo. This issue will track it here. Although it's just a warning, you can suppress it by exporting this environment variable before building:

export CGO_LDFLAGS="-Wl,-no_warn_duplicate_libraries"