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

Fixes #1825 Compiler warnings / errors from new logging feature on Window #1826

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

shikokuchuo
Copy link
Contributor

fixes #1825 <Compiler warnings / errors from new logging feature on Windows>

The first commit should be uncontroversial.

The second is good enough for me as I don't make use of logging. But a cleaner solution would be to have an alternative that works, or a CMake option that disables logging entirely.

Note that the above format should be used in your git commit comments.
You agree that by submitting a PR, you have read and agreed to our
contributing guidelines.

@gdamore
Copy link
Contributor

gdamore commented Apr 27, 2024

I need to think about this. I don't like that we continue to carry diffs for MinGW compilers specifically because they cannot be bothered to expose standard APIs. Supporting Windows alone is hard enough, but dealing with their down-rev compilers with a bunch of compiler workaround is obnoxious.

My preference is that for folks who need to build for Windows, they use a proper compiler supported for the operating system. MinGW fails in that regard, since it misses standard documented Win32 APIs. (This is just one case.)

(Notably also they have a pthreads implementation of clock_gettime(), but that requires linking against pthreads, which is bonkers on a Windows platform.)

If we do this, I'm of a mind to emit a large warning during CMake that you are using a non-standard configuration and will miss functionality, and that I don't want to hear complaints about it.

If I seem bitter about this, it's because it's not the first time I've been burned by MinGW deficiencies. People building for Windows should either use one of the commercial options (and notably VS is free for individual use via the community edition), or perhaps clang.

Of course, if the MinGW folks would be more willing to update their tools to not suck (so that access to all Windows standard APIs were available), I would probably feel a lot less hostile towards them.

I have almost zero sympathy for the "but Visual Studio is not open source!" argument, since the underlying platform is completely proprietary as well. If you want to develop exclusively using open source tools, you have no business working on Windows at all.

@gdamore
Copy link
Contributor

gdamore commented Apr 27, 2024

(Notably I also have approximately zero sympathy for commercial developers who won't spring for a compiler license and instead demand that I support their use of deficient free tools. As doing this comes at a cost to me, and to the project, such an attitude by commercial developers is simply selfish IMO. Perhaps they should instead demand that the producers of those other free tools fix them to not need workarounds, or maybe contribute back to those tools either code or money to fix them.)

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.

Compiler warnings / errors from new logging feature on Windows
2 participants