Add build.go that specifies GLFW build options and linker options.
$ brew install go $ brew tap homebrew/versions $ brew install --build-bottle --static glfw3 $ go get github.com/go-gl/glfw3
package main import ( "runtime" glfw "github.com/go-gl/glfw3" ) func init() { runtime.LockOSThread() } func main() { err := glfw.Init() if err != nil { panic(err) } defer glfw.Terminate() window, err := glfw.CreateWindow(640, 480, "Testing", nil, nil) if err != nil { panic(err) } window.MakeContextCurrent() for !window.ShouldClose() { // Do OpenGL stuff window.SwapBuffers() glfw.PollEvents() } }