-
Notifications
You must be signed in to change notification settings - Fork 83
TST: add test demonstrating the ndebug issue #379
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
rgommers
left a comment
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.
Thanks for adding this test. Looks like we should settle the buildtype change discussion in gh-381, and then this will be mergeable.
| def test_ndebug(package_scipy_like, tmp_path, args): | ||
| with mesonpy._project({'setup-args': args}) as project: | ||
| command = subprocess.run( | ||
| ['ninja', '-C', os.fspath(project._build_dir), '-t', 'commands', '../../mypkg/extmod.c^'], |
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.
The ^ is a typo I think?
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.
The ^ asks ninja to report the build command for the target having the file preceding the ^ as part of its inputs. See the second paragraph here https://ninja-build.org/manual.html#_running_ninja
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.
Ah interesting, didn't know that.
|
I didn't meant this to be merged but only as a reproducer of the issue I saw. It would need some adjustment if we want to merge it. |
|
This can be closed now that gh-383 is merged I assume? |
|
The purpose of #383 is also to fix this, thus this can be closed. However, there isn't a test that makes sure the |
Good point. That's a fairly low-probability thing, so I'll close this and open a follow-up issue to add a test (after the next release). |
The meson-python
-Db_ndebug=if-releasedefault option does not have effect unless the project is also configured with-Dbuildtype=releaseordefault_options: ['buildtype=release']is specified inproject(). I believe this was not the desired effect.