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

meson: simplify version lookup and avoid deprecation warnings #1049

Merged
merged 1 commit into from Jan 29, 2022

Conversation

eli-schwartz
Copy link
Contributor

run_command() in development versions of meson will warn when the check: kwarg is not specified. At the same time, lz4 has some gnarly code to manually check the return code and raise an error if it failed.

Kill two birds with one stone, by making run_command inherently raise a fatal error when erroring out, then proceeding in the knowledge that it must have succeeded.

run_command() in development versions of meson will warn when the
`check: ` kwarg is not specified. At the same time, lz4 has some gnarly
code to manually check the return code and raise an error if it failed.

Kill two birds with one stone, by making run_command inherently raise a
fatal error when erroring out, then proceeding in the knowledge that it
must have succeeded.
@eli-schwartz
Copy link
Contributor Author

Personally, I would recommend storing the version number in a buildsystem agnostic text file, e.g. VERSION. meson directly supports this (since 0.57) via

project('lz4', 'c', version: files('VERSION'))

@Cyan4973 Cyan4973 merged commit b2256c0 into lz4:dev Jan 29, 2022
@eli-schwartz eli-schwartz deleted the meson-warning-run_command branch January 30, 2022 05:01
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.

None yet

2 participants