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

fix _GNU_SOURCE redefined warning #356

Merged
merged 3 commits into from
Jun 22, 2022
Merged

fix _GNU_SOURCE redefined warning #356

merged 3 commits into from
Jun 22, 2022

Conversation

cornelk
Copy link
Contributor

@cornelk cornelk commented Jun 20, 2022

Closes #351

In upstream the _GNU_SOURCE and poll changes introduced this:

glfw/glfw@9f73e9a
glfw/glfw@adc202d

@Jacalz
Copy link
Collaborator

Jacalz commented Jun 21, 2022

You might want to contribute this change upstream. I'm not sure modifying the Glfw source in this way is the best option. It will be removed as soon as Glfw is updated again.

@cornelk
Copy link
Contributor Author

cornelk commented Jun 21, 2022

@Jacalz this has already been fixed in upstream (i guess for 3.4): glfw/glfw@bb9d699 - I am not sure what to do here

@Jacalz
Copy link
Collaborator

Jacalz commented Jun 21, 2022

I think it would be best to get a PR up to fix the issue for their next 3.3.x release. Otherwise it's just going to be undone work when we update to the next release in that series.

That would mean targeting the 3.3-stable branch: https://github.com/glfw/glfw/tree/3.3-stable.

@cornelk
Copy link
Contributor Author

cornelk commented Jun 21, 2022

@Jacalz I have a feeling that this will not get accepted ( glfw/glfw#2133 (comment) ) but I will submit it there

@dmitshur
Copy link
Member

dmitshur commented Jun 21, 2022

@cornelk I think what I wrote in #351 (comment) applies. If the problem can be reproduced with the GLFW C source code (independently of the Go bindings), then it's reasonable to target the fix there. The report in glfw/glfw#2133 refers to the Go bindings, which is suboptimal for that issue tracker. We should investigate that on our side in #351.

@cornelk
Copy link
Contributor Author

cornelk commented Jun 21, 2022

@Jacalz i believe i have found the proper fix now by changing the import order, i see no warning anymore (i am on Linux) using:

cd v3.3/glfw/
go clean -cache
go build ./...

@dmitshur thanks for the tip, i checked and could build glfw 3.3 stable without any warning.

@Jacalz
Copy link
Collaborator

Jacalz commented Jun 22, 2022

Cool. Nice work 👍

Copy link
Collaborator

@Jacalz Jacalz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work. Thanks for the fix.

@dmitshur dmitshur merged commit a6c407e into go-gl:master Jun 22, 2022
@dmitshur
Copy link
Member

Thanks.

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

Successfully merging this pull request may close these issues.

v3.3/glfw: _GNU_SOURCE is defined twice, emits a warning
3 participants