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 NCrystal from Source for OpenMC #3304

Open
wants to merge 7 commits into
base: develop
Choose a base branch
from

Conversation

ahnaf-tahmid-chowdhury
Copy link
Contributor

Description

This PR modifies the OpenMC build process to compile NCrystal from source instead of relying on the manylinux-provided package. The motivation behind this change is to ensure a more streamlined integration, avoiding unnecessary dependencies and improving compatibility.

Motivation

  • Using the manylinux version results in a dependency on libNCrystal.so, which is dynamically loaded via subprocess, adding inefficiencies.

  • Setting LD_LIBRARY_PATH is an option, but it introduces complexity.

Reference

This PR follows up on discussions in another PR (shimwell/openmc/pull/67), where the issue of dependency management was raised. As suggested, this change is being made separately to integrate source-built NCrystal before addressing packaging concerns.

@shimwell
Copy link
Member

Many thanks for making this PR @ahnaf-tahmid-chowdhury

This would be very enabling for the sci kit core wheel building.

@tkittel perhaps has some comments on this

@tkittel
Copy link
Contributor

tkittel commented Feb 14, 2025

Yes, I have some comments. On vacation and busy with kids right now, but will try to find time a bit later :-)

@ahnaf-tahmid-chowdhury
Copy link
Contributor Author

It seems that ncrystal-python requires ncrystal-core to be installed; otherwise, it is broken. We need to install the full ncrystal package.

How would you like to proceed? We can either make ncrystal a runtime dependency, or create a fallback so users can install ncrystal when it's called but not installed, also add an optional dependency on pyproject.toml file.

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