-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request pyne#1097 from CNERG/pymoab_cleanup
Update PyNE to use PyMOAB instead of PyTAPS with newest MOAB
- Loading branch information
Showing
43 changed files
with
3,594 additions
and
2,342 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,55 +1,206 @@ | ||
version: 2 | ||
jobs: | ||
build_py3: | ||
docker: | ||
- image: pyne/pyne_ubuntu_17.04:latest | ||
version: 2.1 | ||
# Executors: | ||
# Alias the environment on which run the different jobs | ||
# i.e. in this case, docker image in which the jobs will be ran | ||
executors: | ||
py2: | ||
docker: | ||
- image: pyne/ubuntu_18.04_py2_pyne-deps:latest | ||
py2_dagmc: | ||
docker: | ||
- image: pyne/ubuntu_18.04_py2_dagmc_pyne-deps:latest | ||
py2_pymoab: | ||
docker: | ||
- image: pyne/ubuntu_18.04_py2_pymoab_pyne-deps:latest | ||
py2_dagmc_pymoab: | ||
docker: | ||
- image: pyne/ubuntu_18.04_py2_dagmc_pymoab_pyne-deps:latest | ||
py3: | ||
docker: | ||
- image: pyne/ubuntu_18.04_py3_pyne-deps:latest | ||
|
||
working_directory: ~/repo | ||
|
||
# Commands: | ||
# Define macros that will be used to build and test PyNE. | ||
# Save_container/pull_container: | ||
# used to avoid repeting building PyNE for the testing jobs, | ||
# it will only pull the saved container state... | ||
# | ||
# checkout_build: | ||
# checkout the source code (usually the PR branch, and build | ||
# PyNE, save the state of the container after the build | ||
# | ||
# run_test: | ||
# load the PyNE build (built in checkout_build macro | ||
# run the nose test | ||
commands: | ||
# Save Container change | ||
save_container: | ||
description: "Save container state" | ||
parameters: | ||
build: | ||
type: string | ||
default: "build" | ||
steps: | ||
- checkout | ||
- run: echo $CIRCLE_SHA1 > .circle-sha | ||
- save_cache: | ||
key: v1-repo-<< parameters.build >>{{ checksum ".circle-sha" }} | ||
paths: | ||
- ~/ | ||
|
||
# Build! | ||
- run: | ||
name: Building PyNE | ||
command: | | ||
python3 setup.py install --user \ | ||
--moab $HOME/opt/moab --clean | ||
# Pull Container change | ||
pull_container: | ||
description: "Load container state" | ||
parameters: | ||
build: | ||
type: string | ||
default: "build" | ||
steps: | ||
- run: echo $CIRCLE_SHA1 > .circle-sha | ||
- restore_cache: | ||
keys: | ||
key: v1-repo-<< parameters.build >>{{ checksum ".circle-sha" }} | ||
|
||
# Test! | ||
- run: | ||
name: Running PyNE Tests | ||
command: | | ||
cd ~/repo/tests | ||
./travis-run-tests.sh python3 | ||
# Checkout and build PyNE | ||
checkout_build: | ||
description: "Checkout PyNE, build with the provided flags" | ||
parameters: | ||
flags: | ||
type: string | ||
default: "" | ||
build: | ||
type: string | ||
default: "build" | ||
steps: | ||
- checkout | ||
- run: python setup.py install --user --clean << parameters.flags >> | ||
- run: cd ../ && nuc_data_make ; | ||
- save_container: | ||
build: << parameters.build >> | ||
|
||
build_py2: | ||
docker: | ||
- image: pyne/pyne_ubuntu_16.04:latest | ||
# Run PyNE test | ||
run_test: | ||
description: "Run tests" | ||
parameters: | ||
flags: | ||
type: string | ||
default: "" | ||
build: | ||
type: string | ||
default: "build" | ||
steps: | ||
- pull_container: | ||
build: << parameters.build >> | ||
- run: | | ||
cd ~/repo/tests | ||
./travis-run-tests.sh << parameters.flags >> | ||
# Jobs part: | ||
# Define the different job that will be ran this separate building form | ||
# testing for each configuration allowing to get more information out of the CI | ||
jobs: | ||
# Python 3 jobs | ||
py3_build: | ||
executor: | ||
name: py3 | ||
working_directory: ~/repo | ||
|
||
steps: | ||
- checkout | ||
- checkout_build: | ||
flags: "" | ||
build: "python3" | ||
py3_test: | ||
executor: | ||
name: py3 | ||
working_directory: ~/repo | ||
steps: | ||
- run_test: | ||
flags: "python3" | ||
build: "python3" | ||
|
||
# Build! | ||
- run: | ||
name: Building PyNE | ||
command: | | ||
python setup.py install --user \ | ||
--moab $HOME/opt/moab --clean | ||
|
||
# Test! | ||
- run: | ||
name: Running PyNE Tests | ||
command: | | ||
cd ~/repo/tests | ||
./travis-run-tests.sh python2 | ||
# Python 2 jobs | ||
# without optional depedencies | ||
py2_build: | ||
executor: | ||
name: py2 | ||
working_directory: ~/repo | ||
steps: | ||
- checkout_build: | ||
flags: "" | ||
build: "python2" | ||
py2_test: | ||
executor: | ||
name: py2 | ||
working_directory: ~/repo | ||
steps: | ||
- run_test: | ||
flags: "python2" | ||
build: "python2" | ||
|
||
# With PyMOAB | ||
py2_pymoab_build: | ||
executor: | ||
name: py2_pymoab | ||
working_directory: ~/repo | ||
steps: | ||
- checkout_build: | ||
flags: "--moab $HOME/opt/moab" | ||
build: "python2_pymoab" | ||
py2_pymoab_test: | ||
executor: | ||
name: py2_pymoab | ||
working_directory: ~/repo | ||
steps: | ||
- run_test: | ||
flags: "python2" | ||
build: "python2_pymoab" | ||
|
||
# With PyMOAB & DAGMC | ||
py2_dagmc_pymoab_build: | ||
executor: | ||
name: py2_dagmc_pymoab | ||
working_directory: ~/repo | ||
steps: | ||
- checkout_build: | ||
flags: "--moab $HOME/opt/moab --dagmc $HOME/opt/dagmc" | ||
build: "python2_dagmc_pymoab" | ||
py2_dagmc_pymoab_test: | ||
executor: | ||
name: py2_dagmc_pymoab | ||
working_directory: ~/repo | ||
steps: | ||
- run_test: | ||
flags: "python2" | ||
build: "python2_dagmc_pymoab" | ||
|
||
# Workflow part: | ||
# This part defines the list of the jobs that will be ran and in which sequence. | ||
# The goal was to avoid running advanced configuration if PyNE does not work | ||
# with limited amount of dependencies. | ||
workflows: | ||
version: 2 | ||
build_and_test: | ||
jobs: | ||
- build_py2 | ||
- build_py3 | ||
- py3_build | ||
- py3_test: | ||
requires: | ||
- py3_build | ||
|
||
- py2_build | ||
- py2_test: | ||
requires: | ||
- py2_build | ||
|
||
- py2_pymoab_build: | ||
requires: | ||
- py2_build | ||
- py2_pymoab_test: | ||
requires: | ||
- py2_pymoab_build | ||
|
||
- py2_dagmc_pymoab_build: | ||
requires: | ||
- py2_pymoab_build | ||
- py2_dagmc_pymoab_test: | ||
requires: | ||
- py2_dagmc_pymoab_build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# - Try to find DAGMC | ||
# Once done this will define | ||
# | ||
# DAGMC_FOUND - system has DAGMC | ||
# DAGMC_INCLUDE_DIRS - the DAGMC include directory | ||
# DAGMC_LIBRARIES - Link these to use DAGMC | ||
# DAGMC_DEFINITIONS - Compiler switches required for using DAGMC | ||
# | ||
# Copyright (c) 2010 Roman Putanowicz <[email protected]> | ||
# | ||
# Redistribution and use is allowed according to the terms of the New | ||
# BSD license. | ||
# For details see the accompanying COPYING-CMAKE-SCRIPTS file. | ||
# | ||
|
||
|
||
message(STATUS ${DAGMC_ROOT}) | ||
|
||
find_path(DAGMC_CMAKE_CONFIG NAMES DAGMCConfig.cmake | ||
HINTS ${DAGMC_ROOT} | ||
PATH_SUFFIXES lib Lib cmake lib/cmake/ | ||
NO_DEFAULT_PATH) | ||
|
||
message(STATUS "Found DAGMC in ${DAGMC_CMAKE_CONFIG}") | ||
|
||
if( "DAGMC_CMAKE_CONFIG-NOTFOUND" STREQUAL "${DAGMC_CMAKE_CONFIG}") | ||
set(DAGMC_FOUND FALSE) | ||
else() | ||
include(${DAGMC_CMAKE_CONFIG}/DAGMCConfig.cmake) | ||
set(DAGMC_FOUND TRUE) | ||
endif() |
Oops, something went wrong.