go-gl / gl

Go bindings for OpenGL (generated via glow)
MIT License
1.07k stars 74 forks source link

Warnings in MacOS when go-getting and executing #101

Closed jmaeso closed 5 years ago

jmaeso commented 6 years ago

Hi, when getting the packages I get a bunch of warnings like this one:

ld: warning: text-based stub file /System/Library/Frameworks//OpenGL.framework/OpenGL.tbd and library file /System/Library/Frameworks//OpenGL.framework/OpenGL are out of sync. Falling back to library file for linking.

I guess this is something related just to macOS.

Btw: Not sure if related but executing this simple script returns me: OpenGL version: 4.1 INTEL-10.34.27 (should be 3.3 right?)

System: Macbook Pro (2016). MacOS High Sierra Version 10.13.5 Graphics card: Intel Iris Graphics 540 1536 MB

dmitshur commented 6 years ago

I can't reproduce this on my system:

~ $ export GOPATH=/tmp/empty
~ $ go get -u github.com/go-gl/gl/v3.3-core/gl
~ $ 

What version of Go are you using?

I'm on a Mid-2015 15" MBP, macOS 10.13.5, Go 1.11 Beta 1 but I'm guessing it would work with Go 1.10.3 as well.

Btw: Not sure if related but executing this simple script returns me: OpenGL version: 4.1 INTEL-10.34.27 (should be 3.3 right?)

4.1 is the right output. You're requesting a forward-compatible, core profile context. That means you'll get a context for the highest version of OpenGL greater than or equal to 3.3 that is supported by macOS and GPU. That is 4.1.

Reference: http://www.glfw.org/faq.html#how-do-i-create-an-opengl-30-context.

jmaeso commented 6 years ago

I'm using 1.10.3 Could be related to the opengl instalation? :S

PeterPetrik commented 5 years ago

could be related XCode update? (http://sd.jtimothyking.com/2018/07/26/stub-file-and-library-file-out-of-sync)

dmitshur commented 5 years ago

Yes, this appears to be related to that. Ever since Xcode 10 came out, it has been affecting the crypto/x509 package too, see https://github.com/golang/go/issues/26073.

Noofbiz commented 5 years ago

I'm getting this error as well, but I'm still able to use engo and ebiten rendering just fine. The warnings don't seem to have an effect on gl working for me.

pwaller commented 5 years ago

Looks like this was fixed over on golang/go#26073. Please ping the thread or file a new issue if not.