Build SAM#
Prerequisites#
SAM relies on the MOOSE framework. We build MOOSE by following the instructions on the MOOSE website first.
Install Mambaforge3#
For Linux users:
| |
After installing, put Mambaforge’s path to system environment PATH:
| |
so that the system recognizes the mamba command.
Then initialize mambaforge by
| |
This command will append several mamba initialization to your ~/.bashrc file. Since I use zsh, I moved those lines from ~/.bashrc to ~/.zshrc.
Then restart the terminal.
Install MOOSE#
Add the INL public channel to Conda:
1conda config --add channels https://conda.software.inl.gov/publicCreate moose environment in Conda
1mamba create -n moose moose-devActivate the environment
1mamba activate moose
Clone SAM and Build#
Clone SAM from ANL’s GitLab#
Get an access token to the GitLab repository.
GitLab -> Settings -> Access Tokens
Clone the SAM repository to your computer or cluster
1 2 3mkdir ~/Documents cd ~/Documents git clone https://git-nse.egs.anl.gov/*YourUserName_or_SAM*/SAM.gitIt will ask you for the GitLab username and password. Use the access token you generated for the password.
Build libmesh#
Get moose submodule
1 2 3cd SAM git submodule init git submodule update --recursive
Build SAM#
Build SAM
1 2cd ~/Documents/SAM make -j4Run the tests
1./run_tests -j4If SAM was built correctly, all the tests will pass.
