Skip to content

Commit 66b5303

Browse files
authored
Merge pull request #393 from arfc/openmc-guide
Add openmc guide
2 parents 549755f + ed9cc2c commit 66b5303

File tree

2 files changed

+39
-0
lines changed

2 files changed

+39
-0
lines changed

manual/guides/guides.md

+1
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ twitter accounts, and whatnot that tie us together.
9797
- [PyNE](/manual/guides/pyne)
9898
- [MOOSE](https://mooseframework.inl.gov/getting_started/installation/)
9999
- [Cyclus](https://fuelcycle.org/user/install.html)
100+
- [OpenMC](/manual/guides/openmc)
100101

101102
# Software
102103

manual/guides/openmc.md

+38
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
---
2+
layout: manual
3+
title: OpenMC
4+
subtitle: "OpenMC - Installing from source for development"
5+
permalink: /manual/guides/openmc
6+
---
7+
8+
# Recommendation 0. Read the Installation Guide
9+
OpenMC has an [excellent installation
10+
guide](https://docs.openmc.org/en/stable/usersguide/install.html#installing-from-source)
11+
that covers the dependencies. Several practices, discussed below, may
12+
make the whole process easier, cleaner, and more self-contained.
13+
14+
# Recommendation 1. Set up a Conda Environment
15+
When building OpenMC from source, using a conda environment to install
16+
dependencies allows different versions of various dependencies to co-exist on
17+
the same machine. It also eases installation of OpenMC's Python API.
18+
To create an environment with the name `openmc-env`, run:
19+
20+
```
21+
conda create -n openmc-env
22+
```
23+
24+
# Recommendation 2. Install Dependencies
25+
Install all the dependencies listed in the installation guide using conda in your new environment. For
26+
example, to install the Python dependencies, run:
27+
```
28+
conda install numpy scipy pandas pytest matplotlib lxml
29+
uncertainties
30+
```
31+
This _should_ install the required compilers and HDF5 libraries needed for
32+
OpenMC.
33+
> [!NOTE]
34+
> The recommendations for installing `h5py` in
35+
> [development mode](https://docs.openmc.org/en/stable/usersguide/install.html#installing-in-development-mode)
36+
> are in the installation guide. If you chose to do this, you should set
37+
> `HDF5_DIR=$CONDA_PREFIX` (for building `h5py`) and `HDF5_ROOT=$CONDA_PREFIX`(for
38+
> building OpenMC).

0 commit comments

Comments
 (0)