Skip to content

Query optional build features through the C API - #4064

Merged
paulromano merged 3 commits into
openmc-dev:developfrom
paulromano:c-api-feature-enabled
Aug 15, 2026
Merged

Query optional build features through the C API#4064
paulromano merged 3 commits into
openmc-dev:developfrom
paulromano:c-api-feature-enabled

Conversation

@paulromano

@paulromano paulromano commented Aug 15, 2026

Copy link
Copy Markdown
Contributor

Description

Another PR moving us toward proper Windows support along the same lines as #4062 (avoiding need for OPENMC_API). This PR replaces the exported DAGMC, libMesh, strict floating-point, and UWUW boolean globals with a single openmc_get_feature_enabled C API function. The Python API exposes this as openmc.lib.feature_enabled, and all tests now query features directly at their point of use.

Checklist

  • I have performed a self-review of my own code
  • I have run clang-format (version 18) on any C++ source files (if applicable)
  • I have followed the style guidelines for Python source files (if applicable)
  • I have made corresponding changes to the documentation (if applicable)
  • I have added tests that prove my fix is effective or that my feature works (if applicable)

@paulromano
paulromano requested a review from pshriwise as a code owner August 15, 2026 17:51

@GuySten GuySten left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good to me.

@GuySten GuySten added the Merging Soon PR will be merged in < 24 hrs if no further comments are made. label Aug 15, 2026
@paulromano
paulromano merged commit f53364e into openmc-dev:develop Aug 15, 2026
18 checks passed
@paulromano
paulromano deleted the c-api-feature-enabled branch August 16, 2026 01:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Merging Soon PR will be merged in < 24 hrs if no further comments are made.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants