Skip to content

Fix CMake double precision builds #1785

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

dgcole
Copy link
Contributor

@dgcole dgcole commented May 31, 2025

Double precision builds with CMake are currently broken. Since I'm contributing the fix directly I did not bother to make an issue first, but please let me know if that is required.

The binding_generator_generate_bindings function has erroneous commas after some of its arguments (i.e., PRECISION,), but this is not correct CMake syntax; the arguments should be separated by whitespace. This causes the USE_TEMPLATE_GET_NODE, BITS, and PRECISION arguments to not be properly received when this function is invoked. This is partially masked for the BITS argument as there is a BITS variable at a higher CMake scope that is used.

The end result is that the PYTHON_SCRIPT always ends up getting populated with precision='' and use_template_get_node='', which makes it impossible to get a working double precision build via CMake.

@dgcole dgcole requested a review from a team as a code owner May 31, 2025 23:32
Copy link
Collaborator

@enetheru enetheru left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I approve these changes.

Copy link
Contributor

@paddy-exe paddy-exe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense in terms of how CMake works👍🏻 haven't tested the changes though

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.

3 participants