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
Allow python 2.7 to compile with Visual Studio 2013 #66157
Comments
VS2013 and beyond implement C99 math functions. Of interest to Python is the function round(). Python conditionally provides its own implementation of round() based on whether or not HAVE_ROUND is defined, but in no case is HAVE_ROUND ever defined. This leads to a huge spew of warnings when compiling with VS2013, and presumably it also leads to undefined behavior. The attached patch conditionally defines HAVE_ROUND based on _MSC_VER, and additionally provides a VS2013 port in the form of a set of native VS2013 solution and project files. This patch is based against tip of 2.7 release branch. The same fix may or may not still be needed in 3.x |
The fix is certainly needed in default, though I already have it in my fork for porting to VC14. I'm okay with the HAVE_ROUND change, but I think the VS2013 project files are better off kept separate. We won't be rebuilding 2.x with a newer compiler, so they don't belong in hg.python.org. |
Agreed. |
That's fine with me, the HAVE_ROUND is the important change anyway. Do I need to re-upload a new patch, or are you able to just delete the VS2013 project files portion of the patch and apply the HAVE_ROUND portion? And do I push the patch myself or does someone need to push it on my behalf? Thanks |
New changeset cb2e1b3a395f by Zachary Ware in branch '2.7': New changeset 1c35cefd25b7 by Zachary Ware in branch '3.4': New changeset 1f5e8380f791 by Zachary Ware in branch 'default': |
Thanks for the patch, I've committed it. For future reference, the devguide should answer any questions you may have about how to contribute to Python, or you can ask on any of the various mailing lists (where you'll either get an answer or be pointed to a list better suited to the question). In this particular case, I just removed the VS2013 build files myself, and only particular people (those with a Python logo next to their name on the tracker, like myself or Steve) are allowed to push to hg.python.org. Also, if you haven't already, please take a moment to sign a contributor agreement (https://www.python.org/psf/contrib/). In this case, the patch was fairly trivial and almost a direct copy from elsewhere in the source tree, so I went ahead and pushed it. For larger or more involved patches, the PSF will require a contributor agreement to be on file before your patch can be accepted. Thanks again for your contribution! |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: