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

Build fails with Meson 0.60.0 #121

Closed
Tachi107 opened this issue Oct 24, 2021 · 4 comments
Closed

Build fails with Meson 0.60.0 #121

Tachi107 opened this issue Oct 24, 2021 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@Tachi107
Copy link
Contributor

Tachi107 commented Oct 24, 2021

Since this is related only to the build system, I'm skipping the issue template.

In the meson.build file, a message is printed describing the status of the build (host cpu, os, release, etc...). Those messages are printed by passing an array to message(), even if according to the documentation you can only pass it one or more strings.

In previous versions of Meson this did not cause any issue, as the array was flattened and booleans were converted to strings, but this does not seem true anymore; the following lines cause Meson to throw an error saying "Function accepts only strings, integers, lists, dictionaries and lists thereof.".

tomlplusplus/meson.build

Lines 49 to 52 in ca76e5d

message(['is_release', is_release])
message(['is_windows', is_windows])
message(['is_x64', is_x64])
message(['has_exceptions', has_exceptions])

Since the documentation does not mention the possibility of passing booleans to message() this could be considered an issue of tomlplusplus' meson.build file, but this started happening only with this latest release, and I'm going to report it upstream as well.

@Tachi107 Tachi107 added the bug Something isn't working label Oct 24, 2021
Tachi107 added a commit to Tachi107/cloudflare-ddns that referenced this issue Oct 24, 2021
@marzer
Copy link
Owner

marzer commented Oct 24, 2021

Ah thanks for letting me know.

I'm going to report it upstream as well.

Definitely a good move. Seems an odd design choice to accept compositions of strings and ints, but not booleans. I'd have to imagine that's an oversight.

@Tachi107
Copy link
Contributor Author

Will be fixed in mesonbuild/meson#9447 :)

@marzer marzer closed this as completed in 47216c8 Oct 25, 2021
@marzer
Copy link
Owner

marzer commented Oct 25, 2021

Awesome, thanks @Tachi107. I've pushed an interim fix to use string.format() instead of passing a list with booleans to message() so that should satisfy older versions of meson, too.

@Tachi107
Copy link
Contributor Author

Nice solution, thanks!

robbert-vdh added a commit to robbert-vdh/yabridge that referenced this issue Nov 12, 2021
This issue otherwise breaks compilation under Meson 0.60.0:

marzer/tomlplusplus#121
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants