From 2f8a2047664e2aec6312d8dc36902091bf326923 Mon Sep 17 00:00:00 2001 From: "Victor A. P. Magri" Date: Fri, 10 Nov 2023 12:46:27 -0500 Subject: [PATCH 1/7] Add script for downloading hypre from GitHub --- scripts/fetchHypre.sh | 51 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100755 scripts/fetchHypre.sh diff --git a/scripts/fetchHypre.sh b/scripts/fetchHypre.sh new file mode 100755 index 00000000..df534061 --- /dev/null +++ b/scripts/fetchHypre.sh @@ -0,0 +1,51 @@ +#!/bin/bash + +# Input argument: hypre branch +VERSION=${1:-"master"} + +# Local variables +BASE_DIR=$(pwd) +HYPRE_DIR=${BASE_DIR}/hypre-${VERSION} +HYPRE_SRC_DIR=${HYPRE_DIR}/src + +# Fetch hypre repository +cd ${BASE_DIR} +rm -rf ${HYPRE_DIR} +git clone https://github.com/hypre-space/hypre.git ${HYPRE_DIR} +git checkout ${VERSION} + +# Assign git variables +cd ${HYPRE_DIR} +HYPRE_DEVELOP_STRING=$(git -C ${HYPRE_SRC_DIR} describe --match 'v*' --long --abbrev=9) +HYPRE_DEVELOP_LASTAG=$(git -C ${HYPRE_SRC_DIR} describe --match 'v*' --abbrev=0) +HYPRE_DEVELOP_NUMBER=$(git -C ${HYPRE_SRC_DIR} rev-list --count $HYPRE_DEVELOP_LASTAG..HEAD) +HYPRE_DEVELOP_BRANCH=$(git -C ${HYPRE_SRC_DIR} rev-parse --abbrev-ref HEAD) + +# Replace placeholders in the "configure" file +sed -i "s/\$develop_string/$HYPRE_DEVELOP_STRING/g" ${HYPRE_SRC_DIR}/configure +sed -i "s/\$develop_lasttag/$HYPRE_DEVELOP_LASTAG/g" ${HYPRE_SRC_DIR}/configure +sed -i "s/\$develop_number/$HYPRE_DEVELOP_NUMBER/g" ${HYPRE_SRC_DIR}/configure +sed -i "s/\$develop_branch/$HYPRE_DEVELOP_BRANCH/g" ${HYPRE_SRC_DIR}/configure +sed -i "s/\$HYPRE_SRCDIR\/..\/.git/\$HYPRE_SRCDIR/g" ${HYPRE_SRC_DIR}/configure + +# Remove git machinery from configure +sed -i '/^[[:space:]]*develop_lastag=\$/d' ${HYPRE_SRC_DIR}/configure +sed -i '/^[[:space:]]*develop_number=\$/d' ${HYPRE_SRC_DIR}/configure +sed -i '/^[[:space:]]*develop_branch=\$/d' ${HYPRE_SRC_DIR}/configure +sed -i '/^[[:space:]]*develop_string=\$/d' ${HYPRE_SRC_DIR}/configure + +# Remove hypre test data +rm -rf ${HYPRE_DIR}/AUTOTEST +rm -rf ${HYPRE_DIR}/src/test/TEST_* + +# Remove git folder +rm -rf ${HYPRE_DIR}/.git + +# Create tarball +HYPRE_DIR=${BASE_DIR}/hypre-${HYPRE_DEVELOP_STRING} +cd ${BASE_DIR} +mv hypre-${VERSION} ${HYPRE_DIR} +tar czvf hypre-${HYPRE_DEVELOP_STRING}.tar.gz hypre-${HYPRE_DEVELOP_STRING} + +# Remove temporary directory +rm -rf ${HYPRE_DIR} From c2d752cd4b75c3133bfbf16fb43b483101900e52 Mon Sep 17 00:00:00 2001 From: "Victor A. P. Magri" Date: Fri, 10 Nov 2023 12:46:58 -0500 Subject: [PATCH 2/7] Remove old hypre tarball --- tplMirror/hypre-2.29.0.tar.gz | 3 --- 1 file changed, 3 deletions(-) delete mode 100644 tplMirror/hypre-2.29.0.tar.gz diff --git a/tplMirror/hypre-2.29.0.tar.gz b/tplMirror/hypre-2.29.0.tar.gz deleted file mode 100644 index d2359d72..00000000 --- a/tplMirror/hypre-2.29.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:98b72115407a0e24dbaac70eccae0da3465f8f999318b2c9241631133f42d511 -size 6832767 From d7bd40d7467af7bc3a023bfa0bfa6a6264e2ace2 Mon Sep 17 00:00:00 2001 From: "Victor A. P. Magri" Date: Fri, 10 Nov 2023 12:47:10 -0500 Subject: [PATCH 3/7] Add new hypre tarball --- CMakeLists.txt | 6 +++--- tplMirror/hypre-v2.30.0-3-gcf43b1653.tar.gz | 3 +++ 2 files changed, 6 insertions(+), 3 deletions(-) create mode 100644 tplMirror/hypre-v2.30.0-3-gcf43b1653.tar.gz diff --git a/CMakeLists.txt b/CMakeLists.txt index 3081cf19..760b26f7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -58,7 +58,7 @@ option( ENABLE_NINJA "" OFF ) include(ProcessorCount) ProcessorCount(NUM_CORES) - + set(NUM_PROC ${NUM_CORES} CACHE STRING "") message( "Running with NUM_PROC = ${NUM_PROC}") @@ -741,7 +741,7 @@ endif() if( ENABLE_HYPRE ) set( HYPRE_DIR "${CMAKE_INSTALL_PREFIX}/hypre" ) - set( HYPRE_URL "${TPL_MIRROR_DIR}/hypre-2.29.0.tar.gz") + set( HYPRE_URL "${TPL_MIRROR_DIR}/hypre-v2.30.0-3-gcf43b1653.tar.gz") set( HYPRE_DEPENDS "" ) @@ -1111,7 +1111,7 @@ endif( ENABLE_MPI ) CMAKE_ARGS -D CMAKE_C_COMPILER=${VTK_C_COMPILER} -D CMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE} -D CMAKE_CXX_COMPILER=${VTK_CXX_COMPILER} - -D CMAKE_CXX_FLAGS:STRING=${CMAKE_CXX_FLAGS} + -D CMAKE_CXX_FLAGS:STRING=${CMAKE_CXX_FLAGS} -D VTK_USE_MPI=${VTK_USE_MPI} -D VTK_MODULE_ENABLE_VTK_IOParallelXML=${VTK_MODULE_ENABLE_VTK_IOParallelXML} -D VTK_MODULE_ENABLE_VTK_FiltersParallelDIY2=${VTK_MODULE_ENABLE_VTK_FiltersParallelDIY2} diff --git a/tplMirror/hypre-v2.30.0-3-gcf43b1653.tar.gz b/tplMirror/hypre-v2.30.0-3-gcf43b1653.tar.gz new file mode 100644 index 00000000..cdd20eb5 --- /dev/null +++ b/tplMirror/hypre-v2.30.0-3-gcf43b1653.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5b66bc279d6d7aafaafd1d9a3b06e32c7ee908986085869cb14d52ac96e372a7 +size 4358310 From e95e2006e717752d38c71de40917e4f9197cf279 Mon Sep 17 00:00:00 2001 From: "Victor A. P. Magri" Date: Tue, 28 Nov 2023 11:47:13 -0500 Subject: [PATCH 4/7] Fix build warnings with SuperLU_Dist --- scripts/fetchHypre.sh | 2 +- tplMirror/hypre-v2.30.0-3-gcf43b1653.tar.gz | 3 --- tplMirror/hypre-v2.30.0-8-g61fa167d7.tar.gz | 3 +++ 3 files changed, 4 insertions(+), 4 deletions(-) delete mode 100644 tplMirror/hypre-v2.30.0-3-gcf43b1653.tar.gz create mode 100644 tplMirror/hypre-v2.30.0-8-g61fa167d7.tar.gz diff --git a/scripts/fetchHypre.sh b/scripts/fetchHypre.sh index df534061..fc26cc86 100755 --- a/scripts/fetchHypre.sh +++ b/scripts/fetchHypre.sh @@ -12,10 +12,10 @@ HYPRE_SRC_DIR=${HYPRE_DIR}/src cd ${BASE_DIR} rm -rf ${HYPRE_DIR} git clone https://github.com/hypre-space/hypre.git ${HYPRE_DIR} -git checkout ${VERSION} # Assign git variables cd ${HYPRE_DIR} +git checkout ${VERSION} HYPRE_DEVELOP_STRING=$(git -C ${HYPRE_SRC_DIR} describe --match 'v*' --long --abbrev=9) HYPRE_DEVELOP_LASTAG=$(git -C ${HYPRE_SRC_DIR} describe --match 'v*' --abbrev=0) HYPRE_DEVELOP_NUMBER=$(git -C ${HYPRE_SRC_DIR} rev-list --count $HYPRE_DEVELOP_LASTAG..HEAD) diff --git a/tplMirror/hypre-v2.30.0-3-gcf43b1653.tar.gz b/tplMirror/hypre-v2.30.0-3-gcf43b1653.tar.gz deleted file mode 100644 index cdd20eb5..00000000 --- a/tplMirror/hypre-v2.30.0-3-gcf43b1653.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:5b66bc279d6d7aafaafd1d9a3b06e32c7ee908986085869cb14d52ac96e372a7 -size 4358310 diff --git a/tplMirror/hypre-v2.30.0-8-g61fa167d7.tar.gz b/tplMirror/hypre-v2.30.0-8-g61fa167d7.tar.gz new file mode 100644 index 00000000..2c9bada8 --- /dev/null +++ b/tplMirror/hypre-v2.30.0-8-g61fa167d7.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b24b9e68e43670e92b3e461d7787899d57335fe905a9f40e14b4b3b5f65241e +size 4360421 From 970f0f625e9c112c34129026ec06ade677254978 Mon Sep 17 00:00:00 2001 From: "Victor A. P. Magri" Date: Tue, 28 Nov 2023 13:44:40 -0500 Subject: [PATCH 5/7] Change script name --- scripts/{fetchHypre.sh => updateHypre.sh} | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) rename scripts/{fetchHypre.sh => updateHypre.sh} (75%) diff --git a/scripts/fetchHypre.sh b/scripts/updateHypre.sh similarity index 75% rename from scripts/fetchHypre.sh rename to scripts/updateHypre.sh index fc26cc86..b6935890 100755 --- a/scripts/fetchHypre.sh +++ b/scripts/updateHypre.sh @@ -4,12 +4,13 @@ VERSION=${1:-"master"} # Local variables -BASE_DIR=$(pwd) -HYPRE_DIR=${BASE_DIR}/hypre-${VERSION} +GEOSTPL_DIR=$(dirname $(dirname $(realpath $0))) +TPL_MIRROR_DIR=${GEOSTPL_DIR}/tplMirror +HYPRE_DIR=${GEOSTPL_DIR}/hypre-${VERSION} HYPRE_SRC_DIR=${HYPRE_DIR}/src # Fetch hypre repository -cd ${BASE_DIR} +cd ${GEOSTPL_DIR} rm -rf ${HYPRE_DIR} git clone https://github.com/hypre-space/hypre.git ${HYPRE_DIR} @@ -41,11 +42,16 @@ rm -rf ${HYPRE_DIR}/src/test/TEST_* # Remove git folder rm -rf ${HYPRE_DIR}/.git -# Create tarball -HYPRE_DIR=${BASE_DIR}/hypre-${HYPRE_DEVELOP_STRING} -cd ${BASE_DIR} +# Create tarball and move it to tplMirror +HYPRE_DIR=${GEOSTPL_DIR}/hypre-${HYPRE_DEVELOP_STRING} +cd ${GEOSTPL_DIR} mv hypre-${VERSION} ${HYPRE_DIR} tar czvf hypre-${HYPRE_DEVELOP_STRING}.tar.gz hypre-${HYPRE_DEVELOP_STRING} +mv hypre-${HYPRE_DEVELOP_STRING}.tar.gz ${TPL_MIRROR_DIR} # Remove temporary directory rm -rf ${HYPRE_DIR} + +# Update CMakeLists +echo -e "Updating CMakeLists..." +sed -i "s|set( HYPRE_URL \"\${TPL_MIRROR_DIR}/hypre-.*\.tar\.gz\" )|set( HYPRE_URL \"\${TPL_MIRROR_DIR}/hypre-${HYPRE_DEVELOP_STRING}.tar.gz\" )|" CMakeLists.txt From 8639752b7205d78e1c7b7da3ff2537e3d2981d3c Mon Sep 17 00:00:00 2001 From: "Victor A. P. Magri" Date: Tue, 28 Nov 2023 13:45:04 -0500 Subject: [PATCH 6/7] Update CMakeLists.txt --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 760b26f7..ef7178e5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -741,7 +741,7 @@ endif() if( ENABLE_HYPRE ) set( HYPRE_DIR "${CMAKE_INSTALL_PREFIX}/hypre" ) - set( HYPRE_URL "${TPL_MIRROR_DIR}/hypre-v2.30.0-3-gcf43b1653.tar.gz") + set( HYPRE_URL "${TPL_MIRROR_DIR}/hypre-v2.30.0-8-g61fa167d7.tar.gz" ) set( HYPRE_DEPENDS "" ) From d2f6191896c75d2db2c66c4883d08a37d37c90f4 Mon Sep 17 00:00:00 2001 From: "Randolph R. Settgast" Date: Fri, 1 Dec 2023 22:02:03 -0800 Subject: [PATCH 7/7] update LC bank in build scripts --- scripts/setupLC-TPL.bash | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/setupLC-TPL.bash b/scripts/setupLC-TPL.bash index 52c11973..fb060a58 100755 --- a/scripts/setupLC-TPL.bash +++ b/scripts/setupLC-TPL.bash @@ -27,8 +27,8 @@ rm -rf toBeDeleted & echo "Building all LC TPLs from $GEOSX_DIR to be installed at $INSTALL_DIR" chmod -R g+rx $INSTALL_DIR chgrp -R GEOS $INSTALL_DIR -./scripts/setupLC-TPL-helper.bash $GEOSX_DIR $INSTALL_DIR quartz clang-14 "srun -N 1 -t 90 -n 1 -A geosecp" $@ & -./scripts/setupLC-TPL-helper.bash $GEOSX_DIR $INSTALL_DIR quartz gcc-12 "srun -N 1 -t 90 -n 1 -A geosecp" $@ & +./scripts/setupLC-TPL-helper.bash $GEOSX_DIR $INSTALL_DIR quartz clang-14 "srun -N 1 -t 90 -n 1 -A cbronze" $@ & +./scripts/setupLC-TPL-helper.bash $GEOSX_DIR $INSTALL_DIR quartz gcc-12 "srun -N 1 -t 90 -n 1 -A cbronze" $@ & ./scripts/setupLC-TPL-helper.bash $GEOSX_DIR $INSTALL_DIR lassen gcc-8-cuda-11 "lalloc 1 -qpdebug" $@ & ./scripts/setupLC-TPL-helper.bash $GEOSX_DIR $INSTALL_DIR lassen clang-13-cuda-11 "lalloc 1 -qpdebug" $@ & ./scripts/setupLC-TPL-helper.bash $GEOSX_DIR $INSTALL_DIR lassen clang-10-cuda-11 "lalloc 1 -qpdebug" $@ &