From 9bde0bf3c2f94e594c09a2c037e60969ea54fb47 Mon Sep 17 00:00:00 2001 From: Erik B Knudsen Date: Mon, 9 Sep 2024 10:19:27 +0200 Subject: [PATCH 1/9] add an arch test --- .github/workflows/build_from_source_containers.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/build_from_source_containers.yml b/.github/workflows/build_from_source_containers.yml index ae30a2d..6ed4326 100755 --- a/.github/workflows/build_from_source_containers.yml +++ b/.github/workflows/build_from_source_containers.yml @@ -22,6 +22,7 @@ jobs: - { os: Debian12, container: "debian:12", CC: gcc-12, CXX: g++-12, python: '3.12' } - { os: Debian12, container: "debian:12", CC: gcc-12, CXX: g++-12, python: '3.11' } - { os: Debian12, container: "debian:12", CC: gcc-12, CXX: g++-12, python: '3.10' } + - { os: Arch, container: "archlinux:latest", CC: gcc, CXX: g++, python: '3' } # - { os: macos-11, CC: clang, CXX: clang++, python: "3.10" } # - { os: macos-12, CC: clang, CXX: clang++, python: "3.11" } # - { os: macos-13, CC: clang, CXX: clang++, python: "3.11" } @@ -39,6 +40,10 @@ jobs: apt-get dist-upgrade apt-get install git build-essential sudo if: ${{ matrix.os == 'Debian11' || matrix.os == 'Debian12' }} + - name: bootstrap arch + run: | + pacman -Syu --noconfirm gcc python>${{ matrix.python }} cmake git + if: ${{ matrix.os == 'Arch' }} - name: checkout_main_repo uses: actions/checkout@v3 with: From c2262e187d0d99d72c5d67588bf6c1abe8e8fca9 Mon Sep 17 00:00:00 2001 From: Erik B Knudsen Date: Mon, 9 Sep 2024 10:22:29 +0200 Subject: [PATCH 2/9] also need sudo --- .github/workflows/build_from_source_containers.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_from_source_containers.yml b/.github/workflows/build_from_source_containers.yml index 6ed4326..18c1455 100755 --- a/.github/workflows/build_from_source_containers.yml +++ b/.github/workflows/build_from_source_containers.yml @@ -42,7 +42,7 @@ jobs: if: ${{ matrix.os == 'Debian11' || matrix.os == 'Debian12' }} - name: bootstrap arch run: | - pacman -Syu --noconfirm gcc python>${{ matrix.python }} cmake git + pacman -Syu --noconfirm gcc python>${{ matrix.python }} cmake git sudo if: ${{ matrix.os == 'Arch' }} - name: checkout_main_repo uses: actions/checkout@v3 From 0782cd66d74c3ba1ebcc42aa42edd37740c2bc24 Mon Sep 17 00:00:00 2001 From: Erik B Knudsen Date: Mon, 9 Sep 2024 10:27:28 +0200 Subject: [PATCH 3/9] use HOME as default build location --- Arch/dagmc-install.sh | 3 +-- Arch/double_down-install.sh | 6 ++---- Arch/moab-install.sh | 4 ++-- Arch/openmc-install.sh | 4 ++-- 4 files changed, 7 insertions(+), 10 deletions(-) diff --git a/Arch/dagmc-install.sh b/Arch/dagmc-install.sh index c2c1b9c..414ab1c 100755 --- a/Arch/dagmc-install.sh +++ b/Arch/dagmc-install.sh @@ -15,8 +15,7 @@ install_prefix="/usr/local/lib" if [ "x" != "x$LOCAL_INSTALL_PREFIX" ]; then install_prefix=$LOCAL_INSTALL_PREFIX fi - -build_prefix="/dev/null/openmc" #this will never exist - and so use the default later. +build_prefix="$HOME" if [ "x" != "x$OPENMC_BUILD_PREFIX" ]; then build_prefix=$OPENMC_BUILD_PREFIX fi diff --git a/Arch/double_down-install.sh b/Arch/double_down-install.sh index ee45b1e..9c2f889 100755 --- a/Arch/double_down-install.sh +++ b/Arch/double_down-install.sh @@ -16,13 +16,11 @@ WD=`pwd` name=`basename $0` package_name='double_down' -install_prefix="/opt" +install_prefix="/usr/local/lib" if [ "x" != "x$LOCAL_INSTALL_PREFIX" ]; then install_prefix=$LOCAL_INSTALL_PREFIX fi -build_prefix="$HOME/openmc" - -build_prefix="/dev/null/openmc" #this will never exist - and so use the default later. +build_prefix="$HOME" if [ "x" != "x$OPENMC_BUILD_PREFIX" ]; then build_prefix=$OPENMC_BUILD_PREFIX fi diff --git a/Arch/moab-install.sh b/Arch/moab-install.sh index 50bb3ef..e8ff5e4 100755 --- a/Arch/moab-install.sh +++ b/Arch/moab-install.sh @@ -8,12 +8,12 @@ WD=`pwd` name=`basename $0` package_name='MOAB' -install_prefix="/opt" +install_prefix="/usr/local/lib" if [ "x" != "x$LOCAL_INSTALL_PREFIX" ]; then install_prefix=$LOCAL_INSTALL_PREFIX fi -build_prefix="/dev/null/openmc" #this will never exist - and so use the default later. +build_prefix="$HOME" if [ "x" != "x$OPENMC_BUILD_PREFIX" ]; then build_prefix=$OPENMC_BUILD_PREFIX fi diff --git a/Arch/openmc-install.sh b/Arch/openmc-install.sh index ed0143e..289affc 100755 --- a/Arch/openmc-install.sh +++ b/Arch/openmc-install.sh @@ -8,7 +8,7 @@ set -ex #./nuclear_data-install.sh #echo "Downloaded & extracted nuclear data, proceeding..." -openmc_version="v0.14.0" +openmc_version="v0.15.0" if [ "x" != "x$OPENMC_VERSION" ]; then openmc_version=$OPENMC_VERSION fi @@ -26,7 +26,7 @@ if [ "x" != "x$LOCAL_INSTALL_PREFIX" ]; then install_prefix=$LOCAL_INSTALL_PREFIX fi -build_prefix="/dev/null/openmc" #this will never exist - and so use the default later. +build_prefix="$HOME" if [ "x" != "x$OPENMC_BUILD_PREFIX" ]; then build_prefix=$OPENMC_BUILD_PREFIX fi From 791f0229a0a4ef1c3b6c73b7eea00ded3b9c84ea Mon Sep 17 00:00:00 2001 From: Erik B Knudsen Date: Mon, 9 Sep 2024 10:34:58 +0200 Subject: [PATCH 4/9] need make as well --- .github/workflows/build_from_source_containers.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_from_source_containers.yml b/.github/workflows/build_from_source_containers.yml index 18c1455..d69929c 100755 --- a/.github/workflows/build_from_source_containers.yml +++ b/.github/workflows/build_from_source_containers.yml @@ -42,7 +42,7 @@ jobs: if: ${{ matrix.os == 'Debian11' || matrix.os == 'Debian12' }} - name: bootstrap arch run: | - pacman -Syu --noconfirm gcc python>${{ matrix.python }} cmake git sudo + pacman -Syu --noconfirm gcc python>${{ matrix.python }} cmake git sudo make if: ${{ matrix.os == 'Arch' }} - name: checkout_main_repo uses: actions/checkout@v3 From 4c4324995e6044fbea82bbe7267103f5e87f00d2 Mon Sep 17 00:00:00 2001 From: Erik B Knudsen Date: Mon, 9 Sep 2024 10:39:04 +0200 Subject: [PATCH 5/9] more deps needed --- .github/workflows/build_from_source_containers.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_from_source_containers.yml b/.github/workflows/build_from_source_containers.yml index d69929c..dfeb7aa 100755 --- a/.github/workflows/build_from_source_containers.yml +++ b/.github/workflows/build_from_source_containers.yml @@ -42,7 +42,7 @@ jobs: if: ${{ matrix.os == 'Debian11' || matrix.os == 'Debian12' }} - name: bootstrap arch run: | - pacman -Syu --noconfirm gcc python>${{ matrix.python }} cmake git sudo make + pacman -Syu --noconfirm gcc python>${{ matrix.python }} cmake git sudo make python-numpy cython if: ${{ matrix.os == 'Arch' }} - name: checkout_main_repo uses: actions/checkout@v3 From 36b32135f3dc441e61574ffa5db91b7d2aae610d Mon Sep 17 00:00:00 2001 From: Erik B Knudsen Date: Mon, 9 Sep 2024 10:52:22 +0200 Subject: [PATCH 6/9] for debuggin fail fast --- .github/workflows/build_from_source_containers.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_from_source_containers.yml b/.github/workflows/build_from_source_containers.yml index dfeb7aa..4a5325e 100755 --- a/.github/workflows/build_from_source_containers.yml +++ b/.github/workflows/build_from_source_containers.yml @@ -11,7 +11,7 @@ on: jobs: run-build-stack: strategy: - fail-fast: false + fail-fast: true matrix: include: - { os: Debian11, container: "debian:11", CC: gcc-10, CXX: g++-10, python: '3.10' } From 10ebfdb3a0e1c4ff60a049f3f5be834e84c550d7 Mon Sep 17 00:00:00 2001 From: Erik B Knudsen Date: Mon, 9 Sep 2024 11:05:04 +0200 Subject: [PATCH 7/9] prefer CPU to Processor --- Arch/dagmc-install.sh | 2 +- Arch/double_down-install.sh | 2 +- Arch/moab-install.sh | 2 +- Arch/openmc-install.sh | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Arch/dagmc-install.sh b/Arch/dagmc-install.sh index 414ab1c..47bbbcb 100755 --- a/Arch/dagmc-install.sh +++ b/Arch/dagmc-install.sh @@ -33,7 +33,7 @@ if [ ! -e ${name}.done ]; then fi #Should we run make in parallel? Default is to use all available cores - ccores=`cat /proc/cpuinfo |grep CPU|wc -l` + ccores=`cat /proc/cpuinfo |grep Processor|wc -l` if [ "x$1" != "x" ]; then ccores=$1 fi diff --git a/Arch/double_down-install.sh b/Arch/double_down-install.sh index 9c2f889..9e79f8f 100755 --- a/Arch/double_down-install.sh +++ b/Arch/double_down-install.sh @@ -34,7 +34,7 @@ if [ ! -e ${name}.done ]; then sudo pacman -Sy --noconfirm embree doxygen #Should we run make in parallel? Default is to use all available cores - ccores=`cat /proc/cpuinfo |grep CPU|wc -l` + ccores=`cat /proc/cpuinfo |grep Processor|wc -l` if [ "x$1" != "x" ]; then ccores=$1 fi diff --git a/Arch/moab-install.sh b/Arch/moab-install.sh index e8ff5e4..dccbf34 100755 --- a/Arch/moab-install.sh +++ b/Arch/moab-install.sh @@ -33,7 +33,7 @@ if [ ! -e ${name}.done ]; then cython fi #Should we run make in parallel? Default is to use all available cores - ccores=`cat /proc/cpuinfo |grep CPU|wc -l` + ccores=`cat /proc/cpuinfo |grep Processor|wc -l` if [ "x$1" != "x" ]; then ccores=$1 fi diff --git a/Arch/openmc-install.sh b/Arch/openmc-install.sh index 289affc..d387af0 100755 --- a/Arch/openmc-install.sh +++ b/Arch/openmc-install.sh @@ -57,7 +57,7 @@ if [ ! -e ${name}.done ]; then fi fi #Should we run make in parallel? Default is to use all available cores - ccores=`cat /proc/cpuinfo |grep CPU|wc -l` + ccores=`cat /proc/cpuinfo |grep Processor|wc -l` if [ "x$1" != "x" ]; then ccores=$1 fi From 9269e73c06464fbd933603826fdd8c76a1c86770 Mon Sep 17 00:00:00 2001 From: Erik B Knudsen Date: Mon, 9 Sep 2024 11:09:13 +0200 Subject: [PATCH 8/9] also need pip --- .github/workflows/build_from_source_containers.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_from_source_containers.yml b/.github/workflows/build_from_source_containers.yml index 4a5325e..8bd5db3 100755 --- a/.github/workflows/build_from_source_containers.yml +++ b/.github/workflows/build_from_source_containers.yml @@ -42,7 +42,7 @@ jobs: if: ${{ matrix.os == 'Debian11' || matrix.os == 'Debian12' }} - name: bootstrap arch run: | - pacman -Syu --noconfirm gcc python>${{ matrix.python }} cmake git sudo make python-numpy cython + pacman -Syu --noconfirm gcc python>${{ matrix.python }} cmake git sudo make python-numpy python-pip cython if: ${{ matrix.os == 'Arch' }} - name: checkout_main_repo uses: actions/checkout@v3 From 6e446d049aac16032a0abba1887f370d92fc69a6 Mon Sep 17 00:00:00 2001 From: Erik B Knudsen Date: Mon, 9 Sep 2024 11:20:03 +0200 Subject: [PATCH 9/9] dagmc no longer needs to be patched --- Arch/dagmc-install.sh | 5 ----- 1 file changed, 5 deletions(-) diff --git a/Arch/dagmc-install.sh b/Arch/dagmc-install.sh index 47bbbcb..a47aac1 100755 --- a/Arch/dagmc-install.sh +++ b/Arch/dagmc-install.sh @@ -46,11 +46,6 @@ if [ ! -e ${name}.done ]; then cd DAGMC; git pull; cd .. fi - for patch in `ls ${WD}/../patches/dagmc_*.patch`; do - patch -p1 < $patch - done - - cd .. mkdir -p build cd build cmake ../DAGMC -DBUILD_TALLY=ON \