-
-
Notifications
You must be signed in to change notification settings - Fork 185
Generate Cython code at build time #1877
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
Conversation
063497c
to
0fb0612
Compare
Generate Cython code at build time
again…me-ce into ignore-cython-cfile
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm generally approving of this as a stop gap before steadily turning cython files to C files.
Though the wasm CI is already doing that, this is probably a bad idea for testing against python git where cython files may need to be edited. This is what i do locally after 3.11 and 3.12(git) are built:
|
Maybe we can solve this problem by adding a 'non-cython' option. |
slightly longer term (but getting closer) the plan is to clear out all the cython code entirely. Is this PR useful enough to current cython development to get over the downsides? Or should we close it. I tend to avoid cython entirely. |
if not no_compilation: # Compile cython before compilation | ||
compile_cython() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are those lines not in the build command? Or are these files needed elsewhere too?
class CythonOnlyCommand(Command): | ||
|
||
user_options = [] | ||
def initialize_options(self):pass |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please add a description:
description = "short doc what this command does"
can be seen with: python setup.py --help-commands
there is also python setup.py cython_only --help
not sure what that would produce at the moment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, see #2360
add `Cython` to CIBW_BEFORE_BUILD
This PR has been superseded by #2831 because we recently introduced the new buildconfig, so I'm closing this But thanks for starting the work on this! |
cython
option from setup.py. (but keep thecython_only
)Reference:
pygame/pygame#2916
#1862