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
In tree cross-build fails copying Include/graminit.h to itself #71416
Comments
While trying a cross compile of Python 3.6 I encountered the following alex@martha:~/src/cpython default☿ hg summary alex@martha: The attached patch allows me to get past this error. I'm unsure if it's an appropriate fix or just a workaround. |
The culprit appears to be the changes introduced for bpo-22359 (c36b9ef8ff39 and friends). |
Yes, those changes incorrectly assume that the source directory and the build directory are always different (using VPATH). Alex patch LGTM, this other patch overwrites the graminit.[ch] files, not sure if this is better. |
I was a little concerned that Alex’s patch used “test A -ef B”, which is not specified by Posix. But it is apparently widely supported (and consider we would only need it for cross compilation). Anyway, I was going to suggest test "$(srcdir)" == "." instead, but maybe Xavier’s solution is slightly better again. I say go with vpath.patch, perhaps with a brief comment explaining that the cp + mv dance avoids copying the file onto itself when doing an in-tree build. |
New changeset 619f7a2aa40a by Martin Panter in branch '3.5': New changeset 9902230b101f by Martin Panter in branch 'default': New changeset ffed402528c7 by Martin Panter in branch '2.7': |
New changeset ec214654708f by Martin Panter in branch '2.7': New changeset de5b85f96266 by Martin Panter in branch '3.5': New changeset b7a4c076ba40 by Martin Panter in branch 'default': |
Thanks Alex & Xavier. |
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: