From a4e3ef6aea2b975ad1afe8578c120c0bf0dccf3a Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Thu, 8 Oct 2020 12:02:11 -0600 Subject: [PATCH 001/132] check for GNU v10.x Fortran and update FFLAGS --- buildscripts/libs/build_fms.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/buildscripts/libs/build_fms.sh b/buildscripts/libs/build_fms.sh index 2e31e62..5c8ab51 100755 --- a/buildscripts/libs/build_fms.sh +++ b/buildscripts/libs/build_fms.sh @@ -35,9 +35,11 @@ else fi export FC=$MPI_FC +[[ -n $FC && `$FC --version` =~ GNU\ Fortran.*\ 1[0-9]\.[0-9]+ ]] && FC_GFORTRAN_10=1 export CC=$MPI_CC export FFLAGS+=" -fPIC -w" +[[ -n $FC_GFORTRAN_10 ]] && export FFLAGS+=" -fallow-argument-mismatch" export CFLAGS+=" -fPIC -w" export FCFLAGS="$FFLAGS" From 1fe5127566989a71546a58ddd45583a8194d0535 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Mon, 12 Oct 2020 08:16:04 -0600 Subject: [PATCH 002/132] add gsl_lite, pybind, json schema validator --- buildscripts/config/config_container-gnu-openmpi-dev.sh | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index e01f17d..8db3af0 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -7,7 +7,6 @@ # Compiler/MPI combination export JEDI_COMPILER="gnu/7.3.0" export JEDI_MPI="openmpi/3.1.2" -#export JEDI_MPI="mpich/3.2.1" # This tells jedi-stack how you want to build the compiler and mpi modules # valid options include: @@ -57,7 +56,7 @@ export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y export STACK_BUILD_FCKIT=N export STACK_BUILD_ATLAS=N -export STACK_BUILD_ODC=Y +export STACK_BUILD_ODC=N # Optional Additions export STACK_BUILD_PIO=Y @@ -81,6 +80,6 @@ export STACK_BUILD_CGAL=N export STACK_BUILD_GEOS=N export STACK_BUILD_SQLITE=N export STACK_BUILD_PROJ=N -export STACK_BUILD_JSON=N +export STACK_BUILD_JSON=Y export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y export STACK_BUILD_FMS=N From 1151dc0c4637669314bab75da2a4f804bab9e68e Mon Sep 17 00:00:00 2001 From: mmiesch Date: Mon, 12 Oct 2020 10:58:02 -0600 Subject: [PATCH 003/132] add CGAL --- buildscripts/config/config_container-gnu-openmpi-dev.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index 8db3af0..cc841a5 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -76,7 +76,7 @@ export STACK_BUILD_ESMF=N export STACK_BUILD_BASELIBS=N export STACK_BUILD_PDTOOLKIT=N export STACK_BUILD_TAU2=N -export STACK_BUILD_CGAL=N +export STACK_BUILD_CGAL=Y export STACK_BUILD_GEOS=N export STACK_BUILD_SQLITE=N export STACK_BUILD_PROJ=N From 13709032e5906ea26fa2abc9bd867e70960feb15 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Mon, 12 Oct 2020 12:21:15 -0600 Subject: [PATCH 004/132] modules line causing build failure --- buildscripts/libs/build_netcdf.sh | 2 -- 1 file changed, 2 deletions(-) diff --git a/buildscripts/libs/build_netcdf.sh b/buildscripts/libs/build_netcdf.sh index 7d3ac12..990b579 100755 --- a/buildscripts/libs/build_netcdf.sh +++ b/buildscripts/libs/build_netcdf.sh @@ -120,8 +120,6 @@ echo "########################################################################## # Load netcdf-c before building netcdf-fortran $MODULES && module load netcdf -module list - set -x cd $curr_dir From 1fbbc530df678aeccb16e41c35c2082b6f43227c Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 13 Oct 2020 10:20:17 -0600 Subject: [PATCH 005/132] update stacks for clang and intel containers --- .../config/config_container-clang-mpich-dev.sh | 4 ++-- buildscripts/config/config_container-intel-impi-dev.sh | 10 +++++----- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/buildscripts/config/config_container-clang-mpich-dev.sh b/buildscripts/config/config_container-clang-mpich-dev.sh index 55fc60a..8113863 100644 --- a/buildscripts/config/config_container-clang-mpich-dev.sh +++ b/buildscripts/config/config_container-clang-mpich-dev.sh @@ -56,7 +56,7 @@ export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y export STACK_BUILD_FCKIT=N export STACK_BUILD_ATLAS=N -export STACK_BUILD_ODC=Y +export STACK_BUILD_ODC=N # Optional Additions export STACK_BUILD_PIO=Y @@ -80,6 +80,6 @@ export STACK_BUILD_CGAL=N export STACK_BUILD_GEOS=N export STACK_BUILD_SQLITE=N export STACK_BUILD_PROJ=N -export STACK_BUILD_JSON=N +export STACK_BUILD_JSON=Y export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y export STACK_BUILD_FMS=N diff --git a/buildscripts/config/config_container-intel-impi-dev.sh b/buildscripts/config/config_container-intel-impi-dev.sh index ae82df9..0a098e7 100644 --- a/buildscripts/config/config_container-intel-impi-dev.sh +++ b/buildscripts/config/config_container-intel-impi-dev.sh @@ -5,8 +5,8 @@ # Compiler/MPI combination -export JEDI_COMPILER="intel/19.0.5" -export JEDI_MPI="impi/19.0.5" +export JEDI_COMPILER="intel/19.1.0" +export JEDI_MPI="impi/19.1.0" source /opt/intel/compilers_and_libraries/linux/bin/compilervars.sh intel64 export PATH=/usr/local/bin:$PATH export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH @@ -18,7 +18,7 @@ export CPATH=/usr/local/include:$CPATH # native-module: load a pre-existing module (common for HPC systems) # native-pkg: use pre-installed executables located in /usr/bin or /usr/local/bin, # as installed by package managers like apt-get or hombrewo. -# This is a common option for, e.g., gcc/g++/gfortrant +# This is a common option for, e.g., gcc/g++/gfortran # from-source: This is to build from source export COMPILER_BUILD="native-pkg" export MPI_BUILD="native-pkg" @@ -61,7 +61,7 @@ export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y export STACK_BUILD_FCKIT=N export STACK_BUILD_ATLAS=N -export STACK_BUILD_ODC=Y +export STACK_BUILD_ODC=N # Optional Additions export STACK_BUILD_PIO=Y @@ -82,6 +82,6 @@ export STACK_BUILD_BASELIBS=N export STACK_BUILD_PDTOOLKIT=N export STACK_BUILD_TAU2=N export STACK_BUILD_CGAL=N -export STACK_BUILD_JSON=N +export STACK_BUILD_JSON=Y export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y export STACK_BUILD_FMS=N From 47caa1880b4bd6e09bfb3baf4d2bb38e9d44bc48 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 21 Oct 2020 10:55:10 -0600 Subject: [PATCH 006/132] add json schema validator by default --- buildscripts/config/choose_modules.sh | 49 ++++++++++++++------------- 1 file changed, 25 insertions(+), 24 deletions(-) diff --git a/buildscripts/config/choose_modules.sh b/buildscripts/config/choose_modules.sh index b1fabb7..7c18549 100644 --- a/buildscripts/config/choose_modules.sh +++ b/buildscripts/config/choose_modules.sh @@ -24,27 +24,28 @@ export STACK_BUILD_ATLAS=N export STACK_BUILD_GSL_LITE=Y # Optional Additions -export STACK_BUILD_ODC=N -export STACK_BUILD_PIO=Y -export STACK_BUILD_GPTL=N -export STACK_BUILD_NCO=N -export STACK_BUILD_PYJEDI=N -export STACK_BUILD_PYBIND11=N -export STACK_BUILD_NCEPLIBS=N -export STACK_BUILD_JPEG=N -export STACK_BUILD_PNG=N -export STACK_BUILD_JASPER=N -export STACK_BUILD_ARMADILLO=N -export STACK_BUILD_XERCES=N -export STACK_BUILD_TKDIFF=N -export STACK_BUILD_BOOST_FULL=N -export STACK_BUILD_ESMF=N -export STACK_BUILD_BASELIBS=N -export STACK_BUILD_PDTOOLKIT=N -export STACK_BUILD_TAU2=N -export STACK_BUILD_CGAL=N -export STACK_BUILD_GEOS=N -export STACK_BUILD_SQLITE=N -export STACK_BUILD_PROJ=N -export STACK_BUILD_FMS=N - +export STACK_BUILD_JSON=Y +export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y +export STACK_BUILD_ODC=N +export STACK_BUILD_PIO=Y +export STACK_BUILD_GPTL=N +export STACK_BUILD_NCO=N +export STACK_BUILD_PYJEDI=N +export STACK_BUILD_PYBIND11=N +export STACK_BUILD_NCEPLIBS=N +export STACK_BUILD_JPEG=N +export STACK_BUILD_PNG=N +export STACK_BUILD_JASPER=N +export STACK_BUILD_ARMADILLO=N +export STACK_BUILD_XERCES=N +export STACK_BUILD_TKDIFF=N +export STACK_BUILD_BOOST_FULL=N +export STACK_BUILD_ESMF=N +export STACK_BUILD_BASELIBS=N +export STACK_BUILD_PDTOOLKIT=N +export STACK_BUILD_TAU2=N +export STACK_BUILD_CGAL=N +export STACK_BUILD_GEOS=N +export STACK_BUILD_SQLITE=N +export STACK_BUILD_PROJ=N +export STACK_BUILD_FMS=N From a65885efd7ccc1a1af238520decace5a3b813a46 Mon Sep 17 00:00:00 2001 From: Rahul Mahajan Date: Mon, 2 Nov 2020 16:19:49 -0500 Subject: [PATCH 007/132] build nceplibs-bufr --- buildscripts/build_stack.sh | 3 +- buildscripts/libs/build_bufr.sh | 57 +++++++++++++++++++ .../compilerVersion/bufr/bufr.lua | 29 ++++++++++ 3 files changed, 88 insertions(+), 1 deletion(-) create mode 100755 buildscripts/libs/build_bufr.sh create mode 100644 modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 2d445cf..ed7dc8d 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -86,7 +86,8 @@ build_lib SZIP szip 2.1.1 build_lib LAPACK lapack 3.8.0 build_lib BOOST_HDRS boost 1.68.0 headers-only build_lib EIGEN3 eigen 3.3.7 -build_lib BUFRLIB bufrlib 11.3.2 +#build_lib BUFRLIB bufrlib 11.4.0 +build_lib BUFR bufr 11.4.0 build_lib ECBUILD ecbuild jcsda 3.3.2.jcsda3 build_lib CGAL cgal 5.0.2 build_lib GITLFS git-lfs 2.11.0 diff --git a/buildscripts/libs/build_bufr.sh b/buildscripts/libs/build_bufr.sh new file mode 100755 index 0000000..515f396 --- /dev/null +++ b/buildscripts/libs/build_bufr.sh @@ -0,0 +1,57 @@ +#!/bin/bash +# © Copyright 2020 UCAR +# © Copyright 2020 NOAA/NCEP/EMC +# This software is licensed under the terms of the Apache Licence Version 2.0 which can be obtained at +# http://www.apache.org/licenses/LICENSE-2.0. + +set -ex + +name="bufr" +version=$1 + +# Hyphenated version used for install prefix +compiler=$(echo $JEDI_COMPILER | sed 's/\//-/g') + +# manage package dependencies here +if $MODULES; then + set +x + source $MODULESHOME/init/bash + module load jedi-$JEDI_COMPILER + module try-load cmake + module list + set -x + + prefix="${PREFIX:-"/opt/modules"}/$compiler/$name/$version" + if [[ -d $prefix ]]; then + [[ $OVERWRITE =~ [yYtT] ]] && ( echo "WARNING: $prefix EXISTS: OVERWRITING!";$SUDO rm -rf $prefix ) \ + || ( echo "WARNING: $prefix EXISTS, SKIPPING"; exit 1 ) + fi + +else + prefix=${BUFR_ROOT:-"/usr/local"} +fi + +export FC=$SERIAL_FC +export CC=$SERIAL_CC + +software=NCEPLIBS-bufr + +# Release git tag name +tag=bufr_v$version + +cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} +[[ -d $software ]] || git clone https://github.com/noaa-emc/$software.git +[[ ${DOWNLOAD_ONLY} =~ [yYtT] ]] && exit 0 +[[ -d $software ]] && cd $software || ( echo "$software does not exist, ABORT!"; exit 1 ) +git fetch +git checkout --detach $tag +[[ -d build ]] && rm -rf build +mkdir -p build && cd build + +cmake -DCMAKE_INSTALL_PREFIX=$prefix .. +VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} +VERBOSE=$MAKE_VERBOSE $SUDO make install + +# generate modulefile from template +$MODULES && update_modules compiler $name $version \ + || echo $name $version >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log diff --git a/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua b/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua new file mode 100644 index 0000000..9f80bf2 --- /dev/null +++ b/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua @@ -0,0 +1,29 @@ +help([[ Module: NCEP bufrlib library for reading binary BUFR format files ]]) + +local pkgName = myModuleName() +local pkgVersion = myModuleVersion() +local pkgNameVer = myModuleFullName() + +local hierA = hierarchyA(pkgNameVer,1) +local compNameVer = hierA[1] +local compNameVerD = compNameVer:gsub("/","-") + +conflict("bufrlib") +conflict(pkgName) + +local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" + +local base = pathJoin(opt,compNameVerD,pkgName,pkgVersion) + +prepend_path("LD_LIBRARY_PATH", pathJoin(base,"lib")) +prepend_path("DYLD_LIBRARY_PATH", pathJoin(base,"lib")) +prepend_path("LIBRARY_PATH", pathJoin(base,"lib")) + +setenv("bufr_VERSION", pkgVersion) +setenv("bufr_ROOT", base) -- CMake find_package(bufr) +setenv("bufrlib_ROOT", base) -- py-ncepbufr variable + +whatis("Name: ".. pkgName) +whatis("Version: " .. pkgVersion) +whatis("Category: library") +whatis("Description: NCEP bufrlib library for reading binary BUFR format files") From 7eb02d58240a6d413ecd696e69ed1f54199b558c Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 3 Nov 2020 14:47:42 -0700 Subject: [PATCH 008/132] add BUFR to config files --- buildscripts/config/choose_modules.sh | 3 ++- buildscripts/config/config_container-clang-mpich-dev.sh | 3 ++- buildscripts/config/config_container-gnu-openmpi-dev.sh | 3 ++- buildscripts/config/config_container-intel-impi-app.sh | 1 + buildscripts/config/config_container-intel-impi-dev.sh | 3 ++- 5 files changed, 9 insertions(+), 4 deletions(-) diff --git a/buildscripts/config/choose_modules.sh b/buildscripts/config/choose_modules.sh index 34f6c5e..e03fe40 100644 --- a/buildscripts/config/choose_modules.sh +++ b/buildscripts/config/choose_modules.sh @@ -11,7 +11,8 @@ export STACK_BUILD_UDUNITS=Y export STACK_BUILD_ZLIB=Y export STACK_BUILD_LAPACK=N export STACK_BUILD_BOOST_HDRS=Y -export STACK_BUILD_BUFRLIB=Y +export STACK_BUILD_BUFRLIB=N +export STACK_BUILD_BUFR=Y export STACK_BUILD_EIGEN3=Y export STACK_BUILD_HDF5=Y export STACK_BUILD_PNETCDF=Y diff --git a/buildscripts/config/config_container-clang-mpich-dev.sh b/buildscripts/config/config_container-clang-mpich-dev.sh index 55fc60a..91a5036 100644 --- a/buildscripts/config/config_container-clang-mpich-dev.sh +++ b/buildscripts/config/config_container-clang-mpich-dev.sh @@ -46,7 +46,8 @@ export STACK_BUILD_ZLIB=Y export STACK_BUILD_LAPACK=Y export STACK_BUILD_BOOST_HDRS=Y export STACK_BUILD_EIGEN3=Y -export STACK_BUILD_BUFRLIB=Y +export STACK_BUILD_BUFRLIB=N +export STACK_BUILD_BUFR=Y export STACK_BUILD_HDF5=Y export STACK_BUILD_PNETCDF=Y export STACK_BUILD_NETCDF=Y diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index e01f17d..731c6e7 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -48,7 +48,8 @@ export STACK_BUILD_LAPACK=Y export STACK_BUILD_BOOST_HDRS=Y export STACK_BUILD_EIGEN3=Y export STACK_BUILD_HDF5=Y -export STACK_BUILD_BUFRLIB=Y +export STACK_BUILD_BUFRLIB=N +export STACK_BUILD_BUFR=Y export STACK_BUILD_PNETCDF=Y export STACK_BUILD_NETCDF=Y export STACK_BUILD_NCCMP=Y diff --git a/buildscripts/config/config_container-intel-impi-app.sh b/buildscripts/config/config_container-intel-impi-app.sh index 1663d01..a17b017 100644 --- a/buildscripts/config/config_container-intel-impi-app.sh +++ b/buildscripts/config/config_container-intel-impi-app.sh @@ -52,6 +52,7 @@ export STACK_BUILD_LAPACK=N export STACK_BUILD_BOOST_HDRS=Y export STACK_BUILD_EIGEN3=Y export STACK_BUILD_BUFRLIB=N +export STACK_BUILD_BUFR=N export STACK_BUILD_HDF5=Y export STACK_BUILD_PNETCDF=Y export STACK_BUILD_NETCDF=Y diff --git a/buildscripts/config/config_container-intel-impi-dev.sh b/buildscripts/config/config_container-intel-impi-dev.sh index ae82df9..48ee2fa 100644 --- a/buildscripts/config/config_container-intel-impi-dev.sh +++ b/buildscripts/config/config_container-intel-impi-dev.sh @@ -51,7 +51,8 @@ export STACK_BUILD_ZLIB=Y export STACK_BUILD_LAPACK=N export STACK_BUILD_BOOST_HDRS=Y export STACK_BUILD_EIGEN3=Y -export STACK_BUILD_BUFRLIB=Y +export STACK_BUILD_BUFRLIB=N +export STACK_BUILD_BUFR=Y export STACK_BUILD_HDF5=Y export STACK_BUILD_PNETCDF=Y export STACK_BUILD_NETCDF=Y From 038f0fd05cec859b903d1cfdb6206f6d79363e46 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 3 Nov 2020 16:00:47 -0700 Subject: [PATCH 009/132] remove module list Not sure where that came from but it caused problems with the container build --- buildscripts/libs/build_netcdf.sh | 2 -- 1 file changed, 2 deletions(-) diff --git a/buildscripts/libs/build_netcdf.sh b/buildscripts/libs/build_netcdf.sh index 7d3ac12..990b579 100755 --- a/buildscripts/libs/build_netcdf.sh +++ b/buildscripts/libs/build_netcdf.sh @@ -120,8 +120,6 @@ echo "########################################################################## # Load netcdf-c before building netcdf-fortran $MODULES && module load netcdf -module list - set -x cd $curr_dir From 6fa25de8c7b95eb6ab6e8ce99e4870c54409fe51 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Tue, 3 Nov 2020 18:20:36 -0700 Subject: [PATCH 010/132] fix for building json schema validator --- buildscripts/libs/build_json-schema-validator.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/buildscripts/libs/build_json-schema-validator.sh b/buildscripts/libs/build_json-schema-validator.sh index 1064d75..3f3de14 100755 --- a/buildscripts/libs/build_json-schema-validator.sh +++ b/buildscripts/libs/build_json-schema-validator.sh @@ -12,8 +12,8 @@ if $MODULES; then set +x source $MODULESHOME/init/bash module load jedi-$JEDI_COMPILER - module try-load cmake - module try-load json + module load cmake + module load json module list set -x @@ -38,11 +38,13 @@ url="https://github.com/pboettch/json-schema-validator/archive/$tarfile" [[ -d build ]] && rm -rf build mkdir -p build && cd build -echo nlohmann_json_DIR=$nlohmann_json_DIR +[[ -n $nlohmann_json_ROOT ]] || ( echo "Required json.hpp class not installed, ABORT!"; exit 1 ) +echo nlohmann_json_DIR=$nlohmann_json_ROOT cmake .. \ -DCMAKE_INSTALL_PREFIX=$prefix \ -DCMAKE_BUILD_TYPE=Release \ -DBUILD_SHARED_LIBS=Y \ + -Dnlohmann_json_DIR=$nlohmann_json_ROOT/include \ -DBUILD_TESTS=$MAKE_CHECK \ -DBUILD_EXAMPLES=N [[ $MAKE_CHECK =~ [yYtT] ]] && make test From f6232c3f469ad32f6414d560d52052f3b451b92c Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Tue, 3 Nov 2020 18:38:10 -0700 Subject: [PATCH 011/132] Update build_json-schema-validator.sh --- buildscripts/libs/build_json-schema-validator.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_json-schema-validator.sh b/buildscripts/libs/build_json-schema-validator.sh index 3f3de14..3a84fe3 100755 --- a/buildscripts/libs/build_json-schema-validator.sh +++ b/buildscripts/libs/build_json-schema-validator.sh @@ -44,7 +44,7 @@ cmake .. \ -DCMAKE_INSTALL_PREFIX=$prefix \ -DCMAKE_BUILD_TYPE=Release \ -DBUILD_SHARED_LIBS=Y \ - -Dnlohmann_json_DIR=$nlohmann_json_ROOT/include \ + -Dnlohmann_json_DIR=$nlohmann_json_DIR/include \ -DBUILD_TESTS=$MAKE_CHECK \ -DBUILD_EXAMPLES=N [[ $MAKE_CHECK =~ [yYtT] ]] && make test From 847ba3fd22d23f1423746e72749233be2231cf8f Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Wed, 4 Nov 2020 09:09:19 -0700 Subject: [PATCH 012/132] Update build_json-schema-validator.sh Change loading of cmake module back to try-load, as cmake is not necessarily a loaded module across all systems; on some hosts, it's installed and available. --- buildscripts/libs/build_json-schema-validator.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_json-schema-validator.sh b/buildscripts/libs/build_json-schema-validator.sh index 3a84fe3..a4c7362 100755 --- a/buildscripts/libs/build_json-schema-validator.sh +++ b/buildscripts/libs/build_json-schema-validator.sh @@ -12,7 +12,7 @@ if $MODULES; then set +x source $MODULESHOME/init/bash module load jedi-$JEDI_COMPILER - module load cmake + module try-load cmake module load json module list set -x From 6f7b60475421be7c4bc62837b34450823114406a Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Wed, 4 Nov 2020 11:55:25 -0700 Subject: [PATCH 013/132] Update build_json-schema-validator.sh Using JSON_DIR as this name more closely corresponds with what the schema validator requires; that is, a value for nlohmann_json_DIR. JSON_DIR is set in the json module file, and points to cmake configuration files used by the schema validator. --- buildscripts/libs/build_json-schema-validator.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/buildscripts/libs/build_json-schema-validator.sh b/buildscripts/libs/build_json-schema-validator.sh index a4c7362..710d77c 100755 --- a/buildscripts/libs/build_json-schema-validator.sh +++ b/buildscripts/libs/build_json-schema-validator.sh @@ -38,13 +38,13 @@ url="https://github.com/pboettch/json-schema-validator/archive/$tarfile" [[ -d build ]] && rm -rf build mkdir -p build && cd build -[[ -n $nlohmann_json_ROOT ]] || ( echo "Required json.hpp class not installed, ABORT!"; exit 1 ) -echo nlohmann_json_DIR=$nlohmann_json_ROOT +# JSON_DIR is set in the json module lua file +[[ -n $JSON_DIR ]] || ( echo "Required json cmake configuration not found, ABORT!"; exit 1 ) cmake .. \ -DCMAKE_INSTALL_PREFIX=$prefix \ -DCMAKE_BUILD_TYPE=Release \ -DBUILD_SHARED_LIBS=Y \ - -Dnlohmann_json_DIR=$nlohmann_json_DIR/include \ + -Dnlohmann_json_DIR=$JSON_DIR \ -DBUILD_TESTS=$MAKE_CHECK \ -DBUILD_EXAMPLES=N [[ $MAKE_CHECK =~ [yYtT] ]] && make test From 05fe697562c73f427099b645fa2058202b4760b2 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Wed, 4 Nov 2020 11:57:44 -0700 Subject: [PATCH 014/132] update json module file to set vars for schema-validator --- modulefiles/core/json/json.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modulefiles/core/json/json.lua b/modulefiles/core/json/json.lua index 2a22ea4..9d65474 100644 --- a/modulefiles/core/json/json.lua +++ b/modulefiles/core/json/json.lua @@ -11,8 +11,8 @@ local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" local base = pathJoin(opt,"core",pkgName,pkgVersion) -setenv("nlohmann_json_ROOT", base) -setenv("nlohmann_json_DIR", pathJoin(base,"lib","cmake","nlohmann_json")) +setenv("JSON_ROOT", base) +setenv("JSON_DIR", pathJoin(base,"lib","cmake","nlohmann_json")) whatis("Name: ".. pkgName) whatis("Version: " .. pkgVersion) From 1a1c4fbdf285c9950183e9066e586fdca7914edb Mon Sep 17 00:00:00 2001 From: mmiesch Date: Thu, 5 Nov 2020 11:52:02 -0700 Subject: [PATCH 015/132] need this to test in the container --- buildscripts/libs/build_netcdf.sh | 2 -- 1 file changed, 2 deletions(-) diff --git a/buildscripts/libs/build_netcdf.sh b/buildscripts/libs/build_netcdf.sh index 7d3ac12..990b579 100755 --- a/buildscripts/libs/build_netcdf.sh +++ b/buildscripts/libs/build_netcdf.sh @@ -120,8 +120,6 @@ echo "########################################################################## # Load netcdf-c before building netcdf-fortran $MODULES && module load netcdf -module list - set -x cd $curr_dir From 34803c8406deb2f16c9d9a05db84f7bb5ac9c2b0 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Thu, 5 Nov 2020 17:03:49 -0700 Subject: [PATCH 016/132] Update build_json-schema-validator.sh Conditionally set JSON_DIR here if modules are not used and it's not set in a module file --- buildscripts/libs/build_json-schema-validator.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/buildscripts/libs/build_json-schema-validator.sh b/buildscripts/libs/build_json-schema-validator.sh index 710d77c..1e5ed7c 100755 --- a/buildscripts/libs/build_json-schema-validator.sh +++ b/buildscripts/libs/build_json-schema-validator.sh @@ -24,7 +24,8 @@ if $MODULES; then fi else - prefix=${json_ROOT:-"/usr/local"} + prefix=${JSON_ROOT:-"/usr/local"} + JSON_DIR=${JSON_DIR:-$prefix/lib/cmake/nlohmann_json} fi cd $JEDI_STACK_ROOT/${PKGDIR:-"pkg"} @@ -38,7 +39,6 @@ url="https://github.com/pboettch/json-schema-validator/archive/$tarfile" [[ -d build ]] && rm -rf build mkdir -p build && cd build -# JSON_DIR is set in the json module lua file [[ -n $JSON_DIR ]] || ( echo "Required json cmake configuration not found, ABORT!"; exit 1 ) cmake .. \ -DCMAKE_INSTALL_PREFIX=$prefix \ From b9706909839d49f3c19258fff3dc4055b7f92cea Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Tue, 3 Nov 2020 18:20:36 -0700 Subject: [PATCH 017/132] fix for building json schema validator --- buildscripts/libs/build_json-schema-validator.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/buildscripts/libs/build_json-schema-validator.sh b/buildscripts/libs/build_json-schema-validator.sh index 0147d7e..ea44107 100755 --- a/buildscripts/libs/build_json-schema-validator.sh +++ b/buildscripts/libs/build_json-schema-validator.sh @@ -12,8 +12,8 @@ if $MODULES; then set +x source $MODULESHOME/init/bash module load jedi-$JEDI_COMPILER - module try-load cmake - module try-load json + module load cmake + module load json module list set -x @@ -38,12 +38,14 @@ url="https://github.com/pboettch/json-schema-validator/archive/$tarfile" [[ -d build ]] && rm -rf build mkdir -p build && cd build -echo nlohmann_json_DIR=$nlohmann_json_DIR +[[ -n $nlohmann_json_ROOT ]] || ( echo "Required json.hpp class not installed, ABORT!"; exit 1 ) +echo nlohmann_json_DIR=$nlohmann_json_ROOT cmake .. \ -DCMAKE_INSTALL_PREFIX=$prefix \ -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_POLICY_DEFAULT_CMP0074=NEW \ -DBUILD_SHARED_LIBS=Y \ + -Dnlohmann_json_DIR=$nlohmann_json_ROOT/include \ -DBUILD_TESTS=$MAKE_CHECK \ -DBUILD_EXAMPLES=N [[ $MAKE_CHECK =~ [yYtT] ]] && make test From 7184b625ce4c31348cbdffec2d29a784b65a79af Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Wed, 4 Nov 2020 11:45:21 -0700 Subject: [PATCH 018/132] resolve merge conflicts with json.lua file --- buildscripts/libs/build_json-schema-validator.sh | 8 ++++---- modulefiles/core/json/json.lua | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/buildscripts/libs/build_json-schema-validator.sh b/buildscripts/libs/build_json-schema-validator.sh index ea44107..48965e5 100755 --- a/buildscripts/libs/build_json-schema-validator.sh +++ b/buildscripts/libs/build_json-schema-validator.sh @@ -12,7 +12,7 @@ if $MODULES; then set +x source $MODULESHOME/init/bash module load jedi-$JEDI_COMPILER - module load cmake + module try-load cmake module load json module list set -x @@ -38,14 +38,14 @@ url="https://github.com/pboettch/json-schema-validator/archive/$tarfile" [[ -d build ]] && rm -rf build mkdir -p build && cd build -[[ -n $nlohmann_json_ROOT ]] || ( echo "Required json.hpp class not installed, ABORT!"; exit 1 ) -echo nlohmann_json_DIR=$nlohmann_json_ROOT +[[ -n $JSON_DIR ]] || ( echo "Required json cmake configuration not found, ABORT!"; exit 1 ) + cmake .. \ -DCMAKE_INSTALL_PREFIX=$prefix \ -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_POLICY_DEFAULT_CMP0074=NEW \ -DBUILD_SHARED_LIBS=Y \ - -Dnlohmann_json_DIR=$nlohmann_json_ROOT/include \ + -Dnlohmann_json_DIR=$JSON_DIR \ -DBUILD_TESTS=$MAKE_CHECK \ -DBUILD_EXAMPLES=N [[ $MAKE_CHECK =~ [yYtT] ]] && make test diff --git a/modulefiles/core/json/json.lua b/modulefiles/core/json/json.lua index 120b20f..9d65474 100644 --- a/modulefiles/core/json/json.lua +++ b/modulefiles/core/json/json.lua @@ -11,7 +11,8 @@ local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" local base = pathJoin(opt,"core",pkgName,pkgVersion) -setenv("nlohmann_json_ROOT", base) +setenv("JSON_ROOT", base) +setenv("JSON_DIR", pathJoin(base,"lib","cmake","nlohmann_json")) whatis("Name: ".. pkgName) whatis("Version: " .. pkgVersion) From e1600d646e4dc52868609ba2a1a13c134dbf7bbd Mon Sep 17 00:00:00 2001 From: mmiesch Date: Thu, 12 Nov 2020 18:17:22 -0700 Subject: [PATCH 019/132] build JSON in the containers too --- buildscripts/config/config_container-clang-mpich-dev.sh | 2 +- buildscripts/config/config_container-gnu-openmpi-dev.sh | 2 +- buildscripts/config/config_container-intel-impi-dev.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/buildscripts/config/config_container-clang-mpich-dev.sh b/buildscripts/config/config_container-clang-mpich-dev.sh index 55fc60a..89bd2e8 100644 --- a/buildscripts/config/config_container-clang-mpich-dev.sh +++ b/buildscripts/config/config_container-clang-mpich-dev.sh @@ -80,6 +80,6 @@ export STACK_BUILD_CGAL=N export STACK_BUILD_GEOS=N export STACK_BUILD_SQLITE=N export STACK_BUILD_PROJ=N -export STACK_BUILD_JSON=N +export STACK_BUILD_JSON=Y export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y export STACK_BUILD_FMS=N diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index e01f17d..63d4e4c 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -81,6 +81,6 @@ export STACK_BUILD_CGAL=N export STACK_BUILD_GEOS=N export STACK_BUILD_SQLITE=N export STACK_BUILD_PROJ=N -export STACK_BUILD_JSON=N +export STACK_BUILD_JSON=Y export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y export STACK_BUILD_FMS=N diff --git a/buildscripts/config/config_container-intel-impi-dev.sh b/buildscripts/config/config_container-intel-impi-dev.sh index ae82df9..1f7e124 100644 --- a/buildscripts/config/config_container-intel-impi-dev.sh +++ b/buildscripts/config/config_container-intel-impi-dev.sh @@ -82,6 +82,6 @@ export STACK_BUILD_BASELIBS=N export STACK_BUILD_PDTOOLKIT=N export STACK_BUILD_TAU2=N export STACK_BUILD_CGAL=N -export STACK_BUILD_JSON=N +export STACK_BUILD_JSON=Y export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y export STACK_BUILD_FMS=N From 915c48c6b6303559ee56df750ba156470f0bcb74 Mon Sep 17 00:00:00 2001 From: Stephen Herbener Date: Mon, 30 Nov 2020 17:08:30 -0700 Subject: [PATCH 020/132] Added capability to use either noaa-emc or jcsda fork for building NCEPLIBS-bufr. --- buildscripts/build_stack.sh | 3 +-- buildscripts/libs/build_bufr.sh | 26 +++++++++++++++++-------- modulefiles/apps/jedi/clang-mpich.lua | 2 +- modulefiles/apps/jedi/clang-openmpi.lua | 2 +- 4 files changed, 21 insertions(+), 12 deletions(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index ed7dc8d..6004303 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -86,8 +86,7 @@ build_lib SZIP szip 2.1.1 build_lib LAPACK lapack 3.8.0 build_lib BOOST_HDRS boost 1.68.0 headers-only build_lib EIGEN3 eigen 3.3.7 -#build_lib BUFRLIB bufrlib 11.4.0 -build_lib BUFR bufr 11.4.0 +build_lib BUFR bufr jcsda 11.4.0.jcsda1 build_lib ECBUILD ecbuild jcsda 3.3.2.jcsda3 build_lib CGAL cgal 5.0.2 build_lib GITLFS git-lfs 2.11.0 diff --git a/buildscripts/libs/build_bufr.sh b/buildscripts/libs/build_bufr.sh index 515f396..4a70859 100755 --- a/buildscripts/libs/build_bufr.sh +++ b/buildscripts/libs/build_bufr.sh @@ -7,7 +7,9 @@ set -ex name="bufr" -version=$1 +# source should either be noaa-emc or jcsda +source=$1 +version=$2 # Hyphenated version used for install prefix compiler=$(echo $JEDI_COMPILER | sed 's/\//-/g') @@ -21,7 +23,7 @@ if $MODULES; then module list set -x - prefix="${PREFIX:-"/opt/modules"}/$compiler/$name/$version" + prefix="${PREFIX:-"/opt/modules"}/$compiler/$name/$source-$version" if [[ -d $prefix ]]; then [[ $OVERWRITE =~ [yYtT] ]] && ( echo "WARNING: $prefix EXISTS: OVERWRITING!";$SUDO rm -rf $prefix ) \ || ( echo "WARNING: $prefix EXISTS, SKIPPING"; exit 1 ) @@ -37,21 +39,29 @@ export CC=$SERIAL_CC software=NCEPLIBS-bufr # Release git tag name -tag=bufr_v$version +if [[ ${source} == "jcsda" ]] +then + gitOrg="jcsda-internal" + tag=$version +else + gitOrg="${source}" + tag=bufr_v$version +fi cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} -[[ -d $software ]] || git clone https://github.com/noaa-emc/$software.git +[[ -d $software ]] || git clone https://github.com/$gitOrg/$software.git [[ ${DOWNLOAD_ONLY} =~ [yYtT] ]] && exit 0 [[ -d $software ]] && cd $software || ( echo "$software does not exist, ABORT!"; exit 1 ) git fetch git checkout --detach $tag -[[ -d build ]] && rm -rf build +#[[ -d build ]] && rm -rf build +[[ -d build ]] && $SUDO rm -rf build mkdir -p build && cd build -cmake -DCMAKE_INSTALL_PREFIX=$prefix .. +cmake -DENABLE_PYTHON=ON -DCMAKE_INSTALL_PREFIX=$prefix .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install # generate modulefile from template -$MODULES && update_modules compiler $name $version \ - || echo $name $version >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log +$MODULES && update_modules compiler $name $source-$version \ + || echo $name $source-$version >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log diff --git a/modulefiles/apps/jedi/clang-mpich.lua b/modulefiles/apps/jedi/clang-mpich.lua index e5c4cd8..4d04d36 100644 --- a/modulefiles/apps/jedi/clang-mpich.lua +++ b/modulefiles/apps/jedi/clang-mpich.lua @@ -19,7 +19,7 @@ load("netcdf") load("lapack") load("boost-headers") load("eigen") -load("bufrlib") +load("bufr") load("json") load("json-schema-validator") diff --git a/modulefiles/apps/jedi/clang-openmpi.lua b/modulefiles/apps/jedi/clang-openmpi.lua index d9a85da..8c52b6c 100644 --- a/modulefiles/apps/jedi/clang-openmpi.lua +++ b/modulefiles/apps/jedi/clang-openmpi.lua @@ -19,7 +19,7 @@ load("netcdf") load("lapack") load("boost-headers") load("eigen") -load("bufrlib") +load("bufr") load("json") load("json-schema-validator") From afe5f2495a2c010f037c56898fc2e91d7d5e534b Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 2 Dec 2020 17:17:57 -0700 Subject: [PATCH 021/132] update list of jedi-stack components and separate it from build instructions. --- README.md | 300 ++++++++++++++++++--------------------------------- doc/Build.md | 167 ++++++++++++++++++++++++++++ 2 files changed, 273 insertions(+), 194 deletions(-) create mode 100644 doc/Build.md diff --git a/README.md b/README.md index e688286..7bc54e1 100644 --- a/README.md +++ b/README.md @@ -5,210 +5,122 @@ The motivation is to define a common set of software packages and versions to be We want to provide a common set of software libraries to JEDI users and developers in order to minimize problems associated with incompatible or outdated software versions. However, we also wish to take advantage of site-specific configurations and optimizations that exploit the local hardware. For this reason, the build process is designed to use native installations of the compiler suite and the MPI libraries. The rest of the software stack is build from source for the specified compiler/mpi combination. -Building the JEDI software stack is a **Four-Step process**, as described in the following sections. - -[See here for additional tips on particular platforms](doc/Platforms.md) - -## Step 1: Set up Basic Environment +# Current JEDI Stack Components + + + +## Required, but not sensitive to version: often installed via package manager of native modules + +| software | minimum version | Notes | +| ------- | --------------- | ----- | +| compiler | --- | C++, C, and Fortran; commonly used: gnu (gcc/gfortran), clang, intel; must support C++-14 +| MPI library | --- | commonly used: Openmpi, mpich, Intel MPI +| cmake | 3.16 | | +| git-lfs | 2.11 | | + + +## Required components of the stack on most HPC systems, laptops, and containers - installed via jedi-stack (current release versions) + +| software | version | Notes | +| -------- | ------- | ----- | +| udunits | 2.2.26 | | +| zlib | 1.2.11 | | +| szip | 2.1.1 | | +| lapack | 3.8.0 | Can be replaced by intel mkl | +| Boost | 1.68.0 | headers only | +| Eigen | 3.3.7 | | +| ecbuild | jcsda/3.3.2.jcsda3 | Should move to ecmwf for future releases | +| hdf5 | 1.12.0 | | +| pnetcdf | 1.12.1 | | +| netcdf | 4.7.4, 4.5.3, 4.3.0 | versions for C, Fortran, and C++ | +| nccmp | 1.8.7.0 | Needed for running tests | +| eckit | jcsda/1.11.6.jcsda2 | Should move to ecmwf for next release | +| bufrlib | 11.3.2 | will be replaced by NCEP bufr | +| pybind11 | 2.5.0 | | +| gsl_lite | 0.34.0 | | + +## New components since most recent release + +| software | version | Notes | +| -------- | ------- | ----- | +| CGAL | 5.0.2 | Optional in principle but may become required in practice for efficiency reasons. Can be installed without gmp, mpfr dependencies | +| bufr | 11.4.0 | NCEP version will replace current bufrlib | + +## Required for certain components or models + +| software | version | Notes | +| -------- | ------- | ----- | +| PIO | 2.5.1 | Needed for MPAS | + +## Required, but not necessarily in HPC modules + +| software | version | Notes | +| -------- | ------- | ----- | +| pyjedi | --- | Python tools installed in user space. Should be deprecated soon in lieu of python dependencies handled by individual repos, solo, new bufr libraries, and/or virtual environments | +| json | 3.9.1 | | +| json-schema-validator | 2.1.0 | used for testing | +| doxygen+dot | --- | used for generating documentation | +| latex | --- | used for generating documentation | + +## Optional + +These can be build by jedi-stack but they are not required for jedi. + +| software | version | Notes | +| -------- | ------- | ----- | +| NCO | 4.7.9 | Can use a native module or package installation? | +| fckit | jcsda/0.7.0.jcsda1 | Usually not included in stack; should move to ecmwf versions for next releases | +| atlas | jcsda/0.20.2.jcsda1 | Usually not included in stack; should move to ecmwf versions for releases | +| fms | jcsda/release-stable | Currently not include in stack but moving toward including it| +| gptl | 8.0.3 | profiling tool | +| fftw | 3.3.8 | | +| Boost (full) | 1.68.0 | | +| esmf | 8_0_1 | | +| baselibs | 5.2.2 | | +| pdtoolkit | 3.25.1 | Tau dependency | +| tau2 | 3.25.1 | | +| armadillo | 1.900.1 | No longer used? | +| odc | jcsda/1.0.3 | | +| png | 1.6.35 | | +| jpeg | 9.1.0 | | +| jasper | 1.900.1 | | +| xerces | 3.1.4 | | +| nceplibs | fv3 | | +| tkdiff | 4.3.5 | | +| geos | 3.8.1 | | +| sqlite | 3.32.3 | | +| proj | 7.1.0 | | + +# Building the JEDI Stack + +[The procedure to build the jedi-stack is described here](doc/Build.md) -This is the most context-dependent part of the build process. How you proceed depends on the system you are on. Regardless of how you proceed, this step only needs to be done once for each system. -Note - you can skip this step and move on to Step 2 if you are building a JEDI software container because all of the required software packages are already built into the jcsda/docker_base container, which you can just pull from Docker Hub. - -This step is most important for bare linux/unix systems, as you would get with a new cloud computing instance, a container build, or a virtual machine (e.g. [vagrant](https://www.vagrantup.com)). For such systems, Step 1 consists of running the following script (all paths are relative to the base path of the jedi-stack repository): -``` -cd buildscripts -./setup_environment.sh -``` -where `` depends on your operating system and the context of the build (for example, if you're in a container or on the cloud or on an HPC system). Examples include `docker-devel` or `ubuntu/18.04`. To see a list of supported options, run the script without any arguments: -``` -./setup_environment.sh -``` -**Warning: for some (not all) options, running this script requires root privileges.** - -The purpose of this script is to install some basic software packages, the most important of which are: -* GNU compiler suite (gcc, g++, gfortran) -* [Lmod](https://lmod.readthedocs.io/en/latest/index.html) module management system -* git, [git-lfs](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/developer/developer_tools/gitlfs.html), and [git-flow](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/developer/developer_tools/getting-started-with-gitflow.html) -* wget and curl -* make and [CMake](https://cmake.org) -* [doxygen](http://www.doxygen.nl) and [graphviz](https://www.graphviz.org) -* Debugging tools, including [kdbg](http://www.kdbg.org/) and valgrind - -Many of these are installed with package managers such as [apt-get](https://linux.die.net/man/8/apt-get) for Linux or [HomeBrew on Linux](https://docs.brew.sh/Homebrew-on-Linux) and [HomeBrew](https://brew.sh/) for Mac OSX. A few scripts are also provided in the libs directory for such packages as `Lmod` and `CMake` if you would rather install these from source. - -If you are using your own laptop or workstation, it is likely that most of these basic packages are already installed. If any of these packages are missing from your system (such as Lmod), you can manually install them with a package manager or with the build scripts. The items near the bottom of the list are not essential - if you don't have them on your system there is no need to install them. - -If you are building on a EMC RHEL7 workstation, use [HomeBrew on Linux](https://docs.brew.sh/Homebrew-on-Linux) to manually install the basic software packages. Follow the instructions at the HomeBrew on Linux website for installing HomeBrew itself, then run the following brew commands: -~~~~~~~~ -brew install lmod -brew install git -brew install git-lfs -brew install git-flow-avh -brew install cmake -brew install doxygen -brew install graphviz -brew install sphinx-doc -~~~~~~~~ - -If you are building on Mac OSX with Clang, then do not run the `setup_environments.sh` script, and instead use [HomeBrew](https://brew.sh/) to manually install the basic software packages. Follow the instructions at the HomeBrew website for installing HomeBrew itself, then run the following brew commands: -~~~~~~~~ -brew install gcc@7 # install version 7 GNU compilers, don't install version 8 GNU as it - # has known problems with JEDI -brew install lmod -brew install git -brew install git-lfs -brew install git-flow-avh -brew install wget -brew install cmake -brew install doxygen -brew install graphviz - -# brew can be used to install any other basic tools that you want such as tkdiff, gdb, etc. -~~~~~~~~ - -See the [section below](#MacPython) for instructions to install python on the Mac. - -Your Mac should have come with Clang compilers for C and C++ pre-installed, so in this scheme you are adding in GFortran (GNU) for compiling Fortran code. Once you have finished with the brew install commands, make sure to set `JEDI_OPT` in your environment as described below. - -If you're on an HPC system you can largely skip this step (but you still need to set the **JEDI_OPT** environment variable, see below) because most of these packages are probably already installed and available. However, there are a few items that you may wish to add by loading the appropriate modules (if they exist) - for example: -``` -module load doxygen git-lfs -``` -Note, however, if you are using [JEDI Modules](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/developer/jedi_environment/modules.html) you do not have to worry about this (or indeed, about this repository in general) - the JEDI team will make sure that the modules provided will include the packages you need. - -**IMPORTANT:** Another responsibility of the `setup_environment.sh` script is to define the `JEDI_OPT` environment variable and initialize the Lmod system. These actions are needed both for the build and to allow users to load the JEDI modules after you build them. `JEDI_OPT` specifies where the modules will be installed, with a default value of `JEDI_OPT=/opt/modules`. Note that this default value normally requires root permission so you would have to set the `USE_SUDO` flag (see Step 2). If you do not have root privileges (e.g. on an HPC system), you may wish to install your modules in a home or work directory, e.g. `JEDI_OPT=$HOME/opt/modules`. - -`JEDI_OPT` needs to be set and Lmod initialized in order to complete Steps 2-4. But, these actions also need to be performed in order for users to use the modules. Be sure to add the following to your shell initialization scripts (example shown is for bash): -``` -# For jedi-stack -export JEDI_OPT=/opt/modules - -# For lmod modules -. /usr/local/opt/lmod/init/profile -module use $JEDI_OPT/modulefiles/core -``` -and make sure these settings are in place before proceeding to Steps 2-4. - -## Step 2: Configure Build - -The next step is to choose what components of the stack you wish to build and to specify any other aspects of the build that you would like. This is normally done by editing one of the platform-specific `buildscripts/config/config_*.sh` files. Or, if your platform is not among the options, you can edit the `config_custom.sh` file. Then, edit the `buildscripts/config/choose_modules.sh` file to choose which modules you wish to build. Note that some are prerequisites of others. For example, you must build hdf5 before you build netcdf. - -Here we describe some of the parameter settings available in these configuration files. - -For building on Mac OSX, a configuration file (`config_mac.sh`) is provided. This configuration is set up to build using Clang 10.0.0 with gfortran and OpenMPI. You may wish to edit this file for building with a different compiler/mpi set. - -For building on an EMC RHEL7 workstation, a configuration file (`config_rhel7emc.sh`) is provided. This . - -**JEDI_COMPILER** This defines the vendor and version of the compiler you wish to use for this build. The format is the same as what you would typically use in a module load command: -``` -export COMPILER=/ -``` -For example, `COMPILER=gnu/7.3.0`. - -**JEDI_MPI** is the MPI library you wish to use for this build. The format is the same as for `COMPILER`, for example: `export MPI=openmpi/3.1.2`. - -**PREFIX** is the directory where the software packages will be installed. Normally this is set to be the same as the `JEDI_OPT` environment variable (default value `/opt/modules`), though this is not required. If `JEDI_OPT` and `PREFIX` are both the same, then the software installation trees (the top level of each being is the compiler, e.g. `gnu-7.3.0`) will branch directly off of `$JEDI_OPT` while the module files will be located in the `modulefiles subdirectory. - -**USE_SUDO** If `PREFIX` is set to a value that requires root permission to write to, such as `/opt/modules`, then this flag should be enabled. - -_**NOTE: To enable a boolean flag use a single-digit `Y` or `T`. To disable, use `N` or `F` (case insensitive)**_ - -**PKGDIR** is the directory where tarred or zipped software files will be downloaded and compiled. Unlike `PREFIX`, this is a relative path, based on the root path of the repository. Individual software packages can be downloaded manually to this directory and untarred, but this is not required. Most build scripts will look for directory `pkg/pkgName-pkgVersion` e.g. `pkg/hdf5-1_10_3`. - -**LOGDIR** is the directory where log files from the build will be written, relative to the root path of the repository. - -**OVERWRITE** If set, this flag will cause the build script to remove the current installation, if any exists, and replace it with the new version of each software package in question. If this is not set, the build will bypass software packages that are already installed. - -**NTHREADS** The number of threads to use for parallel builds - -**MAKE_CHECK** Run `make check` after build - -**MAKE_VERBOSE** Print out extra information to the log files during the build - -The remaining items enable or disable builds of each software package. The following software can optionally be built with the scripts under `buildscripts`. Unless otherwise noted, the packages are built in Step 4 using the `build_scripts.sh` script. - -* Compilers and MPI libraries - - GNU (Step 3) - - OpenMPI - - MPICH - - `jedi-` Meta-modules for all the above as well as Intel and IMPI - -* Minimal JEDI Stack - - SZip - - Zlib - - HDF5 - - NetCDF - - PNetCDF - - Udunits - - LAPACK - - Boost (Headers only) - - Eigen3 - - ncccmp - - nco - - ecbuild, eckit, fckit - - ODB - -* Supplementary Libraries - - PNG - - JPEG - - Jasper - - Armadillo - - Boost (full installation) - - FFTW - - ecCodes - - ESMF - - FMS - - ESMA-Baselibs - - nceplibs - -**IMPORTANT: Steps 2, 3, and 4 need to be repeated for each compiler/mpi combination that you wish to install.** The new packages will be installed alongside any previously-existing packages that may already exist and that are built from other compiler/mpi combinations. +# Adding a New library/package -## Step 3: Set Up Compiler, MPI, and Module System +It is desirable to limit the number of software packages included in jedi-stack for several reasons. -The next step is to run this from the buildscripts directory: -``` -./setup_modules.sh [] -``` -where `` points to the configuration script that you wish to use, as described in Step 2. The name of this file is `config/config_`. For example, to use the `config/config_custom.sh` you would enter this: -``` -./setup_modules.sh custom -``` -If no arguments are specified, the default is `custom`. Note that you can skip this step as well for container builds because we currenly include only one compiler/mpi combination in each container. So, each package is only build once and there is no need for modules. +Adding dependencies to JEDI may adversely affect its portability. New dependencies could pose problems for some platforms and compilers or could conflict with other stack components. As the stack grows, it takes more work to mainin on multiple systems. -For building on Mac OSX, use: -``` -./setup_modules.sh mac -``` +Adding optional build scripts for packages not required by JEDI also increases maintenance work to test them and keep them up to date. We do not want to support build scripts that are not commonly used. -This script sets up the module directory tree in `$JEDI_OPT`. It also sets up the compiler and mpi modules. The compiler and mpi modules are handled separately from the rest of the build because, when possible, we wish to exploit site-specific installations that maximize performance. +For these reasons, additions to the JEDI stack must first be approved by the JEDI Software Infrastructure team. -**For this reason, the compiler and mpi modules are preceded by a `jedi-` label**. For example, to load the gnu compiler module and the openmpi software library, you would enter this: -``` -module load jedi-gnu/7.3.0 -module load jedi-openmpi/3.2.1 -``` -These `jedi-` modules are really meta-modules that will both load the compiler/mpi library and modify the `MODULEPATH` so the user has access to the software packages that will be built in Step 4. On HPC systems, these meta-modules will load the native modules provided by the system administrators. For example, `module load jedi-openmpi/3.2.1` will first load the native `openmpi/3.2.1` module and then modify the `MODULEPATH` accordingly to allow users to access the JEDI libraries. If this module is not available (e.g. in a container or in the cloud), then the `openmpi/3.2.1` module will be built from source and installed into `$JEDI_OPT`. +## Vetting process -So, in short, you should never load the compiler or MPI modules directly. Instead, you should always load the `jedi-` meta-modules as demonstrated above - they will provide everything you need to load and then use the JEDI software libraries. +If you want to add a new library to the stack you need to first propose : +1. Create a Zenhub issue that describes the reason for the addition. Which JEDI components require it? Why is it beneficial to add to the stack? Can it be installed or acquired a different way? (If you do not have access to the internal JCSDA ZenHub boards you can create a thread on the [JCSDA forums](https://forums.jcsda.org)). Bring it to the attention of the JEDI Software Infrastructure team by "asssigning" or tagging individual members. -## Step 4: Build JEDI Stack +2. The issue will be discussed at one or more meetings of the JEDI software infrastructure team. You may be contacted for further information. -Now all that remains is to build the stack: -``` -./build_stack.sh [] -``` -Here `` is the same as in Step 3, namely a reference to the corresponding configuration file in the `config` directory. As in Step 2, if this argument is omitted, the default is to use `config/config_custom.sh`. +3. The JEDI software infrastructure Team will either approve or decline the request for an addition to the jedi-stack. You will be informed of the decision through the ZenHub issue (or forum thread) or by other means (e.g. meetings, email, etc). -For building on Mac OSX, use: -~~~~~~~~ -./build_stack.sh mac -~~~~~~~~ +## Required Code Changes -# Adding a New library/package +If your request to add a package to the JEDI stack is approved by the JEDI software infrastructure team, then you can proceed to add it to the jedi-stack with the following code changes: -If you want to add a new library to the stack you need to follow these steps: -1. write a new build script in buildscripts/libs, using existing scripts as a template -2. define a new control flag and add it to the config files in buildscripts/config -3. Add a call to the new build script in buildscripts/build\_stack.sh -4. Create a new module template at the appropriate place in the modulefiles directory, using existing files as a template +1. write a new build script in `buildscripts/libs`, using existing scripts as a template +2. define a new control flag and add it to the `choose_modules.sh` and `config_container*` scripts in `buildscripts/config` +3. Add a call to the new build script in `buildscripts/build_stack.sh` +4. Create a new module template at the appropriate place in the `modulefiles` directory, using existing files as a template +5. Add the package to the list of jedi-stack components in the `README.md` file diff --git a/doc/Build.md b/doc/Build.md new file mode 100644 index 0000000..0147c29 --- /dev/null +++ b/doc/Build.md @@ -0,0 +1,167 @@ +# Builing the JEDI Stack + +Building the JEDI software stack is a **Four-Step process**, as described in the following sections. + +[See here for additional tips on particular platforms](doc/Platforms.md) + +## Step 1: Set up Basic Environment + +This is the most context-dependent part of the build process. How you proceed depends on the system you are on. Regardless of how you proceed, this step only needs to be done once for each system. + +Note - you can skip this step and move on to Step 2 if you are building a JEDI software container because all of the required software packages are already built into the jcsda/docker_base container, which you can just pull from Docker Hub. + +This step is most important for bare linux/unix systems, as you would get with a new cloud computing instance, a container build, or a virtual machine (e.g. [vagrant](https://www.vagrantup.com)). For such systems, Step 1 consists of running the following script (all paths are relative to the base path of the jedi-stack repository): +``` +cd buildscripts +./setup_environment.sh +``` +where `` depends on your operating system and the context of the build (for example, if you're in a container or on the cloud or on an HPC system). Examples include `docker-devel` or `ubuntu/18.04`. To see a list of supported options, run the script without any arguments: +``` +./setup_environment.sh +``` +**Warning: for some (not all) options, running this script requires root privileges.** + +The purpose of this script is to install some basic software packages, the most important of which are: +* GNU compiler suite (gcc, g++, gfortran) +* [Lmod](https://lmod.readthedocs.io/en/latest/index.html) module management system +* git, [git-lfs](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/developer/developer_tools/gitlfs.html), and [git-flow](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/developer/developer_tools/getting-started-with-gitflow.html) +* wget and curl +* make and [CMake](https://cmake.org) +* [doxygen](http://www.doxygen.nl) and [graphviz](https://www.graphviz.org) +* Debugging tools, including [kdbg](http://www.kdbg.org/) and valgrind + +Many of these are installed with package managers such as [apt-get](https://linux.die.net/man/8/apt-get) for Linux or [HomeBrew on Linux](https://docs.brew.sh/Homebrew-on-Linux) and [HomeBrew](https://brew.sh/) for Mac OSX. A few scripts are also provided in the libs directory for such packages as `Lmod` and `CMake` if you would rather install these from source. + +If you are using your own laptop or workstation, it is likely that most of these basic packages are already installed. If any of these packages are missing from your system (such as Lmod), you can manually install them with a package manager or with the build scripts. The items near the bottom of the list are not essential - if you don't have them on your system there is no need to install them. + +If you are building on a EMC RHEL7 workstation, use [HomeBrew on Linux](https://docs.brew.sh/Homebrew-on-Linux) to manually install the basic software packages. Follow the instructions at the HomeBrew on Linux website for installing HomeBrew itself, then run the following brew commands: +~~~~~~~~ +brew install lmod +brew install git +brew install git-lfs +brew install git-flow-avh +brew install cmake +brew install doxygen +brew install graphviz +brew install sphinx-doc +~~~~~~~~ + +If you are building on Mac OSX with Clang, then do not run the `setup_environments.sh` script, and instead use [HomeBrew](https://brew.sh/) to manually install the basic software packages. Follow the instructions at the HomeBrew website for installing HomeBrew itself, then run the following brew commands: +~~~~~~~~ +brew install gcc@7 # install version 7 GNU compilers, don't install version 8 GNU as it + # has known problems with JEDI +brew install lmod +brew install git +brew install git-lfs +brew install git-flow-avh +brew install wget +brew install cmake +brew install doxygen +brew install graphviz + +# brew can be used to install any other basic tools that you want such as tkdiff, gdb, etc. +~~~~~~~~ + +See the [section below](#MacPython) for instructions to install python on the Mac. + +Your Mac should have come with Clang compilers for C and C++ pre-installed, so in this scheme you are adding in GFortran (GNU) for compiling Fortran code. Once you have finished with the brew install commands, make sure to set `JEDI_OPT` in your environment as described below. + +If you're on an HPC system you can largely skip this step (but you still need to set the **JEDI_OPT** environment variable, see below) because most of these packages are probably already installed and available. However, there are a few items that you may wish to add by loading the appropriate modules (if they exist) - for example: +``` +module load doxygen git-lfs +``` +Note, however, if you are using [JEDI Modules](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/developer/jedi_environment/modules.html) you do not have to worry about this (or indeed, about this repository in general) - the JEDI team will make sure that the modules provided will include the packages you need. + +**IMPORTANT:** Another responsibility of the `setup_environment.sh` script is to define the `JEDI_OPT` environment variable and initialize the Lmod system. These actions are needed both for the build and to allow users to load the JEDI modules after you build them. `JEDI_OPT` specifies where the modules will be installed, with a default value of `JEDI_OPT=/opt/modules`. Note that this default value normally requires root permission so you would have to set the `USE_SUDO` flag (see Step 2). If you do not have root privileges (e.g. on an HPC system), you may wish to install your modules in a home or work directory, e.g. `JEDI_OPT=$HOME/opt/modules`. + +`JEDI_OPT` needs to be set and Lmod initialized in order to complete Steps 2-4. But, these actions also need to be performed in order for users to use the modules. Be sure to add the following to your shell initialization scripts (example shown is for bash): +``` +# For jedi-stack +export JEDI_OPT=/opt/modules + +# For lmod modules +. /usr/local/opt/lmod/init/profile +module use $JEDI_OPT/modulefiles/core +``` +and make sure these settings are in place before proceeding to Steps 2-4. + +## Step 2: Configure Build + +The next step is to choose what components of the stack you wish to build and to specify any other aspects of the build that you would like. This is normally done by editing one of the platform-specific `buildscripts/config/config_*.sh` files. Or, if your platform is not among the options, you can edit the `config_custom.sh` file. Then, edit the `buildscripts/config/choose_modules.sh` file to choose which modules you wish to build. Note that some are prerequisites of others. For example, you must build hdf5 before you build netcdf. + +Here we describe some of the parameter settings available in these configuration files. + +For building on Mac OSX, a configuration file (`config_mac.sh`) is provided. This configuration is set up to build using Clang 10.0.0 with gfortran and OpenMPI. You may wish to edit this file for building with a different compiler/mpi set. + +For building on an EMC RHEL7 workstation, a configuration file (`config_rhel7emc.sh`) is provided. This . + +**JEDI_COMPILER** This defines the vendor and version of the compiler you wish to use for this build. The format is the same as what you would typically use in a module load command: +``` +export COMPILER=/ +``` +For example, `COMPILER=gnu/7.3.0`. + +**JEDI_MPI** is the MPI library you wish to use for this build. The format is the same as for `COMPILER`, for example: `export MPI=openmpi/3.1.2`. + +**PREFIX** is the directory where the software packages will be installed. Normally this is set to be the same as the `JEDI_OPT` environment variable (default value `/opt/modules`), though this is not required. If `JEDI_OPT` and `PREFIX` are both the same, then the software installation trees (the top level of each being is the compiler, e.g. `gnu-7.3.0`) will branch directly off of `$JEDI_OPT` while the module files will be located in the `modulefiles subdirectory. + +**USE_SUDO** If `PREFIX` is set to a value that requires root permission to write to, such as `/opt/modules`, then this flag should be enabled. + +_**NOTE: To enable a boolean flag use a single-digit `Y` or `T`. To disable, use `N` or `F` (case insensitive)**_ + +**PKGDIR** is the directory where tarred or zipped software files will be downloaded and compiled. Unlike `PREFIX`, this is a relative path, based on the root path of the repository. Individual software packages can be downloaded manually to this directory and untarred, but this is not required. Most build scripts will look for directory `pkg/pkgName-pkgVersion` e.g. `pkg/hdf5-1_10_3`. + +**LOGDIR** is the directory where log files from the build will be written, relative to the root path of the repository. + +**OVERWRITE** If set, this flag will cause the build script to remove the current installation, if any exists, and replace it with the new version of each software package in question. If this is not set, the build will bypass software packages that are already installed. + +**NTHREADS** The number of threads to use for parallel builds + +**MAKE_CHECK** Run `make check` after build + +**MAKE_VERBOSE** Print out extra information to the log files during the build + +The remaining items enable or disable builds of each software package. The following software can optionally be built with the scripts under `buildscripts`. Unless otherwise noted, the packages are built in Step 4 using the `build_scripts.sh` script. + +**IMPORTANT: Steps 2, 3, and 4 need to be repeated for each compiler/mpi combination that you wish to install.** The new packages will be installed alongside any previously-existing packages that may already exist and that are built from other compiler/mpi combinations. + +## Step 3: Set Up Compiler, MPI, and Module System + +The next step is to run this from the buildscripts directory: +``` +./setup_modules.sh [] +``` +where `` points to the configuration script that you wish to use, as described in Step 2. The name of this file is `config/config_`. For example, to use the `config/config_custom.sh` you would enter this: +``` +./setup_modules.sh custom +``` +If no arguments are specified, the default is `custom`. Note that you can skip this step as well for container builds because we currenly include only one compiler/mpi combination in each container. So, each package is only build once and there is no need for modules. + +For building on Mac OSX, use: +``` +./setup_modules.sh mac +``` + +This script sets up the module directory tree in `$JEDI_OPT`. It also sets up the compiler and mpi modules. The compiler and mpi modules are handled separately from the rest of the build because, when possible, we wish to exploit site-specific installations that maximize performance. + +**For this reason, the compiler and mpi modules are preceded by a `jedi-` label**. For example, to load the gnu compiler module and the openmpi software library, you would enter this: +``` +module load jedi-gnu/7.3.0 +module load jedi-openmpi/3.2.1 +``` +These `jedi-` modules are really meta-modules that will both load the compiler/mpi library and modify the `MODULEPATH` so the user has access to the software packages that will be built in Step 4. On HPC systems, these meta-modules will load the native modules provided by the system administrators. For example, `module load jedi-openmpi/3.2.1` will first load the native `openmpi/3.2.1` module and then modify the `MODULEPATH` accordingly to allow users to access the JEDI libraries. If this module is not available (e.g. in a container or in the cloud), then the `openmpi/3.2.1` module will be built from source and installed into `$JEDI_OPT`. + +So, in short, you should never load the compiler or MPI modules directly. Instead, you should always load the `jedi-` meta-modules as demonstrated above - they will provide everything you need to load and then use the JEDI software libraries. + +## Step 4: Build JEDI Stack + +Now all that remains is to build the stack: +``` +./build_stack.sh [] +``` +Here `` is the same as in Step 3, namely a reference to the corresponding configuration file in the `config` directory. As in Step 2, if this argument is omitted, the default is to use `config/config_custom.sh`. + +For building on Mac OSX, use: +~~~~~~~~ +./build_stack.sh mac +~~~~~~~~ \ No newline at end of file From 0dc4630fdf3370fadadbed075b8b8fbb9dd6528b Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 2 Dec 2020 17:24:40 -0700 Subject: [PATCH 022/132] bugfixes --- README.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 7bc54e1..568c13d 100644 --- a/README.md +++ b/README.md @@ -5,8 +5,7 @@ The motivation is to define a common set of software packages and versions to be We want to provide a common set of software libraries to JEDI users and developers in order to minimize problems associated with incompatible or outdated software versions. However, we also wish to take advantage of site-specific configurations and optimizations that exploit the local hardware. For this reason, the build process is designed to use native installations of the compiler suite and the MPI libraries. The rest of the software stack is build from source for the specified compiler/mpi combination. -# Current JEDI Stack Components - +# Section 1: Current JEDI Stack Components ## Required, but not sensitive to version: often installed via package manager of native modules @@ -70,8 +69,8 @@ These can be build by jedi-stack but they are not required for jedi. | -------- | ------- | ----- | | NCO | 4.7.9 | Can use a native module or package installation? | | fckit | jcsda/0.7.0.jcsda1 | Usually not included in stack; should move to ecmwf versions for next releases | -| atlas | jcsda/0.20.2.jcsda1 | Usually not included in stack; should move to ecmwf versions for releases | -| fms | jcsda/release-stable | Currently not include in stack but moving toward including it| +| atlas | jcsda/0.20.2.jcsda1 | Usually not included in stack; should move to ecmwf versions for next release | +| fms | jcsda/release-stable | Currently not included in stack but moving toward including it| | gptl | 8.0.3 | profiling tool | | fftw | 3.3.8 | | | Boost (full) | 1.68.0 | | @@ -91,12 +90,12 @@ These can be build by jedi-stack but they are not required for jedi. | sqlite | 3.32.3 | | | proj | 7.1.0 | | -# Building the JEDI Stack +# Section 2: Building the JEDI Stack [The procedure to build the jedi-stack is described here](doc/Build.md) -# Adding a New library/package +# Section 3: Adding a New library/package It is desirable to limit the number of software packages included in jedi-stack for several reasons. @@ -108,7 +107,8 @@ For these reasons, additions to the JEDI stack must first be approved by the JED ## Vetting process -If you want to add a new library to the stack you need to first propose : +If you want to add a new library or software package to the stack you must first do the following: + 1. Create a Zenhub issue that describes the reason for the addition. Which JEDI components require it? Why is it beneficial to add to the stack? Can it be installed or acquired a different way? (If you do not have access to the internal JCSDA ZenHub boards you can create a thread on the [JCSDA forums](https://forums.jcsda.org)). Bring it to the attention of the JEDI Software Infrastructure team by "asssigning" or tagging individual members. 2. The issue will be discussed at one or more meetings of the JEDI software infrastructure team. You may be contacted for further information. From bd58dd1fffed97371767ea597f341522735c652c Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 2 Dec 2020 17:28:30 -0700 Subject: [PATCH 023/132] typos --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 568c13d..a96a766 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ We want to provide a common set of software libraries to JEDI users and develope # Section 1: Current JEDI Stack Components -## Required, but not sensitive to version: often installed via package manager of native modules +## Required, but not sensitive to version: These can be installed via jedi-stack but are often easier to install via package manager or native modules | software | minimum version | Notes | | ------- | --------------- | ----- | @@ -99,7 +99,7 @@ These can be build by jedi-stack but they are not required for jedi. It is desirable to limit the number of software packages included in jedi-stack for several reasons. -Adding dependencies to JEDI may adversely affect its portability. New dependencies could pose problems for some platforms and compilers or could conflict with other stack components. As the stack grows, it takes more work to mainin on multiple systems. +Adding dependencies to JEDI may adversely affect its portability. New dependencies could pose problems for some platforms and compilers or could conflict with other stack components. As the stack grows, it takes more work to maintain on multiple systems. Adding optional build scripts for packages not required by JEDI also increases maintenance work to test them and keep them up to date. We do not want to support build scripts that are not commonly used. @@ -107,7 +107,7 @@ For these reasons, additions to the JEDI stack must first be approved by the JED ## Vetting process -If you want to add a new library or software package to the stack you must first do the following: +If you want to add a new library or software package to the jedi-stack you must first do the following: 1. Create a Zenhub issue that describes the reason for the addition. Which JEDI components require it? Why is it beneficial to add to the stack? Can it be installed or acquired a different way? (If you do not have access to the internal JCSDA ZenHub boards you can create a thread on the [JCSDA forums](https://forums.jcsda.org)). Bring it to the attention of the JEDI Software Infrastructure team by "asssigning" or tagging individual members. From 77ce682212f2bbde7f1540248bc4b995b211701c Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 2 Dec 2020 18:20:07 -0700 Subject: [PATCH 024/132] bugfix in pybind11 modulefile --- modulefiles/core/pybind11/pybind11.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/modulefiles/core/pybind11/pybind11.lua b/modulefiles/core/pybind11/pybind11.lua index bd408f2..a87e2f3 100644 --- a/modulefiles/core/pybind11/pybind11.lua +++ b/modulefiles/core/pybind11/pybind11.lua @@ -11,9 +11,10 @@ local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" local base = pathJoin(opt,"core",pkgName,pkgVersion) -prepend_path("PATH", pathJoin(base,"Contents")) +prepend_path("CPATH", pathJoin(base,"include")) -setenv("pybind11_DIR", base) +setenv("pybind11_ROOT", base) +setenv("pybind11_DIR", base,"share","cmake","pybind11") whatis("Name: ".. pkgName) whatis("Version: " .. pkgVersion) From 7c0b3404aabcef5de4f2ca76774240a2692ff9d3 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 2 Dec 2020 18:26:36 -0700 Subject: [PATCH 025/132] bugfix in gsl-lite modulefile --- modulefiles/core/gsl_lite/gsl_lite.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modulefiles/core/gsl_lite/gsl_lite.lua b/modulefiles/core/gsl_lite/gsl_lite.lua index 9c395f8..9e5b4d7 100644 --- a/modulefiles/core/gsl_lite/gsl_lite.lua +++ b/modulefiles/core/gsl_lite/gsl_lite.lua @@ -11,9 +11,10 @@ local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" local base = pathJoin(opt,"core",pkgName,pkgVersion) -prepend_path("PATH", pathJoin(base,"Contents")) +prepend_path("CPATH", pathJoin(base,"include")) setenv("gsl_lite_ROOT", base) +setenv("gsl_lite_DIR", base,"lib","cmake","gsl_lite") whatis("Name: ".. pkgName) whatis("Version: " .. pkgVersion) From f18f34ddac12bfb922a8086a1ab4dfa16d56d7c2 Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Wed, 2 Dec 2020 18:52:02 -0700 Subject: [PATCH 026/132] Update to CGAL-5.1 and fix CMake bug for intel --- buildscripts/build_stack.sh | 2 +- .../libs/CGAL-5.1-intel-fpmodel-flag-fix.patch | 13 +++++++++++++ buildscripts/libs/build_cgal.sh | 11 +++++++++-- modulefiles/core/cgal/cgal.lua | 3 ++- modulefiles/core/eigen/eigen.lua | 2 +- 5 files changed, 26 insertions(+), 5 deletions(-) create mode 100644 buildscripts/libs/CGAL-5.1-intel-fpmodel-flag-fix.patch diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 2d445cf..dc9ea26 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -88,7 +88,7 @@ build_lib BOOST_HDRS boost 1.68.0 headers-only build_lib EIGEN3 eigen 3.3.7 build_lib BUFRLIB bufrlib 11.3.2 build_lib ECBUILD ecbuild jcsda 3.3.2.jcsda3 -build_lib CGAL cgal 5.0.2 +build_lib CGAL cgal 5.1 build_lib GITLFS git-lfs 2.11.0 #---------------------- diff --git a/buildscripts/libs/CGAL-5.1-intel-fpmodel-flag-fix.patch b/buildscripts/libs/CGAL-5.1-intel-fpmodel-flag-fix.patch new file mode 100644 index 0000000..9139991 --- /dev/null +++ b/buildscripts/libs/CGAL-5.1-intel-fpmodel-flag-fix.patch @@ -0,0 +1,13 @@ +diff --git a/Installation/cmake/modules/CGAL_SetupCGALDependencies.cmake b/Installation/cmake/modules/CGAL_SetupCGALDependencies.cmake +index 6590e31f94..55c783f41c 100644 +--- a/Installation/cmake/modules/CGAL_SetupCGALDependencies.cmake ++++ b/Installation/cmake/modules/CGAL_SetupCGALDependencies.cmake +@@ -147,7 +147,7 @@ function(CGAL_setup_CGAL_dependencies target) + if(WIN32) + target_compile_options(${target} ${keyword} "/fp:strict") + else() +- target_compile_options(${target} ${keyword} "-fp-model" "strict") ++ target_compile_options(${target} ${keyword} "SHELL:-fp-model strict") + endif() + elseif(CMAKE_CXX_COMPILER_ID MATCHES "SunPro") + message( STATUS "Using SunPro compiler, using STLPort 4." ) diff --git a/buildscripts/libs/build_cgal.sh b/buildscripts/libs/build_cgal.sh index b65e11e..62ffdc1 100755 --- a/buildscripts/libs/build_cgal.sh +++ b/buildscripts/libs/build_cgal.sh @@ -33,6 +33,7 @@ if $MODULES; then module try-load cmake module try-load boost-headers module try-load zlib + module try-load eigen module list set -x @@ -49,12 +50,18 @@ fi cd $JEDI_STACK_ROOT/${PKGDIR:-"pkg"} software="CGAL-"$version -url="https://github.com/CGAL/cgal/releases/download/releases%2FCGAL-$version/$software-library.tar.xz" +url="https://github.com/CGAL/cgal/releases/download/v$version/$software-library.tar.xz" [[ -d $software ]] || ( $WGET $url; tar -xf $software-library.tar.xz ) [[ ${DOWNLOAD_ONLY} =~ [yYtT] ]] && exit 0 [[ -d $software ]] && cd $software || ( echo "$software does not exist, ABORT!"; exit 1 ) +if [[ $version == "5.1" ]]; then + git apply ${JEDI_STACK_ROOT}/buildscripts/libs/${software}-intel-fpmodel-flag-fix.patch +else + exit 1 +fi + -cmake . -DCMAKE_INSTALL_PREFIX=$prefix +cmake . -DCMAKE_INSTALL_PREFIX=$prefix -DWITH_CGAL_Qt5=0 -DCGAL_DISABLE_GMP=1 -DEIGEN3_INCLUDE_DIR=$EIGEN_ROOT/include VERBOSE=$MAKE_VERBOSE $SUDO make install # generate modulefile from template diff --git a/modulefiles/core/cgal/cgal.lua b/modulefiles/core/cgal/cgal.lua index 6c0911f..b0d45b7 100644 --- a/modulefiles/core/cgal/cgal.lua +++ b/modulefiles/core/cgal/cgal.lua @@ -7,7 +7,8 @@ local pkgNameVer = myModuleFullName() conflict(pkgName) -prereq("boost-headers") +try_load("boost-headers") +try_load("eigen") local opt = os.getenv("OPT") or "/opt/modules" diff --git a/modulefiles/core/eigen/eigen.lua b/modulefiles/core/eigen/eigen.lua index 715d1db..386909a 100644 --- a/modulefiles/core/eigen/eigen.lua +++ b/modulefiles/core/eigen/eigen.lua @@ -7,7 +7,7 @@ local pkgNameVer = myModuleFullName() conflict(pkgName) -try_load("boost_headers") +try_load("boost-headers") local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" From 606c1d5601c9627dc68da37d80df25108658cdde Mon Sep 17 00:00:00 2001 From: mmiesch Date: Mon, 14 Dec 2020 17:01:56 -0700 Subject: [PATCH 027/132] point to how-to document for Mac OSX --- README.md | 10 +++++----- doc/Build.md | 36 ++++++++++-------------------------- doc/Platforms.md | 6 +++++- 3 files changed, 20 insertions(+), 32 deletions(-) diff --git a/README.md b/README.md index a96a766..1651186 100644 --- a/README.md +++ b/README.md @@ -109,18 +109,18 @@ For these reasons, additions to the JEDI stack must first be approved by the JED If you want to add a new library or software package to the jedi-stack you must first do the following: -1. Create a Zenhub issue that describes the reason for the addition. Which JEDI components require it? Why is it beneficial to add to the stack? Can it be installed or acquired a different way? (If you do not have access to the internal JCSDA ZenHub boards you can create a thread on the [JCSDA forums](https://forums.jcsda.org)). Bring it to the attention of the JEDI Software Infrastructure team by "asssigning" or tagging individual members. +1. Create a Zenhub issue that describes the reason for the addition. Which JEDI components require it? Why is it beneficial to add to the stack? Can it be installed or acquired a different way? (If you do not have access to the internal JCSDA ZenHub boards you can create a thread on the [JCSDA forums](https://forums.jcsda.org)). Bring it to the attention of the JEDI Software Infrastructure team (JEDI 1) by "asssigning" or tagging individual members. -2. The issue will be discussed at one or more meetings of the JEDI software infrastructure team. You may be contacted for further information. +2. The issue will be discussed at one or more meetings of the JEDI 1 team, possibly in consultation with the broader JEDI team. You may be contacted for further information. -3. The JEDI software infrastructure Team will either approve or decline the request for an addition to the jedi-stack. You will be informed of the decision through the ZenHub issue (or forum thread) or by other means (e.g. meetings, email, etc). +3. The JEDI 1 Team will either approve or decline the request for an addition to the jedi-stack. You will be informed of the decision through the ZenHub issue (or forum thread) or by other means (e.g. meetings, email, etc). ## Required Code Changes -If your request to add a package to the JEDI stack is approved by the JEDI software infrastructure team, then you can proceed to add it to the jedi-stack with the following code changes: +If your request to add a package to the JEDI stack is approved by the JEDI 1 team, then you can proceed to add it to the jedi-stack with the following code changes: 1. write a new build script in `buildscripts/libs`, using existing scripts as a template 2. define a new control flag and add it to the `choose_modules.sh` and `config_container*` scripts in `buildscripts/config` 3. Add a call to the new build script in `buildscripts/build_stack.sh` 4. Create a new module template at the appropriate place in the `modulefiles` directory, using existing files as a template -5. Add the package to the list of jedi-stack components in the `README.md` file +5. Add the package to the list of jedi-stack components in the (top-level) `README.md` file diff --git a/doc/Build.md b/doc/Build.md index 0147c29..1ebe84d 100644 --- a/doc/Build.md +++ b/doc/Build.md @@ -1,4 +1,4 @@ -# Builing the JEDI Stack +# Building the JEDI Stack Building the JEDI software stack is a **Four-Step process**, as described in the following sections. @@ -10,12 +10,12 @@ This is the most context-dependent part of the build process. How you proceed d Note - you can skip this step and move on to Step 2 if you are building a JEDI software container because all of the required software packages are already built into the jcsda/docker_base container, which you can just pull from Docker Hub. -This step is most important for bare linux/unix systems, as you would get with a new cloud computing instance, a container build, or a virtual machine (e.g. [vagrant](https://www.vagrantup.com)). For such systems, Step 1 consists of running the following script (all paths are relative to the base path of the jedi-stack repository): +This step is most important for bare linux/unix systems, as you would get with a new cloud computing instance or a virtual machine (e.g. [vagrant](https://www.vagrantup.com)). For such systems, Step 1 consists of running the following script (all paths are relative to the base path of the jedi-stack repository): ``` cd buildscripts ./setup_environment.sh ``` -where `` depends on your operating system and the context of the build (for example, if you're in a container or on the cloud or on an HPC system). Examples include `docker-devel` or `ubuntu/18.04`. To see a list of supported options, run the script without any arguments: +where `` depends on your operating system and the context of the build (for example, if you're in a container or on the cloud or on an HPC system). Examples include `ubuntu/18.04` or `gentoo`. To see a list of supported options, run the script without any arguments: ``` ./setup_environment.sh ``` @@ -46,31 +46,15 @@ brew install graphviz brew install sphinx-doc ~~~~~~~~ -If you are building on Mac OSX with Clang, then do not run the `setup_environments.sh` script, and instead use [HomeBrew](https://brew.sh/) to manually install the basic software packages. Follow the instructions at the HomeBrew website for installing HomeBrew itself, then run the following brew commands: -~~~~~~~~ -brew install gcc@7 # install version 7 GNU compilers, don't install version 8 GNU as it - # has known problems with JEDI -brew install lmod -brew install git -brew install git-lfs -brew install git-flow-avh -brew install wget -brew install cmake -brew install doxygen -brew install graphviz - -# brew can be used to install any other basic tools that you want such as tkdiff, gdb, etc. -~~~~~~~~ - -See the [section below](#MacPython) for instructions to install python on the Mac. - -Your Mac should have come with Clang compilers for C and C++ pre-installed, so in this scheme you are adding in GFortran (GNU) for compiling Fortran code. Once you have finished with the brew install commands, make sure to set `JEDI_OPT` in your environment as described below. +If you are building on Mac OSX with Clang, then do not run the `setup_environments.sh` script, and instead use [HomeBrew](https://brew.sh/) to manually install the basic software packages. Homebrew can be also used to install any other basic tools that you want such as tkdiff, gdb, etc. Then [follow the instructions in the jedi-docs howto document for building and running JEDI](https://github.com/JCSDA-internal/jedi-docs/blob/develop/howto/macos/minimum.md). See the [Platform document](#MacPython) for tips on installing python on the Mac. Your Mac should have come with Clang compilers for C and C++ pre-installed, so in this scheme you are adding in GFortran (GNU) for compiling Fortran code. Once you have finished with the brew install commands, make sure to set `JEDI_OPT` in your environment as described below. If you're on an HPC system you can largely skip this step (but you still need to set the **JEDI_OPT** environment variable, see below) because most of these packages are probably already installed and available. However, there are a few items that you may wish to add by loading the appropriate modules (if they exist) - for example: ``` module load doxygen git-lfs ``` -Note, however, if you are using [JEDI Modules](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/developer/jedi_environment/modules.html) you do not have to worry about this (or indeed, about this repository in general) - the JEDI team will make sure that the modules provided will include the packages you need. +Some modules such as doxygen are optional so if they are not available then no need to worry. However, if `git-lfs` is not available, you can install it using the build script that is provided in jedi-stack. + +Note, however, if you are using [JEDI Modules](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/developer/jedi_environment/modules.html) you do not have to worry about this (or indeed, about this jedi-stack repository in general) - the JEDI team will make sure that the modules provided will include the packages you need. **IMPORTANT:** Another responsibility of the `setup_environment.sh` script is to define the `JEDI_OPT` environment variable and initialize the Lmod system. These actions are needed both for the build and to allow users to load the JEDI modules after you build them. `JEDI_OPT` specifies where the modules will be installed, with a default value of `JEDI_OPT=/opt/modules`. Note that this default value normally requires root permission so you would have to set the `USE_SUDO` flag (see Step 2). If you do not have root privileges (e.g. on an HPC system), you may wish to install your modules in a home or work directory, e.g. `JEDI_OPT=$HOME/opt/modules`. @@ -87,13 +71,13 @@ and make sure these settings are in place before proceeding to Steps 2-4. ## Step 2: Configure Build -The next step is to choose what components of the stack you wish to build and to specify any other aspects of the build that you would like. This is normally done by editing one of the platform-specific `buildscripts/config/config_*.sh` files. Or, if your platform is not among the options, you can edit the `config_custom.sh` file. Then, edit the `buildscripts/config/choose_modules.sh` file to choose which modules you wish to build. Note that some are prerequisites of others. For example, you must build hdf5 before you build netcdf. +The next step is to choose what components of the stack you wish to build and to specify any other aspects of the build that you would like. This is normally done by first editing one of the platform-specific `buildscripts/config/config_*.sh` files. Or, if your platform is not among the options, you can edit the `config_custom.sh` file. Then, edit the `buildscripts/config/choose_modules.sh` file to choose which modules you wish to build. Note that some are prerequisites of others. For example, you must build hdf5 before you build netcdf. Here we describe some of the parameter settings available in these configuration files. For building on Mac OSX, a configuration file (`config_mac.sh`) is provided. This configuration is set up to build using Clang 10.0.0 with gfortran and OpenMPI. You may wish to edit this file for building with a different compiler/mpi set. -For building on an EMC RHEL7 workstation, a configuration file (`config_rhel7emc.sh`) is provided. This . +For building on an EMC RHEL7 workstation, a configuration file (`config_rhel7emc.sh`) is provided. **JEDI_COMPILER** This defines the vendor and version of the compiler you wish to use for this build. The format is the same as what you would typically use in a module load command: ``` @@ -103,7 +87,7 @@ For example, `COMPILER=gnu/7.3.0`. **JEDI_MPI** is the MPI library you wish to use for this build. The format is the same as for `COMPILER`, for example: `export MPI=openmpi/3.1.2`. -**PREFIX** is the directory where the software packages will be installed. Normally this is set to be the same as the `JEDI_OPT` environment variable (default value `/opt/modules`), though this is not required. If `JEDI_OPT` and `PREFIX` are both the same, then the software installation trees (the top level of each being is the compiler, e.g. `gnu-7.3.0`) will branch directly off of `$JEDI_OPT` while the module files will be located in the `modulefiles subdirectory. +**PREFIX** is the directory where the software packages will be installed. Normally this is set to be the same as the `JEDI_OPT` environment variable (default value `/opt/modules`), though this is not required. If `JEDI_OPT` and `PREFIX` are both the same, then the software installation trees (the top level of each being is the compiler, e.g. `gnu-7.3.0`) will branch directly off of `$JEDI_OPT` while the module files will be located in the `modulefiles` subdirectory. **USE_SUDO** If `PREFIX` is set to a value that requires root permission to write to, such as `/opt/modules`, then this flag should be enabled. diff --git a/doc/Platforms.md b/doc/Platforms.md index d0daac3..55e87b3 100644 --- a/doc/Platforms.md +++ b/doc/Platforms.md @@ -2,7 +2,11 @@ Here are are tips for building the jedi-stack on particular Platforms -## Setting up python for Mac OSX +## Mac OSX + +The procedure for setting up a minimial JEDI stack on Mac OSX is described in [a separate how-to document in jedi-docs](https://github.com/JCSDA-internal/jedi-docs/blob/develop/howto/macos/minimum.md). + +#### Setting up python for Mac OSX It is recommended for now to skip the automatic build of the pyjedi package. This has been shut off by default in the mac configuration file. It is also recommended to use miniconda for python2 and python3. For miniconda, get the downloads on the site: https://docs.conda.io/en/latest/miniconda.html. Select the 64-bit bash installer for both python 2.7 and 3.7. These each download a script to install miniconda on your Mac. Run each script as: From 677175b15514a62314419ade6c46e8553881addb Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 15 Dec 2020 10:32:11 -0700 Subject: [PATCH 028/132] update config files --- buildscripts/config/choose_modules.sh | 2 +- buildscripts/config/config_container-clang-mpich-dev.sh | 6 +++--- buildscripts/config/config_container-gnu-openmpi-dev.sh | 6 +++--- buildscripts/config/config_container-intel-impi-app.sh | 4 +++- buildscripts/config/config_container-intel-impi-dev.sh | 6 +++--- 5 files changed, 13 insertions(+), 11 deletions(-) diff --git a/buildscripts/config/choose_modules.sh b/buildscripts/config/choose_modules.sh index 34f6c5e..25721ec 100644 --- a/buildscripts/config/choose_modules.sh +++ b/buildscripts/config/choose_modules.sh @@ -22,13 +22,13 @@ export STACK_BUILD_ECKIT=Y export STACK_BUILD_FCKIT=N export STACK_BUILD_ATLAS=N export STACK_BUILD_GSL_LITE=Y +export STACK_BUILD_PYJEDI=Y # Optional Additions export STACK_BUILD_ODC=N export STACK_BUILD_PIO=Y export STACK_BUILD_GPTL=N export STACK_BUILD_NCO=N -export STACK_BUILD_PYJEDI=N export STACK_BUILD_PYBIND11=N export STACK_BUILD_NCEPLIBS=N export STACK_BUILD_JPEG=N diff --git a/buildscripts/config/config_container-clang-mpich-dev.sh b/buildscripts/config/config_container-clang-mpich-dev.sh index 8113863..32be280 100644 --- a/buildscripts/config/config_container-clang-mpich-dev.sh +++ b/buildscripts/config/config_container-clang-mpich-dev.sh @@ -56,14 +56,14 @@ export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y export STACK_BUILD_FCKIT=N export STACK_BUILD_ATLAS=N -export STACK_BUILD_ODC=N +export STACK_BUILD_PYBIND11=Y +export STACK_BUILD_GSL_LITE=Y # Optional Additions +export STACK_BUILD_ODC=N export STACK_BUILD_PIO=Y export STACK_BUILD_GPTL=N export STACK_BUILD_PYJEDI=Y -export STACK_BUILD_PYBIND11=Y -export STACK_BUILD_GSL_LITE=Y export STACK_BUILD_NCEPLIBS=N export STACK_BUILD_JPEG=N export STACK_BUILD_PNG=N diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index cc841a5..b652a52 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -56,14 +56,14 @@ export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y export STACK_BUILD_FCKIT=N export STACK_BUILD_ATLAS=N -export STACK_BUILD_ODC=N +export STACK_BUILD_PYBIND11=Y +export STACK_BUILD_GSL_LITE=Y # Optional Additions +export STACK_BUILD_ODC=N export STACK_BUILD_PIO=Y export STACK_BUILD_GPTL=N export STACK_BUILD_PYJEDI=Y -export STACK_BUILD_PYBIND11=Y -export STACK_BUILD_GSL_LITE=Y export STACK_BUILD_NCEPLIBS=N export STACK_BUILD_JPEG=N export STACK_BUILD_PNG=N diff --git a/buildscripts/config/config_container-intel-impi-app.sh b/buildscripts/config/config_container-intel-impi-app.sh index 1663d01..c82136e 100644 --- a/buildscripts/config/config_container-intel-impi-app.sh +++ b/buildscripts/config/config_container-intel-impi-app.sh @@ -61,9 +61,11 @@ export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y export STACK_BUILD_FCKIT=N export STACK_BUILD_ATLAS=N -export STACK_BUILD_ODC=N +export STACK_BUILD_PYBIND11=Y +export STACK_BUILD_GSL_LITE=Y # Optional Additions +export STACK_BUILD_ODC=N export STACK_BUILD_PIO=N export STACK_BUILD_PYJEDI=N export STACK_BUILD_NCEPLIBS=N diff --git a/buildscripts/config/config_container-intel-impi-dev.sh b/buildscripts/config/config_container-intel-impi-dev.sh index 0a098e7..d72e752 100644 --- a/buildscripts/config/config_container-intel-impi-dev.sh +++ b/buildscripts/config/config_container-intel-impi-dev.sh @@ -61,14 +61,14 @@ export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y export STACK_BUILD_FCKIT=N export STACK_BUILD_ATLAS=N -export STACK_BUILD_ODC=N +export STACK_BUILD_PYBIND11=Y +export STACK_BUILD_GSL_LITE=Y # Optional Additions +export STACK_BUILD_ODC=N export STACK_BUILD_PIO=Y export STACK_BUILD_GPTL=N export STACK_BUILD_PYJEDI=Y -export STACK_BUILD_PYBIND11=Y -export STACK_BUILD_GSL_LITE=Y export STACK_BUILD_NCEPLIBS=N export STACK_BUILD_JPEG=N export STACK_BUILD_PNG=N From a5519b980a3c72e8aeb694378b465c1c6fae4278 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 15 Dec 2020 10:39:21 -0700 Subject: [PATCH 029/132] fix error - pybind is required, not pyjedi --- buildscripts/config/choose_modules.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/buildscripts/config/choose_modules.sh b/buildscripts/config/choose_modules.sh index 25721ec..f40b852 100644 --- a/buildscripts/config/choose_modules.sh +++ b/buildscripts/config/choose_modules.sh @@ -22,14 +22,14 @@ export STACK_BUILD_ECKIT=Y export STACK_BUILD_FCKIT=N export STACK_BUILD_ATLAS=N export STACK_BUILD_GSL_LITE=Y -export STACK_BUILD_PYJEDI=Y +export STACK_BUILD_PYBIND11=Y # Optional Additions export STACK_BUILD_ODC=N export STACK_BUILD_PIO=Y export STACK_BUILD_GPTL=N export STACK_BUILD_NCO=N -export STACK_BUILD_PYBIND11=N +export STACK_BUILD_PYJEDI=Y export STACK_BUILD_NCEPLIBS=N export STACK_BUILD_JPEG=N export STACK_BUILD_PNG=N From 9c9bb575a543d355cb9c22bda2a552e68a36022e Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 15 Dec 2020 10:57:11 -0700 Subject: [PATCH 030/132] bugfix --- doc/Build.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/Build.md b/doc/Build.md index 1ebe84d..2275976 100644 --- a/doc/Build.md +++ b/doc/Build.md @@ -2,7 +2,7 @@ Building the JEDI software stack is a **Four-Step process**, as described in the following sections. -[See here for additional tips on particular platforms](doc/Platforms.md) +[See here for additional tips on particular platforms](Platforms.md) ## Step 1: Set up Basic Environment @@ -148,4 +148,4 @@ Here `` is the same as in Step 3, namely a reference to the corre For building on Mac OSX, use: ~~~~~~~~ ./build_stack.sh mac -~~~~~~~~ \ No newline at end of file +~~~~~~~~ From 53d9d63585fb750a2d3a2e58957410abdd593aaa Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 15 Dec 2020 11:04:42 -0700 Subject: [PATCH 031/132] fix link --- doc/Build.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/Build.md b/doc/Build.md index 2275976..694af50 100644 --- a/doc/Build.md +++ b/doc/Build.md @@ -54,7 +54,7 @@ module load doxygen git-lfs ``` Some modules such as doxygen are optional so if they are not available then no need to worry. However, if `git-lfs` is not available, you can install it using the build script that is provided in jedi-stack. -Note, however, if you are using [JEDI Modules](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/developer/jedi_environment/modules.html) you do not have to worry about this (or indeed, about this jedi-stack repository in general) - the JEDI team will make sure that the modules provided will include the packages you need. +Note, however, if you are using [JEDI Modules](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/using/jedi_environment/modules.html) you do not have to worry about this (or indeed, about this jedi-stack repository in general) - the JEDI team will make sure that the modules provided will include the packages you need. **IMPORTANT:** Another responsibility of the `setup_environment.sh` script is to define the `JEDI_OPT` environment variable and initialize the Lmod system. These actions are needed both for the build and to allow users to load the JEDI modules after you build them. `JEDI_OPT` specifies where the modules will be installed, with a default value of `JEDI_OPT=/opt/modules`. Note that this default value normally requires root permission so you would have to set the `USE_SUDO` flag (see Step 2). If you do not have root privileges (e.g. on an HPC system), you may wish to install your modules in a home or work directory, e.g. `JEDI_OPT=$HOME/opt/modules`. From 90a9d7b6affd7af68614e1aa59a53ca32acfe6d7 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 15 Dec 2020 11:23:55 -0700 Subject: [PATCH 032/132] add bin and include to modulefile --- modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua b/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua index 9f80bf2..cf3d312 100644 --- a/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua +++ b/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua @@ -15,6 +15,8 @@ local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" local base = pathJoin(opt,compNameVerD,pkgName,pkgVersion) +prepend_path("PATH", pathJoin(base,"bin")) +prepend_path("CPATH", pathJoin(base,"include")) prepend_path("LD_LIBRARY_PATH", pathJoin(base,"lib")) prepend_path("DYLD_LIBRARY_PATH", pathJoin(base,"lib")) prepend_path("LIBRARY_PATH", pathJoin(base,"lib")) From 4e9f8121066c03371b4fd2f55261a7be2bff27ff Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 15 Dec 2020 11:47:58 -0700 Subject: [PATCH 033/132] remove python2 --- doc/Platforms.md | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/doc/Platforms.md b/doc/Platforms.md index 55e87b3..4bf1ca7 100644 --- a/doc/Platforms.md +++ b/doc/Platforms.md @@ -7,17 +7,16 @@ Here are are tips for building the jedi-stack on particular Platforms The procedure for setting up a minimial JEDI stack on Mac OSX is described in [a separate how-to document in jedi-docs](https://github.com/JCSDA-internal/jedi-docs/blob/develop/howto/macos/minimum.md). #### Setting up python for Mac OSX -It is recommended for now to skip the automatic build of the pyjedi package. This has been shut off by default in the mac configuration file. It is also recommended to use miniconda for python2 and python3. +It is recommended for now to skip the automatic build of the pyjedi package. This has been shut off by default in the mac configuration file. It is also recommended to use miniconda for python3. -For miniconda, get the downloads on the site: https://docs.conda.io/en/latest/miniconda.html. Select the 64-bit bash installer for both python 2.7 and 3.7. These each download a script to install miniconda on your Mac. Run each script as: +For miniconda, get the downloads on the site: https://docs.conda.io/en/latest/miniconda.html. Select the 64-bit bash installer for 3.7. These each download a script to install miniconda on your Mac. Run each script as: ~~~~~~~ -sh Miniconda2-latest-MacOSX-x86_64.sh sh Miniconda3-latest-MacOSX-x86_64.sh ~~~~~~~ -When prompted allow the install to go into your home directory, and allow the script to modify your .bash_profile file. Edit your .bash_profile file and make sure that your PATH is being set the way you want it. Keep in mind that for now the ODB API python interface only works with python 2.7 (so you should make sure that "python" will be found in your miniconda2 area). +When prompted allow the install to go into your home directory, and allow the script to modify your .bash_profile file. Edit your .bash_profile file and make sure that your PATH is being set the way you want it. -Once you have miniconda2 and 3 installed, run the conda command to install extra python packages you will need for JEDI. For both miniconda2 and 3, run: +Once you have miniconda3 installed, run the conda command to install extra python packages you will need for JEDI. Now run: ~~~~~~~ conda install setuptools conda install wheel @@ -32,10 +31,9 @@ conda install pyyaml conda install sphinx ~~~~~~~ -Then, build the ncepbufr python packages. Again for both miniconda2 and 3, run: +Then, build the ncepbufr python packages. Run: ~~~~~~~ -git clone https://github.com/JCSDA/py-ncepbufr.git # Only need to do this once. The build/install processes for both - # python2 and 3 can be run from the same clone of py-ncepbufr. +git clone https://github.com/JCSDA/py-ncepbufr.git # Only need to do this once. cd py-ncepbufr python setup.py build From e6975b52ed34986b32e975ede2f0667fc2fe23e3 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 15 Dec 2020 11:50:39 -0700 Subject: [PATCH 034/132] JCSDA-internal for py-ncepbufr --- doc/Platforms.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/Platforms.md b/doc/Platforms.md index 4bf1ca7..8ce6e5b 100644 --- a/doc/Platforms.md +++ b/doc/Platforms.md @@ -33,7 +33,7 @@ conda install sphinx Then, build the ncepbufr python packages. Run: ~~~~~~~ -git clone https://github.com/JCSDA/py-ncepbufr.git # Only need to do this once. +git clone https://github.com/JCSDA-internal/py-ncepbufr.git # Only need to do this once. cd py-ncepbufr python setup.py build From 09ea6b8b60051fe66916f5ca115fcaa72b5829be Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 15 Dec 2020 13:31:51 -0700 Subject: [PATCH 035/132] turn BUFR on for intel app container --- buildscripts/config/config_container-intel-impi-app.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/config/config_container-intel-impi-app.sh b/buildscripts/config/config_container-intel-impi-app.sh index a17b017..d3c8328 100644 --- a/buildscripts/config/config_container-intel-impi-app.sh +++ b/buildscripts/config/config_container-intel-impi-app.sh @@ -52,7 +52,7 @@ export STACK_BUILD_LAPACK=N export STACK_BUILD_BOOST_HDRS=Y export STACK_BUILD_EIGEN3=Y export STACK_BUILD_BUFRLIB=N -export STACK_BUILD_BUFR=N +export STACK_BUILD_BUFR=Y export STACK_BUILD_HDF5=Y export STACK_BUILD_PNETCDF=Y export STACK_BUILD_NETCDF=Y From b5872154a989d09f0467e439b97b2de36bbb3def Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 15 Dec 2020 14:17:18 -0700 Subject: [PATCH 036/132] add PYTHONPATH --- modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua b/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua index cf3d312..4023696 100644 --- a/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua +++ b/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua @@ -20,6 +20,7 @@ prepend_path("CPATH", pathJoin(base,"include")) prepend_path("LD_LIBRARY_PATH", pathJoin(base,"lib")) prepend_path("DYLD_LIBRARY_PATH", pathJoin(base,"lib")) prepend_path("LIBRARY_PATH", pathJoin(base,"lib")) +prepend_path("PYTHONPATH", pathJoin(base,"lib/python3.8/site-packages")) setenv("bufr_VERSION", pkgVersion) setenv("bufr_ROOT", base) -- CMake find_package(bufr) From 4af5aa17927231470859895f83a73108029bc436 Mon Sep 17 00:00:00 2001 From: Stephen Herbener Date: Wed, 16 Dec 2020 12:25:58 -0700 Subject: [PATCH 037/132] Added capability to substitute a python version number into a lua script. Useful for setting PYTHONPATH in the lua script. --- buildscripts/libs/build_bufr.sh | 3 ++- buildscripts/libs/update_modules.sh | 9 +++++++++ .../compiler/compilerName/compilerVersion/bufr/bufr.lua | 2 +- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/buildscripts/libs/build_bufr.sh b/buildscripts/libs/build_bufr.sh index 4a70859..d1b43e2 100755 --- a/buildscripts/libs/build_bufr.sh +++ b/buildscripts/libs/build_bufr.sh @@ -63,5 +63,6 @@ VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install # generate modulefile from template -$MODULES && update_modules compiler $name $source-$version \ +pythonVersion="$(python --version | cut -d " " -f2 | cut -d. -f1-2)" +$MODULES && update_modules compiler $name $source-$version $pythonVersion \ || echo $name $source-$version >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log diff --git a/buildscripts/libs/update_modules.sh b/buildscripts/libs/update_modules.sh index bc91e91..0981d38 100755 --- a/buildscripts/libs/update_modules.sh +++ b/buildscripts/libs/update_modules.sh @@ -10,6 +10,12 @@ # $1 = module path: valid options are core, compiler, or mpi # $2 = package name # $3 = package version +# $4 = python version (optional) +# +# Only specify the python version if you need to set that in the destination +# lua script. A non-empty setting of $4 will cause sed to be run on the +# destination lua script to substitue "@PYTHON_VERSION@" with the python version +# number specified in $4. function update_modules { OPT="${JEDI_OPT:-$OPT}" @@ -33,6 +39,9 @@ function update_modules { cd $to_dir $SUDO mkdir -p $2; cd $2 $SUDO cp $tmpl_file $3.lua + # Argument number 4 is python version. If not empty use sed to + # substitue python version into placeholder marks in the lua script. + [[ -n "$4" ]] && $SUDO sed -i "" -e "s/@PYTHON_VERSION@/$4/" $3.lua # Make the latest installed version the default [[ -e default ]] && $SUDO rm -f default diff --git a/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua b/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua index 4023696..1d29df0 100644 --- a/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua +++ b/modulefiles/compiler/compilerName/compilerVersion/bufr/bufr.lua @@ -20,7 +20,7 @@ prepend_path("CPATH", pathJoin(base,"include")) prepend_path("LD_LIBRARY_PATH", pathJoin(base,"lib")) prepend_path("DYLD_LIBRARY_PATH", pathJoin(base,"lib")) prepend_path("LIBRARY_PATH", pathJoin(base,"lib")) -prepend_path("PYTHONPATH", pathJoin(base,"lib/python3.8/site-packages")) +prepend_path("PYTHONPATH", pathJoin(base,"lib/python@PYTHON_VERSION@/site-packages")) setenv("bufr_VERSION", pkgVersion) setenv("bufr_ROOT", base) -- CMake find_package(bufr) From c8bbeb78fd8a03625578745907d403a32beb74d4 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 16 Dec 2020 17:55:37 -0700 Subject: [PATCH 038/132] add intel oneapi config file --- .../config_container-intel-oneapi-dev.sh | 87 +++++++++++++++++++ 1 file changed, 87 insertions(+) create mode 100644 buildscripts/config/config_container-intel-oneapi-dev.sh diff --git a/buildscripts/config/config_container-intel-oneapi-dev.sh b/buildscripts/config/config_container-intel-oneapi-dev.sh new file mode 100644 index 0000000..7cc060e --- /dev/null +++ b/buildscripts/config/config_container-intel-oneapi-dev.sh @@ -0,0 +1,87 @@ +#!/bin/bash +# © Copyright 2020 UCAR +# This software is licensed under the terms of the Apache Licence Version 2.0 which can be obtained at +# http://www.apache.org/licenses/LICENSE-2.0. + + +# Compiler/MPI combination +export JEDI_COMPILER="intel/19.1.0" +export JEDI_MPI="impi/19.1.0" +source /etc/profile +export PATH=/usr/local/bin:$PATH +export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH +export LIBRARY_PATH=/usr/local/lib:$LIBRARY_PATH +export CPATH=/usr/local/include:$CPATH + +# This tells jedi-stack how you want to build the compiler and mpi modules +# valid options include: +# native-module: load a pre-existing module (common for HPC systems) +# native-pkg: use pre-installed executables located in /usr/bin or /usr/local/bin, +# as installed by package managers like apt-get or hombrewo. +# This is a common option for, e.g., gcc/g++/gfortran +# from-source: This is to build from source +export COMPILER_BUILD="native-pkg" +export MPI_BUILD="native-pkg" + +# Build options +export PREFIX=/usr/local +export USE_SUDO=N +export PKGDIR=pkg +export LOGDIR=buildscripts/log +export OVERWRITE=N +export NTHREADS=4 +export MAKE_CHECK=N +export MAKE_VERBOSE=Y +export MAKE_CLEAN=Y +export DOWNLOAD_ONLY=F +export STACK_EXIT_ON_FAIL=T +export WGET="wget -nv" +#Global compiler flags +export FFLAGS="" +export CFLAGS="" +export CXXFLAGS="" +export LDFLAGS="" + +# Minimal JEDI Stack +export STACK_BUILD_CMAKE=N +export STACK_BUILD_GITLFS=N +export STACK_BUILD_SZIP=Y +export STACK_BUILD_UDUNITS=Y +export STACK_BUILD_ZLIB=Y +export STACK_BUILD_LAPACK=N +export STACK_BUILD_BOOST_HDRS=Y +export STACK_BUILD_EIGEN3=Y +export STACK_BUILD_BUFRLIB=N +export STACK_BUILD_HDF5=Y +export STACK_BUILD_PNETCDF=Y +export STACK_BUILD_NETCDF=Y +export STACK_BUILD_NCCMP=Y +export STACK_BUILD_NCO=N +export STACK_BUILD_ECBUILD=Y +export STACK_BUILD_ECKIT=Y +export STACK_BUILD_FCKIT=N +export STACK_BUILD_ATLAS=N +export STACK_BUILD_PYBIND11=Y +export STACK_BUILD_GSL_LITE=Y + +# Optional Additions +export STACK_BUILD_ODC=N +export STACK_BUILD_PIO=Y +export STACK_BUILD_GPTL=N +export STACK_BUILD_PYJEDI=Y +export STACK_BUILD_NCEPLIBS=N +export STACK_BUILD_JPEG=N +export STACK_BUILD_PNG=N +export STACK_BUILD_JASPER=N +export STACK_BUILD_ARMADILLO=N +export STACK_BUILD_XERCES=N +export STACK_BUILD_TKDIFF=N +export STACK_BUILD_BOOST_FULL=N +export STACK_BUILD_ESMF=N +export STACK_BUILD_BASELIBS=N +export STACK_BUILD_PDTOOLKIT=N +export STACK_BUILD_TAU2=N +export STACK_BUILD_CGAL=N +export STACK_BUILD_JSON=Y +export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y +export STACK_BUILD_FMS=N From 19aef071350b54d3b7c0458b312b511fecf20fcf Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 16 Dec 2020 18:18:11 -0700 Subject: [PATCH 039/132] update intel version for container --- buildscripts/config/config_container-intel-oneapi-dev.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/buildscripts/config/config_container-intel-oneapi-dev.sh b/buildscripts/config/config_container-intel-oneapi-dev.sh index 7cc060e..2116b77 100644 --- a/buildscripts/config/config_container-intel-oneapi-dev.sh +++ b/buildscripts/config/config_container-intel-oneapi-dev.sh @@ -5,8 +5,8 @@ # Compiler/MPI combination -export JEDI_COMPILER="intel/19.1.0" -export JEDI_MPI="impi/19.1.0" +export JEDI_COMPILER="intel/2021.1" +export JEDI_MPI="impi/2021.1" source /etc/profile export PATH=/usr/local/bin:$PATH export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH From cb2496a3c67a8e192d6acbee40aa23f738582789 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Thu, 17 Dec 2020 10:10:39 -0700 Subject: [PATCH 040/132] bugfix in cgal modulefile --- modulefiles/core/cgal/cgal.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modulefiles/core/cgal/cgal.lua b/modulefiles/core/cgal/cgal.lua index 6c0911f..0e1df15 100644 --- a/modulefiles/core/cgal/cgal.lua +++ b/modulefiles/core/cgal/cgal.lua @@ -9,7 +9,7 @@ conflict(pkgName) prereq("boost-headers") -local opt = os.getenv("OPT") or "/opt/modules" +local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" local base = pathJoin(opt,"core",pkgName,pkgVersion) From 98b9a8f14d807c3129ca00ebcf1af5e3f048aba0 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Thu, 17 Dec 2020 16:01:37 -0700 Subject: [PATCH 041/132] get ecmwf forks from jcsda-internal --- buildscripts/build_stack.sh | 12 ++++++------ .../config/config_container-intel-oneapi-dev.sh | 1 - 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 6004303..c032a27 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -86,8 +86,8 @@ build_lib SZIP szip 2.1.1 build_lib LAPACK lapack 3.8.0 build_lib BOOST_HDRS boost 1.68.0 headers-only build_lib EIGEN3 eigen 3.3.7 -build_lib BUFR bufr jcsda 11.4.0.jcsda1 -build_lib ECBUILD ecbuild jcsda 3.3.2.jcsda3 +build_lib BUFR bufr jcsda-internal 11.4.0.jcsda1 +build_lib ECBUILD ecbuild jcsda-internal 3.3.2.jcsda3 build_lib CGAL cgal 5.0.2 build_lib GITLFS git-lfs 2.11.0 @@ -97,11 +97,11 @@ build_lib HDF5 hdf5 1.12.0 build_lib PNETCDF pnetcdf 1.12.1 build_lib NETCDF netcdf 4.7.4 4.5.3 4.3.0 build_lib NCCMP nccmp 1.8.7.0 -build_lib ECKIT eckit jcsda 1.11.6.jcsda2 -build_lib FCKIT fckit jcsda 0.7.0.jcsda1 -build_lib ATLAS atlas jcsda 0.20.2.jcsda1 +build_lib ECKIT eckit jcsda-internal 1.11.6.jcsda2 +build_lib FCKIT fckit jcsda-internal 0.7.0.jcsda1 +build_lib ATLAS atlas jcsda-internal 0.20.2.jcsda1 build_lib ODB odb 0.18.1.r2 -build_lib ODC odc jcsda 1.0.3 +build_lib ODC odc jcsda-internal 1.0.3 # =============================================================================== # Optional Extensions to the JEDI Stack diff --git a/buildscripts/config/config_container-intel-oneapi-dev.sh b/buildscripts/config/config_container-intel-oneapi-dev.sh index 2116b77..94f4996 100644 --- a/buildscripts/config/config_container-intel-oneapi-dev.sh +++ b/buildscripts/config/config_container-intel-oneapi-dev.sh @@ -7,7 +7,6 @@ # Compiler/MPI combination export JEDI_COMPILER="intel/2021.1" export JEDI_MPI="impi/2021.1" -source /etc/profile export PATH=/usr/local/bin:$PATH export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH export LIBRARY_PATH=/usr/local/lib:$LIBRARY_PATH From c4d961ee4bd10ec644bde4fba8cf9120a4d357c0 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Sat, 19 Dec 2020 16:18:51 -0700 Subject: [PATCH 042/132] Initial commit for building ecFlow as a module --- buildscripts/build_stack.sh | 1 + buildscripts/config/choose_modules.sh | 1 + buildscripts/libs/build_boost.sh | 9 ++- buildscripts/libs/build_ecflow.sh | 74 +++++++++++++++++++ .../compilerVersion/ecflow/ecflow.lua | 32 ++++++++ 5 files changed, 116 insertions(+), 1 deletion(-) create mode 100755 buildscripts/libs/build_ecflow.sh create mode 100644 modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 6004303..3dc7ee7 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -121,6 +121,7 @@ build_lib SQLITE sqlite 3.32.3 build_lib PROJ proj 7.1.0 build_lib JSON json 3.9.1 build_lib JSON_SCHEMA_VALIDATOR json-schema-validator 2.1.0 +build_lib ECFLOW ecflow ecmwf 5.5.3 #---------------------- # These must be rebuilt for each MPI implementation diff --git a/buildscripts/config/choose_modules.sh b/buildscripts/config/choose_modules.sh index c8a15c8..eeec9fd 100644 --- a/buildscripts/config/choose_modules.sh +++ b/buildscripts/config/choose_modules.sh @@ -50,3 +50,4 @@ export STACK_BUILD_PROJ=N export STACK_BUILD_FMS=N export STACK_BUILD_JSON=N export STACK_BUILD_JSON_SCHEMA_VALIDATOR=N +export STACK_BUILD_ECFLOW=N diff --git a/buildscripts/libs/build_boost.sh b/buildscripts/libs/build_boost.sh index 1661596..dd4be14 100755 --- a/buildscripts/libs/build_boost.sh +++ b/buildscripts/libs/build_boost.sh @@ -70,6 +70,7 @@ compName=$(echo $compiler | cut -d- -f1) case "$compName" in gnu ) MPICC=$(which mpicc) ; toolset=gcc ;; intel ) MPICC=$(which mpiicc) ; toolset=intel ;; + clang ) MPICC=$(which mpiicc) ; toolset=clang ;; * ) echo "Unknown compiler = $compName, ABORT!"; exit 1 ;; esac @@ -85,7 +86,13 @@ EOF rm -f $HOME/user-config.jam [[ -z $mpi ]] && rm -f ./user-config.jam || mv -f ./user-config.jam $HOME -./bootstrap.sh --with-toolset=$toolset +# boost python libraries may not build without these values exported +pyInc=`python3-config --includes | cut -d' ' -f1` +# echo $pyInc +export C_INCLUDE_PATH=$C_INCLUDE_PATH:$pyInc +export CPLUS_INCLUDE_PATH=$CPLUS_INCLUDE_PATH:$pyInc + +./bootstrap.sh --with-toolset=$toolset --with-python=`which python3` ./b2 install $debug --prefix=$BoostBuild export PATH="$BoostBuild/bin:$PATH" diff --git a/buildscripts/libs/build_ecflow.sh b/buildscripts/libs/build_ecflow.sh new file mode 100755 index 0000000..ca56ffa --- /dev/null +++ b/buildscripts/libs/build_ecflow.sh @@ -0,0 +1,74 @@ +#!/bin/bash +# © Copyright 2020 UCAR +# This software is licensed under the terms of the Apache Licence Version 2.0 which can be obtained at +# http://www.apache.org/licenses/LICENSE-2.0. + +set -x + +name="ecflow" +source=$1 +version=$2 + +software=$name +cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} +[[ -d $software ]] || git clone https://github.com/$source/$software.git +[[ ${DOWNLOAD_ONLY} =~ [yYtT] ]] && exit 0 +[[ -d $software ]] && cd $software || ( echo "$software does not exist, ABORT!"; exit 1 ) +git fetch --tags +git checkout $version + +ecflow_version=$(awk '/^project/ && /ecflow/ && /VERSION/ {for (I=1;I<=NF;I++) if ($I == "VERSION") {print $(I+1)};}' CMakeLists.txt) + +# Hyphenated version used for install prefix +compiler=$(echo $JEDI_COMPILER | sed 's/\//-/g') + +software=$name\_$(echo $ecflow_version | sed 's/\./_/g') + +if $MODULES; then + set +x + source $MODULESHOME/init/bash + module load jedi-$JEDI_COMPILER + module load jedi-$JEDI_MPI + module try-load cmake git python qt + module load boost + module list + set -x + + prefix="${PREFIX:-"/opt/modules"}/$compiler/$name/$ecflow_version" + if [[ -d $prefix ]]; then + [[ $OVERWRITE =~ [yYtT] ]] && ( echo "WARNING: $prefix EXISTS: OVERWRITING!";$SUDO rm -rf $prefix ) \ + || ( echo "WARNING: $prefix EXISTS, SKIPPING"; exit 1 ) + fi +else + prefix=${ECFLOW_ROOT:-"/usr/local"} +fi + +export FC=$SERIAL_FC +export CC=$SERIAL_CC +export CXX=$SERIAL_CXX + +[[ -d build ]] && $SUDO rm -rf build +mkdir -p build && cd build + +host=$(uname -s) +if [[ "$host" == "Darwin" ]] +then + export OPENSSL_ROOT_DIR=`brew --prefix openssl` + export OPENSSL_INCLUDE_DIR=$OPENSSL_ROOT_DIR/include + export QT=`brew --prefix qt` + QT_LOC="-DCMAKE_PREFIX_PATH=$QT" +fi + +cmake -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release -DENABLE_STATIC_BOOST_LIBS=OFF $QT_LOC \ + -DENABLE_STATIC_BOOST_LIBS=OFF .. +VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} +VERBOSE=$MAKE_VERBOSE $SUDO make install + +# update rpath that macOS frameworks install if mixing python frameworks (which is a bad idea) +# install_name_tool -change @rpath/Python3.framework/Versions/3.8/Python3 \ +# /Library/Frameworks/Python.framework/Versions/3.8/Python \ +# /Users/grubin/opt/modules/gnu-10.2.0/ecflow/5.5.3/lib/python3.8/site-packages/ecflow/ecflow.so + +# generate modulefile from template +$MODULES && update_modules compiler $name $ecflow_version \ + || echo $name $ecflow_version >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log diff --git a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua new file mode 100644 index 0000000..996168f --- /dev/null +++ b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua @@ -0,0 +1,32 @@ +help([[ +]]) + +local pkgName = myModuleName() +local pkgVersion = myModuleVersion() +local pkgNameVer = myModuleFullName() + +local hierA = hierarchyA(pkgNameVer,1) +local compNameVer = hierA[1] +local compNameVerD = compNameVer:gsub("/","-") + +conflict(pkgName) + +local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" + +local base = pathJoin(opt,compNameVerD,pkgName,pkgVersion) + +prepend_path("PATH", pathJoin(base,"bin")) +prepend_path("LD_LIBRARY_PATH", pathJoin(base,"lib")) +prepend_path("DYLD_LIBRARY_PATH", pathJoin(base,"lib")) +prepend_path("CPATH", pathJoin(base,"include")) +prepend_path("MANPATH", pathJoin(base,"share","man")) + +setenv("ECFLOW_ROOT", base) +setenv("ECFLOW_INCLUDES", pathJoin(base,"include")) +setenv("ECFLOW_LIBRARIES", pathJoin(base,"lib")) +setenv("ECFLOW_VERSION", pkgVersion) + +whatis("Name: ".. pkgName) +whatis("Version: " .. pkgVersion) +whatis("Category: library") +whatis("Description: ecFlow Workflow Manager") From 60e3eaa547b3f6b1be85447cdbc9b4813d47845d Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Sun, 20 Dec 2020 13:16:34 -0700 Subject: [PATCH 043/132] fix pyInc string manipulation --- buildscripts/libs/build_boost.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_boost.sh b/buildscripts/libs/build_boost.sh index dd4be14..4ef8483 100755 --- a/buildscripts/libs/build_boost.sh +++ b/buildscripts/libs/build_boost.sh @@ -87,7 +87,7 @@ rm -f $HOME/user-config.jam [[ -z $mpi ]] && rm -f ./user-config.jam || mv -f ./user-config.jam $HOME # boost python libraries may not build without these values exported -pyInc=`python3-config --includes | cut -d' ' -f1` +pyInc=`python3-config --includes | cut -d' ' -f1 | cut -c3-` # echo $pyInc export C_INCLUDE_PATH=$C_INCLUDE_PATH:$pyInc export CPLUS_INCLUDE_PATH=$CPLUS_INCLUDE_PATH:$pyInc From 68b5ea8a8c88b7e42ead6b6ad49da789c73333cc Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Tue, 22 Dec 2020 09:29:35 -0700 Subject: [PATCH 044/132] load qt module for the UI --- .../compiler/compilerName/compilerVersion/ecflow/ecflow.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua index 996168f..c6a101e 100644 --- a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua +++ b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua @@ -11,6 +11,8 @@ local compNameVerD = compNameVer:gsub("/","-") conflict(pkgName) +try-load(qt) + local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" local base = pathJoin(opt,compNameVerD,pkgName,pkgVersion) From 5f7f49e2199d42650171e5cc989f3279093b27c8 Mon Sep 17 00:00:00 2001 From: Ryan Honeyager Date: Tue, 5 Jan 2021 11:55:37 -0500 Subject: [PATCH 045/132] Update build_stack.sh --- buildscripts/build_stack.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 6004303..a6bee5e 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -115,7 +115,7 @@ build_lib NCEPLIBS nceplibs fv3 build_lib TKDIFF tkdiff 4.3.5 build_lib PYJEDI pyjedi build_lib PYBIND11 pybind11 2.5.0 -build_lib GSL_LITE gsl_lite 0.34.0 +build_lib GSL_LITE gsl_lite 0.37.0 build_lib GEOS geos 3.8.1 build_lib SQLITE sqlite 3.32.3 build_lib PROJ proj 7.1.0 From 86fca001423eef077b3504b708a3291eef68c728 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 6 Jan 2021 20:21:46 +0000 Subject: [PATCH 046/132] use pathJoin in modulefile --- modulefiles/core/gsl_lite/gsl_lite.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modulefiles/core/gsl_lite/gsl_lite.lua b/modulefiles/core/gsl_lite/gsl_lite.lua index 9e5b4d7..3220439 100644 --- a/modulefiles/core/gsl_lite/gsl_lite.lua +++ b/modulefiles/core/gsl_lite/gsl_lite.lua @@ -14,7 +14,7 @@ local base = pathJoin(opt,"core",pkgName,pkgVersion) prepend_path("CPATH", pathJoin(base,"include")) setenv("gsl_lite_ROOT", base) -setenv("gsl_lite_DIR", base,"lib","cmake","gsl_lite") +setenv("gsl_lite_DIR", pathJoin(base,"lib","cmake","gsl_lite")) whatis("Name: ".. pkgName) whatis("Version: " .. pkgVersion) From 8d910db9ff79ddd8d2f4c921f7620265e466ec77 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 6 Jan 2021 20:31:55 +0000 Subject: [PATCH 047/132] bugfix - dash, not underscore --- modulefiles/core/gsl_lite/gsl_lite.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modulefiles/core/gsl_lite/gsl_lite.lua b/modulefiles/core/gsl_lite/gsl_lite.lua index 3220439..8b8cfd4 100644 --- a/modulefiles/core/gsl_lite/gsl_lite.lua +++ b/modulefiles/core/gsl_lite/gsl_lite.lua @@ -14,7 +14,7 @@ local base = pathJoin(opt,"core",pkgName,pkgVersion) prepend_path("CPATH", pathJoin(base,"include")) setenv("gsl_lite_ROOT", base) -setenv("gsl_lite_DIR", pathJoin(base,"lib","cmake","gsl_lite")) +setenv("gsl_lite_DIR", pathJoin(base,"lib","cmake","gsl-lite")) whatis("Name: ".. pkgName) whatis("Version: " .. pkgVersion) From b03c39e6dda081235ac12dbcdf376de32113746a Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 6 Jan 2021 15:09:23 -0700 Subject: [PATCH 048/132] update apps modulefiles --- modulefiles/apps/jedi/clang-mpich.lua | 5 ++- modulefiles/apps/jedi/clang-openmpi.lua | 5 ++- .../jedi/gnu-7.3.0_openmpi-3.1.2_1.0.0.lua | 31 --------------- ....0_mpich-3.2.1_1.0.0.lua => gnu-mpich.lua} | 33 ++++++++-------- modulefiles/apps/jedi/gnu-openmpi.lua | 39 ++++++++----------- modulefiles/apps/jedi/intel-impi.lua | 37 +++++++++--------- 6 files changed, 59 insertions(+), 91 deletions(-) delete mode 100644 modulefiles/apps/jedi/gnu-7.3.0_openmpi-3.1.2_1.0.0.lua rename modulefiles/apps/jedi/{gnu-7.3.0_mpich-3.2.1_1.0.0.lua => gnu-mpich.lua} (56%) diff --git a/modulefiles/apps/jedi/clang-mpich.lua b/modulefiles/apps/jedi/clang-mpich.lua index 4d04d36..233c3f3 100644 --- a/modulefiles/apps/jedi/clang-mpich.lua +++ b/modulefiles/apps/jedi/clang-mpich.lua @@ -9,8 +9,8 @@ local pkgNameVer = myModuleFullName() conflict(pkgName) load("jedi-clang") -load("szip/2.1.1") -load("jedi-mpich/3.3.2") +load("szip") +load("jedi-mpich") load("hdf5") load("pnetcdf") @@ -26,6 +26,7 @@ load("json-schema-validator") load("ecbuild") load("nccmp") +load("gsl_lite") setenv("CC","mpicc") setenv("FC","mpifort") diff --git a/modulefiles/apps/jedi/clang-openmpi.lua b/modulefiles/apps/jedi/clang-openmpi.lua index 8c52b6c..23f2229 100644 --- a/modulefiles/apps/jedi/clang-openmpi.lua +++ b/modulefiles/apps/jedi/clang-openmpi.lua @@ -9,8 +9,8 @@ local pkgNameVer = myModuleFullName() conflict(pkgName) load("jedi-clang") -load("szip/2.1.1") -load("jedi-openmpi/4.0.3") +load("szip") +load("jedi-openmpi") load("hdf5") load("pnetcdf") @@ -26,6 +26,7 @@ load("json-schema-validator") load("ecbuild") load("nccmp") +load("gsl_lite") setenv("CC","mpicc") setenv("FC","mpifort") diff --git a/modulefiles/apps/jedi/gnu-7.3.0_openmpi-3.1.2_1.0.0.lua b/modulefiles/apps/jedi/gnu-7.3.0_openmpi-3.1.2_1.0.0.lua deleted file mode 100644 index cc35e83..0000000 --- a/modulefiles/apps/jedi/gnu-7.3.0_openmpi-3.1.2_1.0.0.lua +++ /dev/null @@ -1,31 +0,0 @@ -help([[ -Load environment for running JEDI applications with GNU compilers and OpenMPI. -]]) - -local pkgName = myModuleName() -local pkgVersion = myModuleVersion() -local pkgNameVer = myModuleFullName() - -conflict(pkgName) - -load("jedi-gnu/7.3.0") -load("szip/2.1.1") -load("jedi-openmpi/3.1.2") - -load("hdf5/1.10.3") -load("pnetcdf/1.11.1") -load("netcdf/4.6.3") - -load("lapack/3.7.0") -load("boost-headers/1.68.0") -load("eigen/3.3.5") -load("json/3.9.1") -load("json-schema-validator/2.1.0") - -load("eckit/1.1.0") -load("fckit/jcsda-develop") - -whatis("Name: ".. pkgName) -whatis("Version: ".. pkgVersion) -whatis("Category: Application") -whatis("Description: JEDI Environment with OpenMPI") diff --git a/modulefiles/apps/jedi/gnu-7.3.0_mpich-3.2.1_1.0.0.lua b/modulefiles/apps/jedi/gnu-mpich.lua similarity index 56% rename from modulefiles/apps/jedi/gnu-7.3.0_mpich-3.2.1_1.0.0.lua rename to modulefiles/apps/jedi/gnu-mpich.lua index 02172cb..b7088c6 100644 --- a/modulefiles/apps/jedi/gnu-7.3.0_mpich-3.2.1_1.0.0.lua +++ b/modulefiles/apps/jedi/gnu-mpich.lua @@ -8,22 +8,23 @@ local pkgNameVer = myModuleFullName() conflict(pkgName) -load("gnu/7.3.0") -load("szip/2.1.1") -load("mpich/3.2.1") - -load("eigen/3.3.5") -load("boost/1_68_0") -load("json/3.9.1") -load("json-schema-validator/2.1.0") - -load("ecbuild/2.9.3") - -load("eckit/1.1.0") -load("fckit/jcsda-develop") - -load("hdf5/1.10.3") -load("netcdf/4.6.3") +load("jedi-gnu") +load("szip") +load("jedi-mpich") + +load("lapack") +load("eigen") +load("boost") +load("json") +load("json-schema-validator") + +load("ecbuild") +load("eckit") + +load("hdf5") +load("netcdf") +load("nccmp") +load("gsl_lite") whatis("Name: ".. pkgName) whatis("Version: ".. pkgVersion) diff --git a/modulefiles/apps/jedi/gnu-openmpi.lua b/modulefiles/apps/jedi/gnu-openmpi.lua index 4a42610..a4d9846 100644 --- a/modulefiles/apps/jedi/gnu-openmpi.lua +++ b/modulefiles/apps/jedi/gnu-openmpi.lua @@ -8,28 +8,23 @@ local pkgNameVer = myModuleFullName() conflict(pkgName) -load("jedi-gnu/7.4.0") -load("szip/2.1.1") -load("jedi-openmpi/3.1.2") - -load("hdf5/1.10.5") -load("pnetcdf/1.11.2") -load("netcdf/4.7.0") - -load("lapack/3.7.0") -load("boost-headers/1.68.0") -load("eigen/3.3.5") -load("bufrlib/11.3.2") -load("json/3.9.1") -load("json-schema-validator/2.1.0") - -load("ecbuild/jcsda-release-stable") -load("eckit/1.1.0") -load("fckit/jcsda-develop") - -setenv("CC","mpicc") -setenv("FC","mpifort") -setenv("CXX","mpicxx") +load("jedi-gnu") +load("szip") +load("jedi-openmpi") + +load("hdf5") +load("pnetcdf") +load("netcdf") + +load("lapack") +load("boost-headers") +load("eigen") +load("json") +load("json-schema-validator") + +laod("ecbuild") +load("eckit") +load("gsl_lite") whatis("Name: ".. pkgName) whatis("Version: ".. pkgVersion) diff --git a/modulefiles/apps/jedi/intel-impi.lua b/modulefiles/apps/jedi/intel-impi.lua index c48b6b7..c64cabf 100644 --- a/modulefiles/apps/jedi/intel-impi.lua +++ b/modulefiles/apps/jedi/intel-impi.lua @@ -8,24 +8,25 @@ local pkgNameVer = myModuleFullName() conflict(pkgName) -load("jedi-intel/17.0.1") -try_load("szip/2.1.1") -load("jedi-impi/17.0.1") - -load("hdf5/1.10.5") -load("pnetcdf/1.11.2") -load("netcdf/4.7.0") - -load("lapack/3.7.0") -load("boost-headers/1.68.0") -load("eigen/3.3.5") -load("bufrlib/11.3.2") -load("json/3.9.1") -load("json-schema-validator/2.1.0") - -load("ecbuild/jcsda-release-stable") -load("eckit/1.1.0") -load("fckit/jcsda-develop") +load("jedi-intel") +load("szip") +load("jedi-impi") + +load("hdf5") +load("pnetcdf") +load("netcdf") +load("nccmp") + +load("boost-headers") +load("eigen") +load("bufr") +load("json") +load("json-schema-validator") + +load("ecbuild") +load("eckit") +load("gsl_lite") + setenv("CC","mpiicc") setenv("FC","mpiifort") From 7b78c47c5520b2ec9261792d3bb914359cbdeaf6 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 12 Jan 2021 13:04:16 -0700 Subject: [PATCH 049/132] update udunits to 2.2.28 --- buildscripts/build_stack.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index be36f8e..3247af9 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -78,7 +78,7 @@ $MODULES && (set +x; source $MODULESHOME/init/bash; module purge; set -x) # this can be done in each script individually # it might warrant a --force flag to force rebuild when desired build_lib CMAKE cmake 3.17.2 -build_lib UDUNITS udunits 2.2.26 +build_lib UDUNITS udunits 2.2.28 build_lib JPEG jpeg 9.1.0 build_lib ZLIB zlib 1.2.11 build_lib PNG png 1.6.35 From f488a7413cc034a3a9f9175cc0e0ea26161d0d96 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 12 Jan 2021 13:19:12 -0700 Subject: [PATCH 050/132] bugfix in bufr version --- buildscripts/libs/build_bufr.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_bufr.sh b/buildscripts/libs/build_bufr.sh index d1b43e2..0bacd2e 100755 --- a/buildscripts/libs/build_bufr.sh +++ b/buildscripts/libs/build_bufr.sh @@ -45,7 +45,7 @@ then tag=$version else gitOrg="${source}" - tag=bufr_v$version + tag=$version fi cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} From 8ba26dd4d377a9ce22bbdedcbd0491f2fea48cc4 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 12 Jan 2021 14:28:30 -0700 Subject: [PATCH 051/132] remove bufrlib --- buildscripts/config/choose_modules.sh | 1 - .../config_container-clang-mpich-dev.sh | 1 - .../config_container-gnu-openmpi-dev.sh | 1 - .../config/config_container-intel-impi-app.sh | 1 - .../config/config_container-intel-impi-dev.sh | 1 - .../config_container-intel-oneapi-dev.sh | 1 - buildscripts/config/config_gentoo.sh | 1 - buildscripts/libs/build_bufrlib.sh | 58 ------------------- .../compilerVersion/bufrlib/bufrlib.lua | 28 --------- 9 files changed, 93 deletions(-) delete mode 100755 buildscripts/libs/build_bufrlib.sh delete mode 100644 modulefiles/compiler/compilerName/compilerVersion/bufrlib/bufrlib.lua diff --git a/buildscripts/config/choose_modules.sh b/buildscripts/config/choose_modules.sh index c8a15c8..2a2789f 100644 --- a/buildscripts/config/choose_modules.sh +++ b/buildscripts/config/choose_modules.sh @@ -11,7 +11,6 @@ export STACK_BUILD_UDUNITS=Y export STACK_BUILD_ZLIB=Y export STACK_BUILD_LAPACK=N export STACK_BUILD_BOOST_HDRS=Y -export STACK_BUILD_BUFRLIB=N export STACK_BUILD_BUFR=Y export STACK_BUILD_EIGEN3=Y export STACK_BUILD_HDF5=Y diff --git a/buildscripts/config/config_container-clang-mpich-dev.sh b/buildscripts/config/config_container-clang-mpich-dev.sh index ccb4297..9913665 100644 --- a/buildscripts/config/config_container-clang-mpich-dev.sh +++ b/buildscripts/config/config_container-clang-mpich-dev.sh @@ -46,7 +46,6 @@ export STACK_BUILD_ZLIB=Y export STACK_BUILD_LAPACK=Y export STACK_BUILD_BOOST_HDRS=Y export STACK_BUILD_EIGEN3=Y -export STACK_BUILD_BUFRLIB=N export STACK_BUILD_BUFR=Y export STACK_BUILD_HDF5=Y export STACK_BUILD_PNETCDF=Y diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index 627eae4..bb22f96 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -47,7 +47,6 @@ export STACK_BUILD_LAPACK=Y export STACK_BUILD_BOOST_HDRS=Y export STACK_BUILD_EIGEN3=Y export STACK_BUILD_HDF5=Y -export STACK_BUILD_BUFRLIB=N export STACK_BUILD_BUFR=Y export STACK_BUILD_PNETCDF=Y export STACK_BUILD_NETCDF=Y diff --git a/buildscripts/config/config_container-intel-impi-app.sh b/buildscripts/config/config_container-intel-impi-app.sh index 41a975c..d7b4805 100644 --- a/buildscripts/config/config_container-intel-impi-app.sh +++ b/buildscripts/config/config_container-intel-impi-app.sh @@ -51,7 +51,6 @@ export STACK_BUILD_ZLIB=Y export STACK_BUILD_LAPACK=N export STACK_BUILD_BOOST_HDRS=Y export STACK_BUILD_EIGEN3=Y -export STACK_BUILD_BUFRLIB=N export STACK_BUILD_BUFR=Y export STACK_BUILD_HDF5=Y export STACK_BUILD_PNETCDF=Y diff --git a/buildscripts/config/config_container-intel-impi-dev.sh b/buildscripts/config/config_container-intel-impi-dev.sh index 332b628..2ee9c43 100644 --- a/buildscripts/config/config_container-intel-impi-dev.sh +++ b/buildscripts/config/config_container-intel-impi-dev.sh @@ -51,7 +51,6 @@ export STACK_BUILD_ZLIB=Y export STACK_BUILD_LAPACK=N export STACK_BUILD_BOOST_HDRS=Y export STACK_BUILD_EIGEN3=Y -export STACK_BUILD_BUFRLIB=N export STACK_BUILD_BUFR=Y export STACK_BUILD_HDF5=Y export STACK_BUILD_PNETCDF=Y diff --git a/buildscripts/config/config_container-intel-oneapi-dev.sh b/buildscripts/config/config_container-intel-oneapi-dev.sh index 94f4996..aedc3f2 100644 --- a/buildscripts/config/config_container-intel-oneapi-dev.sh +++ b/buildscripts/config/config_container-intel-oneapi-dev.sh @@ -50,7 +50,6 @@ export STACK_BUILD_ZLIB=Y export STACK_BUILD_LAPACK=N export STACK_BUILD_BOOST_HDRS=Y export STACK_BUILD_EIGEN3=Y -export STACK_BUILD_BUFRLIB=N export STACK_BUILD_HDF5=Y export STACK_BUILD_PNETCDF=Y export STACK_BUILD_NETCDF=Y diff --git a/buildscripts/config/config_gentoo.sh b/buildscripts/config/config_gentoo.sh index 89943ca..2aede30 100644 --- a/buildscripts/config/config_gentoo.sh +++ b/buildscripts/config/config_gentoo.sh @@ -66,7 +66,6 @@ export HWLOC_ROOT=/usr ## Don't add any new dependencies to this file # Packages that produce Fortran modules -export STACK_BUILD_BUFRLIB=Y export STACK_BUILD_HDF5=Y export STACK_BUILD_PNETCDF=Y export STACK_BUILD_NETCDF=Y diff --git a/buildscripts/libs/build_bufrlib.sh b/buildscripts/libs/build_bufrlib.sh deleted file mode 100755 index b289c6b..0000000 --- a/buildscripts/libs/build_bufrlib.sh +++ /dev/null @@ -1,58 +0,0 @@ -#!/bin/bash -# © Copyright 2020 UCAR -# This software is licensed under the terms of the Apache Licence Version 2.0 which can be obtained at -# http://www.apache.org/licenses/LICENSE-2.0. - -set -ex - -name="bufrlib" -version=$1 - -# Hyphenated version used for install prefix -compiler=$(echo $JEDI_COMPILER | sed 's/\//-/g') - -# manage package dependencies here -if $MODULES; then - set +x - source $MODULESHOME/init/bash - module load jedi-$JEDI_COMPILER - module try-load cmake - module list - set -x - - prefix="${PREFIX:-"/opt/modules"}/$compiler/$name/$version" - if [[ -d $prefix ]]; then - [[ $OVERWRITE =~ [yYtT] ]] && ( echo "WARNING: $prefix EXISTS: OVERWRITING!";$SUDO rm -rf $prefix ) \ - || ( echo "WARNING: $prefix EXISTS, SKIPPING"; exit 1 ) - fi - -else - prefix=${BUFRLIB_ROOT:-"/usr/local"} -fi - -export FC=$SERIAL_FC -export CC=$SERIAL_CC - -## Implementation can be switched to NCEPLIBS-bufr when shared libraries are supported -software=bufrlib -#software=NCEPLIBS-bufr - -# Release git tag name -tag=bufr_v$version - -cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} -[[ -d $software ]] || git clone https://github.com/JCSDA/$software.git -[[ ${DOWNLOAD_ONLY} =~ [yYtT] ]] && exit 0 -[[ -d $software ]] && cd $software || ( echo "$software does not exist, ABORT!"; exit 1 ) -git fetch -git checkout --detach $tag -[[ -d build ]] && rm -rf build - -cmake -H. -Bbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=1 -DOPT_IPO=OFF -cd build -VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} -VERBOSE=$MAKE_VERBOSE $SUDO make install - -# generate modulefile from template -$MODULES && update_modules compiler $name $version \ - || echo $name $version >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log diff --git a/modulefiles/compiler/compilerName/compilerVersion/bufrlib/bufrlib.lua b/modulefiles/compiler/compilerName/compilerVersion/bufrlib/bufrlib.lua deleted file mode 100644 index 6aea0c6..0000000 --- a/modulefiles/compiler/compilerName/compilerVersion/bufrlib/bufrlib.lua +++ /dev/null @@ -1,28 +0,0 @@ -help([[ Module: NCEP bufrlib library for reading binary BUFR format files ]]) - -local pkgName = myModuleName() -local pkgVersion = myModuleVersion() -local pkgNameVer = myModuleFullName() - -local hierA = hierarchyA(pkgNameVer,1) -local compNameVer = hierA[1] -local compNameVerD = compNameVer:gsub("/","-") - -conflict(pkgName) - -local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" - -local base = pathJoin(opt,compNameVerD,pkgName,pkgVersion) - -prepend_path("LD_LIBRARY_PATH", pathJoin(base,"lib")) -prepend_path("DYLD_LIBRARY_PATH", pathJoin(base,"lib")) -prepend_path("LIBRARY_PATH", pathJoin(base,"lib")) - -setenv("bufr_VERSION", pkgVersion) -setenv("bufr_ROOT", base) -- CMake find_package(bufr) -setenv("bufrlib_ROOT", base) -- py-ncepbufr variable - -whatis("Name: ".. pkgName) -whatis("Version: " .. pkgVersion) -whatis("Category: library") -whatis("Description: NCEP bufrlib library for reading binary BUFR format files") From a53e55ac061346e03d149ab0cffdb0128358ecf8 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 12 Jan 2021 14:39:25 -0700 Subject: [PATCH 052/132] bugfix and module name --- buildscripts/libs/build_bufr.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/buildscripts/libs/build_bufr.sh b/buildscripts/libs/build_bufr.sh index 0bacd2e..1fcc610 100755 --- a/buildscripts/libs/build_bufr.sh +++ b/buildscripts/libs/build_bufr.sh @@ -39,13 +39,15 @@ export CC=$SERIAL_CC software=NCEPLIBS-bufr # Release git tag name -if [[ ${source} == "jcsda" ]] +if [[ ${source} == "jcsda-internal" ]] then gitOrg="jcsda-internal" tag=$version + modlabel="jcsda" else gitOrg="${source}" - tag=$version + tag=bufr_v$version + modlabel="noaa" fi cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} @@ -64,5 +66,5 @@ VERBOSE=$MAKE_VERBOSE $SUDO make install # generate modulefile from template pythonVersion="$(python --version | cut -d " " -f2 | cut -d. -f1-2)" -$MODULES && update_modules compiler $name $source-$version $pythonVersion \ +$MODULES && update_modules compiler $name $modlabel-$version $pythonVersion \ || echo $name $source-$version >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log From c5ceca7ff49ccf31a0e31fa2558a05255ce0a551 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 12 Jan 2021 14:57:05 -0700 Subject: [PATCH 053/132] update README --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 1651186..2733929 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ We want to provide a common set of software libraries to JEDI users and develope | software | version | Notes | | -------- | ------- | ----- | -| udunits | 2.2.26 | | +| udunits | 2.2.26 | updated to 2.2.28 in develop | | zlib | 1.2.11 | | | szip | 2.1.1 | | | lapack | 3.8.0 | Can be replaced by intel mkl | @@ -34,7 +34,7 @@ We want to provide a common set of software libraries to JEDI users and develope | netcdf | 4.7.4, 4.5.3, 4.3.0 | versions for C, Fortran, and C++ | | nccmp | 1.8.7.0 | Needed for running tests | | eckit | jcsda/1.11.6.jcsda2 | Should move to ecmwf for next release | -| bufrlib | 11.3.2 | will be replaced by NCEP bufr | +| bufrlib | 11.3.2 | deprecated: replaced by NCEP-bufr | | pybind11 | 2.5.0 | | | gsl_lite | 0.34.0 | | @@ -43,7 +43,7 @@ We want to provide a common set of software libraries to JEDI users and develope | software | version | Notes | | -------- | ------- | ----- | | CGAL | 5.0.2 | Optional in principle but may become required in practice for efficiency reasons. Can be installed without gmp, mpfr dependencies | -| bufr | 11.4.0 | NCEP version will replace current bufrlib | +| bufr | 11.4.0.jcsda1 | NCEP version replaces previous bufrlib | ## Required for certain components or models From d0d79d4fe997d33ff16ad1563190ec763db81677 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 12 Jan 2021 15:09:33 -0700 Subject: [PATCH 054/132] update gsl_lite in README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 2733929..582ba70 100644 --- a/README.md +++ b/README.md @@ -36,7 +36,7 @@ We want to provide a common set of software libraries to JEDI users and develope | eckit | jcsda/1.11.6.jcsda2 | Should move to ecmwf for next release | | bufrlib | 11.3.2 | deprecated: replaced by NCEP-bufr | | pybind11 | 2.5.0 | | -| gsl_lite | 0.34.0 | | +| gsl_lite | 0.34.0 | upgraded to 0.37.0 in develop | ## New components since most recent release From d069204276013a491a41287d074b1856ea1e6116 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 12 Jan 2021 15:33:22 -0700 Subject: [PATCH 055/132] revert modlabel --- buildscripts/libs/build_bufr.sh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/buildscripts/libs/build_bufr.sh b/buildscripts/libs/build_bufr.sh index 1fcc610..c9ac2ff 100755 --- a/buildscripts/libs/build_bufr.sh +++ b/buildscripts/libs/build_bufr.sh @@ -43,11 +43,9 @@ if [[ ${source} == "jcsda-internal" ]] then gitOrg="jcsda-internal" tag=$version - modlabel="jcsda" else gitOrg="${source}" tag=bufr_v$version - modlabel="noaa" fi cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} @@ -66,5 +64,5 @@ VERBOSE=$MAKE_VERBOSE $SUDO make install # generate modulefile from template pythonVersion="$(python --version | cut -d " " -f2 | cut -d. -f1-2)" -$MODULES && update_modules compiler $name $modlabel-$version $pythonVersion \ +$MODULES && update_modules compiler $name $source-$version $pythonVersion \ || echo $name $source-$version >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log From 38c77ea4d94912f1f83c20a693d6dec458c9f8b9 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Sat, 23 Jan 2021 11:37:37 -0700 Subject: [PATCH 056/132] initial commit for ecFlow --- buildscripts/build_stack.sh | 1 + buildscripts/config/choose_modules.sh | 1 + buildscripts/libs/build_boost.sh | 8 ++- buildscripts/libs/build_ecflow.sh | 71 +++++++++++++++++++ .../compilerVersion/ecflow/ecflow.lua | 35 +++++++++ 5 files changed, 115 insertions(+), 1 deletion(-) create mode 100755 buildscripts/libs/build_ecflow.sh create mode 100644 modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 3247af9..e6aafa2 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -121,6 +121,7 @@ build_lib SQLITE sqlite 3.32.3 build_lib PROJ proj 7.1.0 build_lib JSON json 3.9.1 build_lib JSON_SCHEMA_VALIDATOR json-schema-validator 2.1.0 +build_lib ECFLOW ecflow ecmwf 5.5.3 #---------------------- # These must be rebuilt for each MPI implementation diff --git a/buildscripts/config/choose_modules.sh b/buildscripts/config/choose_modules.sh index 2a2789f..f81e997 100644 --- a/buildscripts/config/choose_modules.sh +++ b/buildscripts/config/choose_modules.sh @@ -49,3 +49,4 @@ export STACK_BUILD_PROJ=N export STACK_BUILD_FMS=N export STACK_BUILD_JSON=N export STACK_BUILD_JSON_SCHEMA_VALIDATOR=N +export STACK_BUILD_ECFLOW=N diff --git a/buildscripts/libs/build_boost.sh b/buildscripts/libs/build_boost.sh index 1661596..c075462 100755 --- a/buildscripts/libs/build_boost.sh +++ b/buildscripts/libs/build_boost.sh @@ -70,6 +70,7 @@ compName=$(echo $compiler | cut -d- -f1) case "$compName" in gnu ) MPICC=$(which mpicc) ; toolset=gcc ;; intel ) MPICC=$(which mpiicc) ; toolset=intel ;; + clang ) MPICC=$(which mpiicc) ; toolset=clang ;; * ) echo "Unknown compiler = $compName, ABORT!"; exit 1 ;; esac @@ -85,7 +86,12 @@ EOF rm -f $HOME/user-config.jam [[ -z $mpi ]] && rm -f ./user-config.jam || mv -f ./user-config.jam $HOME -./bootstrap.sh --with-toolset=$toolset +# boost python libraries may not build without these values exported +pyInc=`python3-config --includes | cut -d' ' -f1 | cut -c3-` +export C_INCLUDE_PATH=$C_INCLUDE_PATH:$pyInc +export CPLUS_INCLUDE_PATH=$CPLUS_INCLUDE_PATH:$pyInc + +./bootstrap.sh --with-toolset=$toolset --with-python=`which python3` ./b2 install $debug --prefix=$BoostBuild export PATH="$BoostBuild/bin:$PATH" diff --git a/buildscripts/libs/build_ecflow.sh b/buildscripts/libs/build_ecflow.sh new file mode 100755 index 0000000..665dfd3 --- /dev/null +++ b/buildscripts/libs/build_ecflow.sh @@ -0,0 +1,71 @@ +#!/bin/bash +# © Copyright 2020 UCAR +# This software is licensed under the terms of the Apache Licence Version 2.0 which can be obtained at +# http://www.apache.org/licenses/LICENSE-2.0. + +set -x + +name="ecflow" +source=$1 +version=$2 + +software=$name +cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} +[[ -d $software ]] || git clone https://github.com/$source/$software.git +[[ ${DOWNLOAD_ONLY} =~ [yYtT] ]] && exit 0 +[[ -d $software ]] && cd $software || ( echo "$software does not exist, ABORT!"; exit 1 ) +git fetch --tags +git checkout $version + +ecflow_version=$(awk '/^project/ && /ecflow/ && /VERSION/ {for (I=1;I<=NF;I++) if ($I == "VERSION") {print $(I+1)};}' CMakeLists.txt) +pythonVersion=$(`which python3` -c 'import sys;print(sys.version_info[0],".",sys.version_info[1],sep="")') + +# Hyphenated version used for install prefix +compiler=$(echo $JEDI_COMPILER | sed 's/\//-/g') + +# software=$name\_$(echo $ecflow_version | sed 's/\./_/g') + +if $MODULES; then + set +x + source $MODULESHOME/init/bash + module load jedi-$JEDI_COMPILER + module load jedi-$JEDI_MPI + module try-load cmake git python qt + module load boost + module list + set -x + + # prefix="${PREFIX:-"/opt/modules"}/$compiler/$name/$ecflow_version" + prefix="${PREFIX:-"/opt/modules"}/$compiler/$name/$name/$version" + if [[ -d $prefix ]]; then + [[ $OVERWRITE =~ [yYtT] ]] && ( echo "WARNING: $prefix EXISTS: OVERWRITING!";$SUDO rm -rf $prefix ) \ + || ( echo "WARNING: $prefix EXISTS, SKIPPING"; exit 1 ) + fi +else + prefix=${ECFLOW_ROOT:-"/usr/local"} +fi + +export FC=$SERIAL_FC +export CC=$SERIAL_CC +export CXX=$SERIAL_CXX + +[[ -d build ]] && $SUDO rm -rf build +mkdir -p build && cd build + +host=$(uname -s) +if [[ "$host" == "Darwin" ]] +then + export OPENSSL_ROOT_DIR=`brew --prefix openssl` + export OPENSSL_INCLUDE_DIR=$OPENSSL_ROOT_DIR/include + export QT=`brew --prefix qt` + QT_LOC="-DCMAKE_PREFIX_PATH=$QT" +fi + +cmake -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release -DENABLE_STATIC_BOOST_LIBS=OFF $QT_LOC \ + -DENABLE_STATIC_BOOST_LIBS=OFF .. +VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} +VERBOSE=$MAKE_VERBOSE $SUDO make install + +# generate modulefile from template +$MODULES && update_modules compiler $name $version $pythonVersion \ + || echo $name $ecflow_version >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log diff --git a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua new file mode 100644 index 0000000..4deb043 --- /dev/null +++ b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua @@ -0,0 +1,35 @@ +help([[ +]]) + +local pkgName = myModuleName() +local pkgVersion = myModuleVersion() +local pkgNameVer = myModuleFullName() + +local hierA = hierarchyA(pkgNameVer,1) +local compNameVer = hierA[1] +local compNameVerD = compNameVer:gsub("/","-") + +conflict(pkgName) + +try_load("qt") + +local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" + +local base = pathJoin(opt,compNameVerD,pkgName,pkgVersion) + +prepend_path("PATH", pathJoin(base,"bin")) +prepend_path("LD_LIBRARY_PATH", pathJoin(base,"lib")) +prepend_path("DYLD_LIBRARY_PATH", pathJoin(base,"lib")) +prepend_path("CPATH", pathJoin(base,"include")) +prepend_path("MANPATH", pathJoin(base,"share","man")) + +setenv("ECFLOW_ROOT", base) +setenv("ECFLOW_INCLUDES", pathJoin(base,"include")) +setenv("ECFLOW_LIBRARIES", pathJoin(base,"lib")) +setenv("ECFLOW_VERSION", pkgVersion) +setenv("ECFLOW_PYTHON", pathJoin(base,"lib/python@PYTHON_VERSION@/site-packages/ecflow")) + +whatis("Name: ".. pkgName) +whatis("Version: " .. pkgVersion) +whatis("Category: library") +whatis("Description: ecFlow Workflow Manager") From a3caf014a87128fb6ae8966641ab3914886f6d4b Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Sat, 23 Jan 2021 11:54:34 -0700 Subject: [PATCH 057/132] fix typos --- buildscripts/libs/build_ecflow.sh | 4 ++-- .../compiler/compilerName/compilerVersion/ecflow/ecflow.lua | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/buildscripts/libs/build_ecflow.sh b/buildscripts/libs/build_ecflow.sh index 4a5f8a7..b16950e 100755 --- a/buildscripts/libs/build_ecflow.sh +++ b/buildscripts/libs/build_ecflow.sh @@ -17,7 +17,7 @@ cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} git fetch --tags git checkout $version -ecflow_version=$(awk '/^project/ && /ecflow/ && /VERSION/ {for (I=1;I<=NF;I++) if ($I == "VERSION") {print $(I+1)};}' CMakeLists.txt) +ecflowVersion=$(awk '/^project/ && /ecflow/ && /VERSION/ {for (I=1;I<=NF;I++) if ($I == "VERSION") {print $(I+1)};}' CMakeLists.txt) pythonVersion=$(`which python3` -c 'import sys;print(sys.version_info[0],".",sys.version_info[1],sep="")') # Hyphenated version used for install prefix @@ -65,4 +65,4 @@ VERBOSE=$MAKE_VERBOSE $SUDO make install # generate modulefile from template $MODULES && update_modules compiler $name $version $pythonVersion \ - || echo $name $ecflow_version >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log + || echo $name $ecflowVersion >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log diff --git a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua index 6493a28..4deb043 100644 --- a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua +++ b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua @@ -11,7 +11,7 @@ local compNameVerD = compNameVer:gsub("/","-") conflict(pkgName) -try-load(qt) +try_load("qt") local opt = os.getenv("JEDI_OPT") or os.getenv("OPT") or "/opt/modules" From 1335ca15cd078d14d3e5696964547c58cc7cd1a7 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Sat, 23 Jan 2021 12:03:52 -0700 Subject: [PATCH 058/132] Update build_ecflow.sh MPI module not necessary to build ecFlow --- buildscripts/libs/build_ecflow.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/buildscripts/libs/build_ecflow.sh b/buildscripts/libs/build_ecflow.sh index b16950e..e662f8f 100755 --- a/buildscripts/libs/build_ecflow.sh +++ b/buildscripts/libs/build_ecflow.sh @@ -27,7 +27,6 @@ if $MODULES; then set +x source $MODULESHOME/init/bash module load jedi-$JEDI_COMPILER - module load jedi-$JEDI_MPI module try-load cmake git python qt module load boost module list From 9e55605b5630473267fec4cae8df4f53740633b6 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Sat, 23 Jan 2021 12:10:07 -0700 Subject: [PATCH 059/132] Update build_ecflow.sh Fix install path naming --- buildscripts/libs/build_ecflow.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_ecflow.sh b/buildscripts/libs/build_ecflow.sh index e662f8f..e7a2bf2 100755 --- a/buildscripts/libs/build_ecflow.sh +++ b/buildscripts/libs/build_ecflow.sh @@ -32,7 +32,7 @@ if $MODULES; then module list set -x - prefix="${PREFIX:-"/opt/modules"}/$compiler/$name/$name/$version" + prefix="${PREFIX:-"/opt/modules"}/$compiler/$name/$version" if [[ -d $prefix ]]; then [[ $OVERWRITE =~ [yYtT] ]] && ( echo "WARNING: $prefix EXISTS: OVERWRITING!";$SUDO rm -rf $prefix ) \ || ( echo "WARNING: $prefix EXISTS, SKIPPING"; exit 1 ) From 8bb0927d311c38a567e4d3f907868103e4a2f574 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Sun, 24 Jan 2021 09:19:00 -0700 Subject: [PATCH 060/132] fix sed command for python version substitution --- buildscripts/libs/update_modules.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/update_modules.sh b/buildscripts/libs/update_modules.sh index 0981d38..124a970 100755 --- a/buildscripts/libs/update_modules.sh +++ b/buildscripts/libs/update_modules.sh @@ -41,7 +41,7 @@ function update_modules { $SUDO cp $tmpl_file $3.lua # Argument number 4 is python version. If not empty use sed to # substitue python version into placeholder marks in the lua script. - [[ -n "$4" ]] && $SUDO sed -i "" -e "s/@PYTHON_VERSION@/$4/" $3.lua + [[ -n "$4" ]] && $SUDO sed -i -e "s/@PYTHON_VERSION@/$4/" $3.lua # Make the latest installed version the default [[ -e default ]] && $SUDO rm -f default From be2f3651384b1ace7c0dbb9b81b4416355134bec Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Mon, 25 Jan 2021 15:10:03 -0700 Subject: [PATCH 061/132] add PYTHONPATH to env vars --- .../compiler/compilerName/compilerVersion/ecflow/ecflow.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua index 4deb043..1c60e4a 100644 --- a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua +++ b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua @@ -23,6 +23,8 @@ prepend_path("DYLD_LIBRARY_PATH", pathJoin(base,"lib")) prepend_path("CPATH", pathJoin(base,"include")) prepend_path("MANPATH", pathJoin(base,"share","man")) +prepend_path("PYTHONPATH", pathJoin(base,"lib/python@PYTHON_VERSION@/site-packages/ecflow")) + setenv("ECFLOW_ROOT", base) setenv("ECFLOW_INCLUDES", pathJoin(base,"include")) setenv("ECFLOW_LIBRARIES", pathJoin(base,"lib")) From 369b657e3b306ba2efed8321fb4f7255c546662d Mon Sep 17 00:00:00 2001 From: mmiesch Date: Mon, 1 Feb 2021 17:29:47 -0700 Subject: [PATCH 062/132] deprecate old intel dev container config --- .../config/config_container-intel-impi-dev.sh | 5 +- .../config_container-intel-oneapi-dev.sh | 85 ------------------- 2 files changed, 2 insertions(+), 88 deletions(-) delete mode 100644 buildscripts/config/config_container-intel-oneapi-dev.sh diff --git a/buildscripts/config/config_container-intel-impi-dev.sh b/buildscripts/config/config_container-intel-impi-dev.sh index 2ee9c43..af2367a 100644 --- a/buildscripts/config/config_container-intel-impi-dev.sh +++ b/buildscripts/config/config_container-intel-impi-dev.sh @@ -5,9 +5,8 @@ # Compiler/MPI combination -export JEDI_COMPILER="intel/19.1.0" -export JEDI_MPI="impi/19.1.0" -source /opt/intel/compilers_and_libraries/linux/bin/compilervars.sh intel64 +export JEDI_COMPILER="intel/2021.1.2" +export JEDI_MPI="impi/2021.1.2" export PATH=/usr/local/bin:$PATH export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH export LIBRARY_PATH=/usr/local/lib:$LIBRARY_PATH diff --git a/buildscripts/config/config_container-intel-oneapi-dev.sh b/buildscripts/config/config_container-intel-oneapi-dev.sh deleted file mode 100644 index aedc3f2..0000000 --- a/buildscripts/config/config_container-intel-oneapi-dev.sh +++ /dev/null @@ -1,85 +0,0 @@ -#!/bin/bash -# © Copyright 2020 UCAR -# This software is licensed under the terms of the Apache Licence Version 2.0 which can be obtained at -# http://www.apache.org/licenses/LICENSE-2.0. - - -# Compiler/MPI combination -export JEDI_COMPILER="intel/2021.1" -export JEDI_MPI="impi/2021.1" -export PATH=/usr/local/bin:$PATH -export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH -export LIBRARY_PATH=/usr/local/lib:$LIBRARY_PATH -export CPATH=/usr/local/include:$CPATH - -# This tells jedi-stack how you want to build the compiler and mpi modules -# valid options include: -# native-module: load a pre-existing module (common for HPC systems) -# native-pkg: use pre-installed executables located in /usr/bin or /usr/local/bin, -# as installed by package managers like apt-get or hombrewo. -# This is a common option for, e.g., gcc/g++/gfortran -# from-source: This is to build from source -export COMPILER_BUILD="native-pkg" -export MPI_BUILD="native-pkg" - -# Build options -export PREFIX=/usr/local -export USE_SUDO=N -export PKGDIR=pkg -export LOGDIR=buildscripts/log -export OVERWRITE=N -export NTHREADS=4 -export MAKE_CHECK=N -export MAKE_VERBOSE=Y -export MAKE_CLEAN=Y -export DOWNLOAD_ONLY=F -export STACK_EXIT_ON_FAIL=T -export WGET="wget -nv" -#Global compiler flags -export FFLAGS="" -export CFLAGS="" -export CXXFLAGS="" -export LDFLAGS="" - -# Minimal JEDI Stack -export STACK_BUILD_CMAKE=N -export STACK_BUILD_GITLFS=N -export STACK_BUILD_SZIP=Y -export STACK_BUILD_UDUNITS=Y -export STACK_BUILD_ZLIB=Y -export STACK_BUILD_LAPACK=N -export STACK_BUILD_BOOST_HDRS=Y -export STACK_BUILD_EIGEN3=Y -export STACK_BUILD_HDF5=Y -export STACK_BUILD_PNETCDF=Y -export STACK_BUILD_NETCDF=Y -export STACK_BUILD_NCCMP=Y -export STACK_BUILD_NCO=N -export STACK_BUILD_ECBUILD=Y -export STACK_BUILD_ECKIT=Y -export STACK_BUILD_FCKIT=N -export STACK_BUILD_ATLAS=N -export STACK_BUILD_PYBIND11=Y -export STACK_BUILD_GSL_LITE=Y - -# Optional Additions -export STACK_BUILD_ODC=N -export STACK_BUILD_PIO=Y -export STACK_BUILD_GPTL=N -export STACK_BUILD_PYJEDI=Y -export STACK_BUILD_NCEPLIBS=N -export STACK_BUILD_JPEG=N -export STACK_BUILD_PNG=N -export STACK_BUILD_JASPER=N -export STACK_BUILD_ARMADILLO=N -export STACK_BUILD_XERCES=N -export STACK_BUILD_TKDIFF=N -export STACK_BUILD_BOOST_FULL=N -export STACK_BUILD_ESMF=N -export STACK_BUILD_BASELIBS=N -export STACK_BUILD_PDTOOLKIT=N -export STACK_BUILD_TAU2=N -export STACK_BUILD_CGAL=N -export STACK_BUILD_JSON=Y -export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y -export STACK_BUILD_FMS=N From 3830e4d1852225db6c1f31f4568535aee73a50be Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 3 Feb 2021 10:00:12 -0700 Subject: [PATCH 063/132] remove py-ncepbufr from pyjedi --- buildscripts/libs/build_pyjedi.sh | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/buildscripts/libs/build_pyjedi.sh b/buildscripts/libs/build_pyjedi.sh index 7661a54..4c78195 100755 --- a/buildscripts/libs/build_pyjedi.sh +++ b/buildscripts/libs/build_pyjedi.sh @@ -28,14 +28,3 @@ $SUDO python3 -m pip install -U pytest $SUDO python3 -m pip install -U ford $SUDO python3 -m pip install -U xarray $SUDO python3 -m pip install -U pyodc - -##################################################################### -# ncepbufr for python -##################################################################### - -cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} -git clone https://github.com/JCSDA/py-ncepbufr.git -cd py-ncepbufr - -CC=gcc python3 setup.py build -$SUDO python3 setup.py install From 0d343f44038ce9d2881194e738f3479187ee48e7 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 3 Feb 2021 11:20:14 -0700 Subject: [PATCH 064/132] remove patch from intel container config --- buildscripts/config/config_container-intel-impi-dev.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/buildscripts/config/config_container-intel-impi-dev.sh b/buildscripts/config/config_container-intel-impi-dev.sh index af2367a..c5b6953 100644 --- a/buildscripts/config/config_container-intel-impi-dev.sh +++ b/buildscripts/config/config_container-intel-impi-dev.sh @@ -5,8 +5,8 @@ # Compiler/MPI combination -export JEDI_COMPILER="intel/2021.1.2" -export JEDI_MPI="impi/2021.1.2" +export JEDI_COMPILER="intel/2021.1" +export JEDI_MPI="impi/2021.1" export PATH=/usr/local/bin:$PATH export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH export LIBRARY_PATH=/usr/local/lib:$LIBRARY_PATH From 1ffcc92fb48e090ef8b01b0717701dba73d20c74 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 3 Feb 2021 17:36:54 -0700 Subject: [PATCH 065/132] don't clean pkg directory yet --- buildscripts/config/config_container-intel-impi-dev.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/config/config_container-intel-impi-dev.sh b/buildscripts/config/config_container-intel-impi-dev.sh index c5b6953..7bdfe20 100644 --- a/buildscripts/config/config_container-intel-impi-dev.sh +++ b/buildscripts/config/config_container-intel-impi-dev.sh @@ -31,7 +31,7 @@ export OVERWRITE=N export NTHREADS=4 export MAKE_CHECK=N export MAKE_VERBOSE=Y -export MAKE_CLEAN=Y +export MAKE_CLEAN=N export DOWNLOAD_ONLY=F export STACK_EXIT_ON_FAIL=T export WGET="wget -nv" From c09400a4684476c960f3c7a18d7496f42444dad4 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Mon, 8 Feb 2021 17:17:24 -0700 Subject: [PATCH 066/132] updated to build full boost within ecFlow --- buildscripts/build_stack.sh | 2 +- buildscripts/libs/build_ecflow.sh | 88 ++++++++++++++++++++++++++++--- 2 files changed, 81 insertions(+), 9 deletions(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index e6aafa2..c2fb8a5 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -121,7 +121,7 @@ build_lib SQLITE sqlite 3.32.3 build_lib PROJ proj 7.1.0 build_lib JSON json 3.9.1 build_lib JSON_SCHEMA_VALIDATOR json-schema-validator 2.1.0 -build_lib ECFLOW ecflow ecmwf 5.5.3 +build_lib ECFLOW ecflow ecmwf 5.5.3 boost 1.73.0 #---------------------- # These must be rebuilt for each MPI implementation diff --git a/buildscripts/libs/build_ecflow.sh b/buildscripts/libs/build_ecflow.sh index e7a2bf2..264ef3c 100755 --- a/buildscripts/libs/build_ecflow.sh +++ b/buildscripts/libs/build_ecflow.sh @@ -8,27 +8,36 @@ set -x name="ecflow" source=$1 version=$2 +boost=$3 +boost_version=$4 + +# Build boost libraries first; ecFlow requires them +# Install boost and ecFlow in ecFlow directory hierarchy + +# Steps +# 1. get ecFlow software +# 2. get boost software, downloaded into ecFlow pkg dir +# 3. build full boost (libs, headers) in ecFlow pkg dir +# 4. build ecFlow against boost -software=$name cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} + +software=$name [[ -d $software ]] || git clone https://github.com/$source/$software.git [[ ${DOWNLOAD_ONLY} =~ [yYtT] ]] && exit 0 [[ -d $software ]] && cd $software || ( echo "$software does not exist, ABORT!"; exit 1 ) git fetch --tags git checkout $version -ecflowVersion=$(awk '/^project/ && /ecflow/ && /VERSION/ {for (I=1;I<=NF;I++) if ($I == "VERSION") {print $(I+1)};}' CMakeLists.txt) -pythonVersion=$(`which python3` -c 'import sys;print(sys.version_info[0],".",sys.version_info[1],sep="")') - -# Hyphenated version used for install prefix compiler=$(echo $JEDI_COMPILER | sed 's/\//-/g') +mpi=$(echo $JEDI_MPI | sed 's/\//-/g') if $MODULES; then set +x source $MODULESHOME/init/bash module load jedi-$JEDI_COMPILER + [[ -z $mpi ]] || module load jedi-$JEDI_MPI module try-load cmake git python qt - module load boost module list set -x @@ -41,6 +50,69 @@ else prefix=${ECFLOW_ROOT:-"/usr/local"} fi +# boost component +boost_software=$boost\_$(echo $boost_version | sed 's/\./_/g') +url="https://dl.bintray.com/boostorg/release/$boost_version/source/$boost_software.tar.gz" +[[ -d $boost_software ]] || ( $WGET $url; tar -xf $boost_software.tar.gz ) +[[ -d $boost_software ]] && cd $boost_software || ( echo "$boost_software does not exist, ABORT!"; exit 1 ) + +debug="--debug-configuration" + +BoostRoot=$(pwd) +BoostBuild=$BoostRoot/BoostBuild +build_boost=$BoostRoot/build_boost +[[ -d $BoostBuild ]] && rm -rf $BoostBuild +[[ -d $build_boost ]] && rm -rf $build_boost +cd $BoostRoot/tools/build + +# Configure with MPI +compName=$(echo $compiler | cut -d- -f1) +case "$compName" in + gnu ) MPICC=$(which mpicc) ; toolset=gcc ;; + intel ) MPICC=$(which mpiicc) ; toolset=intel ;; + clang ) MPICC=$(which mpiicc) ; toolset=clang ;; + * ) echo "Unknown compiler = $compName, ABORT!"; exit 1 ;; +esac + +cp $BoostRoot/tools/build/example/user-config.jam ./user-config.jam +cat >> ./user-config.jam << EOF + +# ------------------ +# MPI configuration. +# ------------------ +using mpi : $MPICC ; +EOF + +rm -f $HOME/user-config.jam +[[ -z $mpi ]] && rm -f ./user-config.jam || mv -f ./user-config.jam $HOME + +# boost python libraries may not build without these values exported +pyInc=`python3-config --includes | cut -d' ' -f1 | cut -c3-` +export C_INCLUDE_PATH=$C_INCLUDE_PATH:$pyInc +export CPLUS_INCLUDE_PATH=$CPLUS_INCLUDE_PATH:$pyInc + +./bootstrap.sh --with-toolset=$toolset --with-python=`which python3` +./b2 install $debug --prefix=$BoostBuild + +export PATH="$BoostBuild/bin:$PATH" + +cd $BoostRoot +b2 $debug --build-dir=$build_boost address-model=64 toolset=$toolset stage + +$SUDO mkdir -p $prefix $prefix/include +$SUDO cp -R boost $prefix/include +$SUDO mv stage/lib $prefix + +rm -f $HOME/user-config.jam + +export BOOST_ROOT=$prefix + +# ecFlow component +cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"}/$software + +ecflowVersion=$(awk '/^project/ && /ecflow/ && /VERSION/ {for (I=1;I<=NF;I++) if ($I == "VERSION") {print $(I+1)};}' CMakeLists.txt) +pythonVersion=$(`which python3` -c 'import sys;print(sys.version_info[0],".",sys.version_info[1],sep="")') + export FC=$SERIAL_FC export CC=$SERIAL_CC export CXX=$SERIAL_CXX @@ -57,8 +129,8 @@ then QT_LOC="-DCMAKE_PREFIX_PATH=$QT" fi -cmake -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release -DENABLE_STATIC_BOOST_LIBS=OFF $QT_LOC \ - -DENABLE_STATIC_BOOST_LIBS=OFF .. +cmake -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release \ + -DBOOST_ROOT=$prefix -DENABLE_STATIC_BOOST_LIBS=OFF $QT_LOC .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install From 60ff77ccaf6e4d73690f98b3ca1b4ec3899ef824 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Mon, 8 Feb 2021 17:24:32 -0700 Subject: [PATCH 067/132] remove modified build_boost.sh; changes no longer required --- buildscripts/libs/build_boost.sh | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/buildscripts/libs/build_boost.sh b/buildscripts/libs/build_boost.sh index c075462..1661596 100755 --- a/buildscripts/libs/build_boost.sh +++ b/buildscripts/libs/build_boost.sh @@ -70,7 +70,6 @@ compName=$(echo $compiler | cut -d- -f1) case "$compName" in gnu ) MPICC=$(which mpicc) ; toolset=gcc ;; intel ) MPICC=$(which mpiicc) ; toolset=intel ;; - clang ) MPICC=$(which mpiicc) ; toolset=clang ;; * ) echo "Unknown compiler = $compName, ABORT!"; exit 1 ;; esac @@ -86,12 +85,7 @@ EOF rm -f $HOME/user-config.jam [[ -z $mpi ]] && rm -f ./user-config.jam || mv -f ./user-config.jam $HOME -# boost python libraries may not build without these values exported -pyInc=`python3-config --includes | cut -d' ' -f1 | cut -c3-` -export C_INCLUDE_PATH=$C_INCLUDE_PATH:$pyInc -export CPLUS_INCLUDE_PATH=$CPLUS_INCLUDE_PATH:$pyInc - -./bootstrap.sh --with-toolset=$toolset --with-python=`which python3` +./bootstrap.sh --with-toolset=$toolset ./b2 install $debug --prefix=$BoostBuild export PATH="$BoostBuild/bin:$PATH" From 552c1673c5967105ef3a801591f49b61d430859d Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Mon, 8 Feb 2021 17:30:16 -0700 Subject: [PATCH 068/132] remove setting of env var BOOST_ROOT; would conflict with boost headers module --- buildscripts/libs/build_ecflow.sh | 2 -- 1 file changed, 2 deletions(-) diff --git a/buildscripts/libs/build_ecflow.sh b/buildscripts/libs/build_ecflow.sh index 264ef3c..c44bc7b 100755 --- a/buildscripts/libs/build_ecflow.sh +++ b/buildscripts/libs/build_ecflow.sh @@ -105,8 +105,6 @@ $SUDO mv stage/lib $prefix rm -f $HOME/user-config.jam -export BOOST_ROOT=$prefix - # ecFlow component cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"}/$software From c9f4d5920731c8ab5b577fc6e2d71cd03cadde7e Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 17 Feb 2021 14:30:07 -0700 Subject: [PATCH 069/132] Add issue templates --- .github/ISSUE_TEMPLATE/bug-report.md | 28 +++++++++++++++++++++++++ .github/ISSUE_TEMPLATE/config.yaml | 8 +++++++ .github/ISSUE_TEMPLATE/general-issue.md | 26 +++++++++++++++++++++++ 3 files changed, 62 insertions(+) create mode 100644 .github/ISSUE_TEMPLATE/bug-report.md create mode 100644 .github/ISSUE_TEMPLATE/config.yaml create mode 100644 .github/ISSUE_TEMPLATE/general-issue.md diff --git a/.github/ISSUE_TEMPLATE/bug-report.md b/.github/ISSUE_TEMPLATE/bug-report.md new file mode 100644 index 0000000..d87615d --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug-report.md @@ -0,0 +1,28 @@ +--- +name: Bug report +about: Use this template to report bugs +title: "[Bug]" +labels: 'bug' +assignees: '' + +--- + +## Current behavior (describe the bug) +>[Be sure to add a Pipeline, Label, Estimate, Assignees, and Epic](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/inside/practices/issues.html) + +## To Reproduce + +> What computer are you running on? + +> What compilers/modules are you using? + +> Steps to reproduce the behavior + +1. +2. +3. +... + +## Expected behavior + +## Additional information (optional) diff --git a/.github/ISSUE_TEMPLATE/config.yaml b/.github/ISSUE_TEMPLATE/config.yaml new file mode 100644 index 0000000..4de2fed --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yaml @@ -0,0 +1,8 @@ +blank_issues_enabled: false +contact_links: + - name: JCSDA + url: https://jcsda.org/ + about: JCSDA web site + - name: Forums + url: https://forums.jcsda.org/ + about: JCSDA user/developer forums diff --git a/.github/ISSUE_TEMPLATE/general-issue.md b/.github/ISSUE_TEMPLATE/general-issue.md new file mode 100644 index 0000000..dc339e4 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/general-issue.md @@ -0,0 +1,26 @@ +--- +name: General issue template +about: Use this template for general issues +title: "[New issue]" +labels: '' +assignees: '' + +--- + +## Description +>Provide a detailed description of this issue. +>What problem needs to be fixed? What new capability needs to be added? +>If this is a bug, describe the current behavior (or use the bug template). +>[Be sure to add a Pipeline, Label, Estimate, Assignees, and Epic](https://jointcenterforsatellitedataassimilation-jedi-docs.readthedocs-hosted.com/en/latest/inside/practices/issues.html) + +## Requirements + +>If this is a new feature: What does the new code need to accomplish? Does it require new software dependencies (e.g. new jedi-stack components or new python modules?) +>If this is a bugfix: What is the expected behavior? + +## Acceptance Criteria (Definition of Done) +>What does it mean for this to be finished? + +## Dependencies +>What must be done before this can be done? Add issue dependencies in ZenHub as appropriate +>Does this block progress on other issues? Add this issue as a dependency to other ZenHub issues as appropriate From 1193b35c7cf8d7b4f04a46ff5119fe2e828dfcde Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Wed, 17 Feb 2021 14:39:21 -0700 Subject: [PATCH 070/132] remove unnecessary boost components --- buildscripts/libs/build_ecflow.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/buildscripts/libs/build_ecflow.sh b/buildscripts/libs/build_ecflow.sh index c44bc7b..d5285e0 100755 --- a/buildscripts/libs/build_ecflow.sh +++ b/buildscripts/libs/build_ecflow.sh @@ -132,6 +132,9 @@ cmake -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release \ VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install +rm -rf $prefix/lib/cmake +rm -rf $prefix/include/boost + # generate modulefile from template $MODULES && update_modules compiler $name $version $pythonVersion \ || echo $name $ecflowVersion >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log From 4c422361b39d7f30864ce3d8aeaf6e2fb49acb12 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Tue, 9 Mar 2021 18:10:07 -0700 Subject: [PATCH 071/132] changes to support brew-installed components on macOS --- buildscripts/libs/build_ecflow.sh | 112 ++++++++++++------------------ 1 file changed, 45 insertions(+), 67 deletions(-) diff --git a/buildscripts/libs/build_ecflow.sh b/buildscripts/libs/build_ecflow.sh index d5285e0..9b1ddad 100755 --- a/buildscripts/libs/build_ecflow.sh +++ b/buildscripts/libs/build_ecflow.sh @@ -11,15 +11,6 @@ version=$2 boost=$3 boost_version=$4 -# Build boost libraries first; ecFlow requires them -# Install boost and ecFlow in ecFlow directory hierarchy - -# Steps -# 1. get ecFlow software -# 2. get boost software, downloaded into ecFlow pkg dir -# 3. build full boost (libs, headers) in ecFlow pkg dir -# 4. build ecFlow against boost - cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} software=$name @@ -30,13 +21,11 @@ git fetch --tags git checkout $version compiler=$(echo $JEDI_COMPILER | sed 's/\//-/g') -mpi=$(echo $JEDI_MPI | sed 's/\//-/g') if $MODULES; then set +x source $MODULESHOME/init/bash module load jedi-$JEDI_COMPILER - [[ -z $mpi ]] || module load jedi-$JEDI_MPI module try-load cmake git python qt module list set -x @@ -50,60 +39,58 @@ else prefix=${ECFLOW_ROOT:-"/usr/local"} fi -# boost component -boost_software=$boost\_$(echo $boost_version | sed 's/\./_/g') -url="https://dl.bintray.com/boostorg/release/$boost_version/source/$boost_software.tar.gz" -[[ -d $boost_software ]] || ( $WGET $url; tar -xf $boost_software.tar.gz ) -[[ -d $boost_software ]] && cd $boost_software || ( echo "$boost_software does not exist, ABORT!"; exit 1 ) - -debug="--debug-configuration" +host=$(uname -s) +if [[ "$host" == "Darwin" ]]; then + [[ -d `brew --cellar boost` ]] && boost_root=`brew --prefix boost` + [[ -z $boost_root ]] || echo "Using brew-installed boost headers and libraries" -BoostRoot=$(pwd) -BoostBuild=$BoostRoot/BoostBuild -build_boost=$BoostRoot/build_boost -[[ -d $BoostBuild ]] && rm -rf $BoostBuild -[[ -d $build_boost ]] && rm -rf $build_boost -cd $BoostRoot/tools/build + export OPENSSL_ROOT_DIR=`brew --prefix openssl` + export OPENSSL_INCLUDE_DIR=$OPENSSL_ROOT_DIR/include -# Configure with MPI -compName=$(echo $compiler | cut -d- -f1) -case "$compName" in - gnu ) MPICC=$(which mpicc) ; toolset=gcc ;; - intel ) MPICC=$(which mpiicc) ; toolset=intel ;; - clang ) MPICC=$(which mpiicc) ; toolset=clang ;; - * ) echo "Unknown compiler = $compName, ABORT!"; exit 1 ;; -esac + [[ -d `brew --cellar qt` ]] && qt_root=`brew --prefix qt` + [[ ! -z $qt_root ]] && QT="-DCMAKE_PREFIX_PATH=$qt_root" \ + || ( echo "Qt must be installed for ecFlow UI, ABORT!" ; exit 1 ) +fi -cp $BoostRoot/tools/build/example/user-config.jam ./user-config.jam -cat >> ./user-config.jam << EOF +# boost component; build if not otherwise present +if [ -z $boost_root ]; then + echo "Building boost from source" + boost_software=$boost\_$(echo $boost_version | sed 's/\./_/g') + url="https://dl.bintray.com/boostorg/release/$boost_version/source/$boost_software.tar.gz" + [[ -d $boost_software ]] || ( $WGET $url; tar -xf $boost_software.tar.gz ) + [[ -d $boost_software ]] && cd $boost_software || ( echo "$boost_software does not exist, ABORT!"; exit 1 ) -# ------------------ -# MPI configuration. -# ------------------ -using mpi : $MPICC ; -EOF + debug="--debug-configuration" -rm -f $HOME/user-config.jam -[[ -z $mpi ]] && rm -f ./user-config.jam || mv -f ./user-config.jam $HOME + BoostRoot=$(pwd) + BoostBuild=$BoostRoot/BoostBuild + build_boost=$BoostRoot/build_boost + [[ -d $BoostBuild ]] && rm -rf $BoostBuild + [[ -d $build_boost ]] && rm -rf $build_boost + cd $BoostRoot/tools/build -# boost python libraries may not build without these values exported -pyInc=`python3-config --includes | cut -d' ' -f1 | cut -c3-` -export C_INCLUDE_PATH=$C_INCLUDE_PATH:$pyInc -export CPLUS_INCLUDE_PATH=$CPLUS_INCLUDE_PATH:$pyInc + compName=$(echo $compiler | cut -d- -f1) + case "$compName" in + gnu ) toolset=gcc ;; + intel ) toolset=intel ;; + clang ) toolset=clang ;; + * ) echo "Unknown compiler = $compName, ABORT!"; exit 1 ;; + esac -./bootstrap.sh --with-toolset=$toolset --with-python=`which python3` -./b2 install $debug --prefix=$BoostBuild + ./bootstrap.sh --with-toolset=$toolset --with-python=`which python3` + ./b2 install $debug --prefix=$BoostBuild -export PATH="$BoostBuild/bin:$PATH" + export PATH="$BoostBuild/bin:$PATH" -cd $BoostRoot -b2 $debug --build-dir=$build_boost address-model=64 toolset=$toolset stage + cd $BoostRoot + b2 $debug --build-dir=$build_boost address-model=64 toolset=$toolset stage -$SUDO mkdir -p $prefix $prefix/include -$SUDO cp -R boost $prefix/include -$SUDO mv stage/lib $prefix + $SUDO mkdir -p $prefix $prefix/include + $SUDO cp -R boost $prefix/include + $SUDO mv stage/lib $prefix -rm -f $HOME/user-config.jam + boost_root=$prefix +fi # ecFlow component cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"}/$software @@ -118,23 +105,14 @@ export CXX=$SERIAL_CXX [[ -d build ]] && $SUDO rm -rf build mkdir -p build && cd build -host=$(uname -s) -if [[ "$host" == "Darwin" ]] -then - export OPENSSL_ROOT_DIR=`brew --prefix openssl` - export OPENSSL_INCLUDE_DIR=$OPENSSL_ROOT_DIR/include - export QT=`brew --prefix qt` - QT_LOC="-DCMAKE_PREFIX_PATH=$QT" -fi - cmake -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release \ - -DBOOST_ROOT=$prefix -DENABLE_STATIC_BOOST_LIBS=OFF $QT_LOC .. + -DBOOST_ROOT=$boost_root -DENABLE_STATIC_BOOST_LIBS=OFF $QT .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install -rm -rf $prefix/lib/cmake -rm -rf $prefix/include/boost +[[ -d $prefix/lib/cmake ]] && $SUDO rm -rf $prefix/lib/cmake +[[ -d $prefix/include/boost ]] && $SUDO rm -rf $prefix/include/boost # generate modulefile from template $MODULES && update_modules compiler $name $version $pythonVersion \ - || echo $name $ecflowVersion >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log + || echo $name $ecflowVersion >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log \ No newline at end of file From 53dd942daf961c1e91bdc72f5de7eb12ee414bc6 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Wed, 10 Mar 2021 17:02:08 -0700 Subject: [PATCH 072/132] refactoring for macOS brew, remove MPI dependency --- README.md | 1 + buildscripts/build_stack.sh | 2 +- buildscripts/libs/build_boost.sh | 3 ++- buildscripts/libs/build_ecflow.sh | 1 + .../compiler/compilerName/compilerVersion/ecflow/ecflow.lua | 3 ++- 5 files changed, 7 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 582ba70..82114c9 100644 --- a/README.md +++ b/README.md @@ -89,6 +89,7 @@ These can be build by jedi-stack but they are not required for jedi. | geos | 3.8.1 | | | sqlite | 3.32.3 | | | proj | 7.1.0 | | +| ecflow | 5.5.3 | Requires boost, boost-python3, openssl, and qt (install via [brew](https://brew.sh/)) | # Section 2: Building the JEDI Stack diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index c2fb8a5..7fda7e6 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -121,7 +121,7 @@ build_lib SQLITE sqlite 3.32.3 build_lib PROJ proj 7.1.0 build_lib JSON json 3.9.1 build_lib JSON_SCHEMA_VALIDATOR json-schema-validator 2.1.0 -build_lib ECFLOW ecflow ecmwf 5.5.3 boost 1.73.0 +build_lib ECFLOW ecflow ecmwf 5.5.3 boost 1.68.0 #---------------------- # These must be rebuilt for each MPI implementation diff --git a/buildscripts/libs/build_boost.sh b/buildscripts/libs/build_boost.sh index 1661596..7d0cb48 100755 --- a/buildscripts/libs/build_boost.sh +++ b/buildscripts/libs/build_boost.sh @@ -70,6 +70,7 @@ compName=$(echo $compiler | cut -d- -f1) case "$compName" in gnu ) MPICC=$(which mpicc) ; toolset=gcc ;; intel ) MPICC=$(which mpiicc) ; toolset=intel ;; + clang ) MPICC=$(which mpiicc) ; toolset=clang ;; * ) echo "Unknown compiler = $compName, ABORT!"; exit 1 ;; esac @@ -85,7 +86,7 @@ EOF rm -f $HOME/user-config.jam [[ -z $mpi ]] && rm -f ./user-config.jam || mv -f ./user-config.jam $HOME -./bootstrap.sh --with-toolset=$toolset +./bootstrap.sh --with-toolset=$toolset --with-python=`which python3` ./b2 install $debug --prefix=$BoostBuild export PATH="$BoostBuild/bin:$PATH" diff --git a/buildscripts/libs/build_ecflow.sh b/buildscripts/libs/build_ecflow.sh index 9b1ddad..a05506a 100755 --- a/buildscripts/libs/build_ecflow.sh +++ b/buildscripts/libs/build_ecflow.sh @@ -39,6 +39,7 @@ else prefix=${ECFLOW_ROOT:-"/usr/local"} fi +# macOS: requires boost / boost-python3, openssl, qt host=$(uname -s) if [[ "$host" == "Darwin" ]]; then [[ -d `brew --cellar boost` ]] && boost_root=`brew --prefix boost` diff --git a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua index 1c60e4a..c450746 100644 --- a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua +++ b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua @@ -7,6 +7,7 @@ local pkgNameVer = myModuleFullName() local hierA = hierarchyA(pkgNameVer,1) local compNameVer = hierA[1] +local compNameVer = hierA[2] local compNameVerD = compNameVer:gsub("/","-") conflict(pkgName) @@ -33,5 +34,5 @@ setenv("ECFLOW_PYTHON", pathJoin(base,"lib/python@PYTHON_VERSION@/site-packages/ whatis("Name: ".. pkgName) whatis("Version: " .. pkgVersion) -whatis("Category: library") +whatis("Category: application") whatis("Description: ecFlow Workflow Manager") From d7f57b5cadcf3bfc5cddc4b04d3e2cd0c08120a6 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Thu, 11 Mar 2021 09:24:15 -0700 Subject: [PATCH 073/132] remove duplicate defn of compNameVerD lua variable --- .../compiler/compilerName/compilerVersion/ecflow/ecflow.lua | 1 - 1 file changed, 1 deletion(-) diff --git a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua index c450746..6a887da 100644 --- a/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua +++ b/modulefiles/compiler/compilerName/compilerVersion/ecflow/ecflow.lua @@ -7,7 +7,6 @@ local pkgNameVer = myModuleFullName() local hierA = hierarchyA(pkgNameVer,1) local compNameVer = hierA[1] -local compNameVer = hierA[2] local compNameVerD = compNameVer:gsub("/","-") conflict(pkgName) From 702226edec6486f4568b653198df866e065c1232 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Fri, 12 Mar 2021 10:48:26 -0700 Subject: [PATCH 074/132] clean up macOS brew config logic --- buildscripts/libs/build_ecflow.sh | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/buildscripts/libs/build_ecflow.sh b/buildscripts/libs/build_ecflow.sh index a05506a..25309c5 100755 --- a/buildscripts/libs/build_ecflow.sh +++ b/buildscripts/libs/build_ecflow.sh @@ -39,18 +39,24 @@ else prefix=${ECFLOW_ROOT:-"/usr/local"} fi -# macOS: requires boost / boost-python3, openssl, qt host=$(uname -s) if [[ "$host" == "Darwin" ]]; then [[ -d `brew --cellar boost` ]] && boost_root=`brew --prefix boost` [[ -z $boost_root ]] || echo "Using brew-installed boost headers and libraries" - export OPENSSL_ROOT_DIR=`brew --prefix openssl` - export OPENSSL_INCLUDE_DIR=$OPENSSL_ROOT_DIR/include + [[ -d `brew --cellar openssl` ]] && openssl_root=`brew --prefix openssl` + if [ -z $openssl_root ]; then + echo "OpenSSL must be installed for ecFlow, ABORT!" + exit 1 + fi [[ -d `brew --cellar qt` ]] && qt_root=`brew --prefix qt` - [[ ! -z $qt_root ]] && QT="-DCMAKE_PREFIX_PATH=$qt_root" \ - || ( echo "Qt must be installed for ecFlow UI, ABORT!" ; exit 1 ) + if [ ! -z $qt_root ]; then + QT="-DCMAKE_PREFIX_PATH=$qt_root" + else + echo "Qt must be installed for ecFlow UI, ABORT!" + exit 1 + fi fi # boost component; build if not otherwise present @@ -107,7 +113,8 @@ export CXX=$SERIAL_CXX mkdir -p build && cd build cmake -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release \ - -DBOOST_ROOT=$boost_root -DENABLE_STATIC_BOOST_LIBS=OFF $QT .. + -DBOOST_ROOT=$boost_root -DENABLE_STATIC_BOOST_LIBS=OFF \ + -DOPENSSL_ROOT_DIR=$openssl_root $QT .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install From 856fec7299b671a7cd1aff33ce99dc05733e796d Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Tue, 16 Mar 2021 18:03:01 -0600 Subject: [PATCH 075/132] updates for macOS symlink of brew packages --- README.md | 2 +- buildscripts/Mac/README.md | 17 ++++++++ buildscripts/Mac/linkBoostPythonLibsmacOS.sh | 20 +++++++++ buildscripts/Mac/linkOpenSSLmacOS.sh | 45 ++++++++++++++++++++ 4 files changed, 83 insertions(+), 1 deletion(-) create mode 100644 buildscripts/Mac/README.md create mode 100755 buildscripts/Mac/linkBoostPythonLibsmacOS.sh create mode 100755 buildscripts/Mac/linkOpenSSLmacOS.sh diff --git a/README.md b/README.md index 82114c9..d99258b 100644 --- a/README.md +++ b/README.md @@ -89,7 +89,7 @@ These can be build by jedi-stack but they are not required for jedi. | geos | 3.8.1 | | | sqlite | 3.32.3 | | | proj | 7.1.0 | | -| ecflow | 5.5.3 | Requires boost, boost-python3, openssl, and qt (install via [brew](https://brew.sh/)) | +| ecflow | 5.5.3 | Requires boost, boost-python3, openssl, and qt (install via [brew](https://brew.sh/)) see [Notes on building the Software Stack for JEDI applications on Mac OS](buildscripts/Mac/README.md)| # Section 2: Building the JEDI Stack diff --git a/buildscripts/Mac/README.md b/buildscripts/Mac/README.md new file mode 100644 index 0000000..bfaa8ae --- /dev/null +++ b/buildscripts/Mac/README.md @@ -0,0 +1,17 @@ +# Notes on building the Software Stack for JEDI applications on Mac OS + +Building the JEDI software stack on Mac OS (*catalina 10.15.7 and newer*) is described in some detail elsewhere, in particular: + +[Minimum steps for working with JEDI natively on Mac OS](https://github.com/JCSDA-internal/jedi-docs/blob/develop/howto/macos/minimum.md) + +The [brew](https://brew.sh) package manager installs packages to their own directory (/usr/local/Cellar/\) and then symlinks their files into the system location /usr/local. There are exceptions: Sometimes, brew cannot symlink to header files or libraries in /usr/local, and +for some packages that have multiple related components, they are not installed in a common root location in /usr/local/Cellar. + +If you are building the optional jedi-stack component [ecFlow](https://confluence.ecmwf.int/display/ECFLOW/ecflow+home), two scripts are provided to properly symlink software packages that ecFlow requires: + +| software | helper script | Notes | +| ------- | --------------- | ----- | +| openssl | linkOpenSSLmacOS.sh | backs up deprecated versions of system libraries and symlinks to brew's version | +| boost / boost-python3 | co-locates boost and boost-python libraries, allowing you to set the build config variable BOOST_ROOT | + +Running these scripts after installing openssl and boost / boost-python3 will properly set up symlinks for jedi-stack components that depend on them to build correctly. diff --git a/buildscripts/Mac/linkBoostPythonLibsmacOS.sh b/buildscripts/Mac/linkBoostPythonLibsmacOS.sh new file mode 100755 index 0000000..74578a8 --- /dev/null +++ b/buildscripts/Mac/linkBoostPythonLibsmacOS.sh @@ -0,0 +1,20 @@ +#!/bin/bash + +# Co-locate (via symlink) brew-installed boost / boost-python libraries and headers +e brew install boost +# brew install boost-python3 + +# Boost libraries and headers: version and location +boostLib_version=`brew list --versions | grep "boost " | cut -d ' ' -f 2` +boostLib_cellar=`brew --cellar boost` + +# Boost python libraries: version and location +boostPython_version=`brew list --versions | grep boost-python3 | cut -d ' ' -f 2` +boostPython_cellar=`brew --cellar boost-python3` + +echo 'Linking boost-python3 libraries into boost installation location' +for lib in `ls $boostPython_cellar/$boostPython_version/lib/lib*`; do + echo "Linking $lib into $boostLib_cellar/$boostLib_version/lib" + sudo ln -s $lib $boostLib_cellar/$boostLib_version/lib +done + diff --git a/buildscripts/Mac/linkOpenSSLmacOS.sh b/buildscripts/Mac/linkOpenSSLmacOS.sh new file mode 100755 index 0000000..3e1a77e --- /dev/null +++ b/buildscripts/Mac/linkOpenSSLmacOS.sh @@ -0,0 +1,45 @@ +#!/bin/bash + +# Replace macOS-supplied openssl libraries; macOS SIP often prevents proper linking +# Steps: +# brew install openssl@1.1 +# run this script + +version=`brew list --versions | grep openssl | cut -d ' ' -f 2` +cellar=`brew --cellar openssl` + +echo 'Linking openssl@1.1 v$version libraries and pkgconfig files' + +if [ -f /usr/local/lib/libssl.dylib ]; then + echo 'backing up existing libssl.dylib' + mv /usr/local/lib/libssl.dylib /usr/local/lib/libssl_bak.dylib +fi + +if [ -f /usr/local/lib/libcrypto.dylib ]; then + echo 'backing up existing libcrypto.dylib' + mv /usr/local/lib/libcrypto.dylib /usr/local/lib/libcrypto_bak.dylib +fi + +echo 'add symlink for openssl libs' + +if [ -f $cellar/$version/lib/libssl.1.1.dylib ]; then + sudo ln -s $cellar/$version/lib/libssl.1.1.dylib /usr/local/lib/libssl.dylib +fi + +if [ -f $cellar/$version/lib/libcrypto.1.1.dylib ]; then + sudo ln -s $cellar$version/lib/libcrypto.1.1.dylib /usr/local/lib/libcrypto.dylib +fi + +echo 'add symlink for openssl pkgconfig files' + +if [ -f $cellar/$version/lib/pkgconfig/openssl.pc ]; then + sudo ln -s $cellar/$version/lib/pkgconfig/openssl.pc /usr/local/lib/pkgconfig/openssl.pc +fi + +if [ -f $cellar/$version/lib/pkgconfig/libssl.pc ]; then + sudo ln -s $cellar/$version/lib/pkgconfig/libssl.pc /usr/local/lib/pkgconfig/libssl.pc +fi + +if [ -f $cellar/$version/lib/pkgconfig/libcrypto.pc ]; then + sudo ln -s $cellar/$version/lib/pkgconfig/libcrypto.pc /usr/local/lib/pkgconfig/libcrypto.pc +fi From e5b26e9668a2295a946bbd52fdd8dc6da273b59f Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Tue, 16 Mar 2021 18:11:31 -0600 Subject: [PATCH 076/132] tidy up for brew packages update --- README.md | 2 +- buildscripts/Mac/README.md | 7 +++---- buildscripts/Mac/linkBoostPythonLibsmacOS.sh | 8 ++++++-- 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index d99258b..5dca1af 100644 --- a/README.md +++ b/README.md @@ -89,7 +89,7 @@ These can be build by jedi-stack but they are not required for jedi. | geos | 3.8.1 | | | sqlite | 3.32.3 | | | proj | 7.1.0 | | -| ecflow | 5.5.3 | Requires boost, boost-python3, openssl, and qt (install via [brew](https://brew.sh/)) see [Notes on building the Software Stack for JEDI applications on Mac OS](buildscripts/Mac/README.md)| +| ecflow | 5.5.3 | Requires boost, boost-python3, openssl, and qt (install via [brew](https://brew.sh/)); see [Notes on building the Software Stack for JEDI applications on Mac OS](buildscripts/Mac/README.md)| # Section 2: Building the JEDI Stack diff --git a/buildscripts/Mac/README.md b/buildscripts/Mac/README.md index bfaa8ae..934b768 100644 --- a/buildscripts/Mac/README.md +++ b/buildscripts/Mac/README.md @@ -1,17 +1,16 @@ # Notes on building the Software Stack for JEDI applications on Mac OS -Building the JEDI software stack on Mac OS (*catalina 10.15.7 and newer*) is described in some detail elsewhere, in particular: +Installing a minimal JEDI software stack on Mac OS (*catalina 10.15.7* and newer) is described in some detail elsewhere, in particular: [Minimum steps for working with JEDI natively on Mac OS](https://github.com/JCSDA-internal/jedi-docs/blob/develop/howto/macos/minimum.md) -The [brew](https://brew.sh) package manager installs packages to their own directory (/usr/local/Cellar/\) and then symlinks their files into the system location /usr/local. There are exceptions: Sometimes, brew cannot symlink to header files or libraries in /usr/local, and -for some packages that have multiple related components, they are not installed in a common root location in /usr/local/Cellar. +The [brew](https://brew.sh) package manager installs packages to their own directory (`/usr/local/Cellar/\)` and then symlinks their files into the system location `/usr/local`. There are exceptions: Sometimes, brew cannot symlink to header files or libraries in `/usr/local`, and for some packages that have multiple related components, they are not installed in a common root location in `/usr/local/Cellar`. If you are building the optional jedi-stack component [ecFlow](https://confluence.ecmwf.int/display/ECFLOW/ecflow+home), two scripts are provided to properly symlink software packages that ecFlow requires: | software | helper script | Notes | | ------- | --------------- | ----- | | openssl | linkOpenSSLmacOS.sh | backs up deprecated versions of system libraries and symlinks to brew's version | -| boost / boost-python3 | co-locates boost and boost-python libraries, allowing you to set the build config variable BOOST_ROOT | +| boost / boost-python3 | linkBoostPythonLibsmacOS.sh | co-locates boost and boost-python libraries, allowing you to set the build config variable BOOST_ROOT | Running these scripts after installing openssl and boost / boost-python3 will properly set up symlinks for jedi-stack components that depend on them to build correctly. diff --git a/buildscripts/Mac/linkBoostPythonLibsmacOS.sh b/buildscripts/Mac/linkBoostPythonLibsmacOS.sh index 74578a8..57981c4 100755 --- a/buildscripts/Mac/linkBoostPythonLibsmacOS.sh +++ b/buildscripts/Mac/linkBoostPythonLibsmacOS.sh @@ -1,8 +1,12 @@ #!/bin/bash # Co-locate (via symlink) brew-installed boost / boost-python libraries and headers -e brew install boost -# brew install boost-python3 +# brew installs these packages in different locations; a typical build from source +# code would co-locate them, so that setting BOOST_ROOT for use in building other +# software is made easier. +# Steps: +# brew install boost boost-python3 +# run this script # Boost libraries and headers: version and location boostLib_version=`brew list --versions | grep "boost " | cut -d ' ' -f 2` From 3c67349b107f5e637400865127886155171231d7 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Tue, 16 Mar 2021 18:14:34 -0600 Subject: [PATCH 077/132] fix markdown --- buildscripts/Mac/README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/buildscripts/Mac/README.md b/buildscripts/Mac/README.md index 934b768..2f0d306 100644 --- a/buildscripts/Mac/README.md +++ b/buildscripts/Mac/README.md @@ -4,13 +4,13 @@ Installing a minimal JEDI software stack on Mac OS (*catalina 10.15.7* and newer [Minimum steps for working with JEDI natively on Mac OS](https://github.com/JCSDA-internal/jedi-docs/blob/develop/howto/macos/minimum.md) -The [brew](https://brew.sh) package manager installs packages to their own directory (`/usr/local/Cellar/\)` and then symlinks their files into the system location `/usr/local`. There are exceptions: Sometimes, brew cannot symlink to header files or libraries in `/usr/local`, and for some packages that have multiple related components, they are not installed in a common root location in `/usr/local/Cellar`. +The [brew](https://brew.sh) package manager installs packages to their own directory (`/usr/local/Cellar/)` and then symlinks their files into the system location `/usr/local`. There are exceptions: Sometimes, brew cannot symlink to header files or libraries in `/usr/local`, and for some packages that have multiple related components, they are not installed in a common root location in `/usr/local/Cellar`. If you are building the optional jedi-stack component [ecFlow](https://confluence.ecmwf.int/display/ECFLOW/ecflow+home), two scripts are provided to properly symlink software packages that ecFlow requires: | software | helper script | Notes | | ------- | --------------- | ----- | | openssl | linkOpenSSLmacOS.sh | backs up deprecated versions of system libraries and symlinks to brew's version | -| boost / boost-python3 | linkBoostPythonLibsmacOS.sh | co-locates boost and boost-python libraries, allowing you to set the build config variable BOOST_ROOT | +| boost / boost-python3 | linkBoostPythonLibsmacOS.sh | co-locates boost and boost-python libraries, allowing you to set the build config variable `BOOST_ROOT` | Running these scripts after installing openssl and boost / boost-python3 will properly set up symlinks for jedi-stack components that depend on them to build correctly. From fed4ba4effb23245290e0cc3750777bab949ef22 Mon Sep 17 00:00:00 2001 From: cgas Date: Thu, 18 Mar 2021 12:16:59 -0600 Subject: [PATCH 078/132] Typo buildscripts --- doc/Platforms.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/Platforms.md b/doc/Platforms.md index 8ce6e5b..6ab8cbb 100644 --- a/doc/Platforms.md +++ b/doc/Platforms.md @@ -59,9 +59,9 @@ To setup environment, choose a modules home directory. This can be anywhere, bu ~~~~~~~~~ $ export INTEL_ROOT= $ export JEDI_OPT=$HOME/opt/modules -$ buildscipts/setup_environment.sh gentoo -$ buildscipts/setup_modules.sh gentoo -$ buildscipts/build_stack.sh gentoo +$ buildscripts/setup_environment.sh gentoo +$ buildscripts/setup_modules.sh gentoo +$ buildscripts/build_stack.sh gentoo ~~~~~~~~~ The enthronement setup with `setup_environment.sh gentoo` generates a `$HOME/.jedi-stack-bashrc` with all the environment From 7e579d1d4ec56830c9d0add8b9b75362b0234360 Mon Sep 17 00:00:00 2001 From: Stephen Herbener Date: Fri, 19 Mar 2021 10:45:59 -0600 Subject: [PATCH 079/132] Bumped NCEPLIBS-bufr tag up to 11.4.0.jcsda2 in order to pick up necessary updates for the EMC bufr converter. --- buildscripts/build_stack.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 7fda7e6..2b33323 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -86,7 +86,7 @@ build_lib SZIP szip 2.1.1 build_lib LAPACK lapack 3.8.0 build_lib BOOST_HDRS boost 1.68.0 headers-only build_lib EIGEN3 eigen 3.3.7 -build_lib BUFR bufr jcsda-internal 11.4.0.jcsda1 +build_lib BUFR bufr jcsda-internal 11.4.0.jcsda2 build_lib ECBUILD ecbuild jcsda-internal 3.3.2.jcsda3 build_lib CGAL cgal 5.0.2 build_lib GITLFS git-lfs 2.11.0 From 39ee2cdb2747b5aae7a75d661331f82fa87528ea Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Wed, 24 Mar 2021 13:23:17 -0600 Subject: [PATCH 080/132] Use CMAKE_INSTALL_LIBDIR=lib for bufr and lapack to agree with module definitions --- buildscripts/libs/build_bufr.sh | 2 +- buildscripts/libs/build_lapack.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/buildscripts/libs/build_bufr.sh b/buildscripts/libs/build_bufr.sh index c9ac2ff..8494222 100755 --- a/buildscripts/libs/build_bufr.sh +++ b/buildscripts/libs/build_bufr.sh @@ -58,7 +58,7 @@ git checkout --detach $tag [[ -d build ]] && $SUDO rm -rf build mkdir -p build && cd build -cmake -DENABLE_PYTHON=ON -DCMAKE_INSTALL_PREFIX=$prefix .. +cmake -DENABLE_PYTHON=ON -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install diff --git a/buildscripts/libs/build_lapack.sh b/buildscripts/libs/build_lapack.sh index 57ac880..c9db5f5 100755 --- a/buildscripts/libs/build_lapack.sh +++ b/buildscripts/libs/build_lapack.sh @@ -47,8 +47,8 @@ url="https://github.com/Reference-LAPACK/lapack/archive/$tarball" [[ -d build ]] && rm -rf build # Add CMAKE_INSTALL_LIBDIR to make sure it will be installed under lib not lib64 -cmake -H. -Bbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release \ - -DCMAKE_Fortran_COMPILER=$SERIAL_FC +cmake -H. -Bbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_LIBDIR=lib \ + -DCMAKE_Fortran_COMPILER=$SERIAL_FC -DCMAKE_Fortran_FLAGS=$FCFLAGS cd build VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} [[ $MAKE_CHECK =~ [yYtT] ]] && make check From ff7b5f4fecc11ed563adc712f298303c61923eb2 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Wed, 24 Mar 2021 13:59:41 -0600 Subject: [PATCH 081/132] same fix for gsl_lite build --- buildscripts/libs/build_gsl_lite.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/buildscripts/libs/build_gsl_lite.sh b/buildscripts/libs/build_gsl_lite.sh index ea773c0..37f2249 100755 --- a/buildscripts/libs/build_gsl_lite.sh +++ b/buildscripts/libs/build_gsl_lite.sh @@ -39,7 +39,8 @@ git fetch git checkout $branch [[ -d build ]] && rm -rf build mkdir -p build && cd build -cmake -DCMAKE_INSTALL_PREFIX=$prefix -DGSL_LITE_OPT_BUILD_TESTS=OFF -DGSL_LITE_OPT_INSTALL_COMPAT_HEADER=ON -DCMAKE_VERBOSE_MAKEFILE=1 .. +cmake -DCMAKE_INSTALL_PREFIX=$prefix -DGSL_LITE_OPT_BUILD_TESTS=OFF -DGSL_LITE_OPT_INSTALL_COMPAT_HEADER=ON + -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_VERBOSE_MAKEFILE=1 .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} #[[ $MAKE_CHECK =~ [yYtT] ]] && make test VERBOSE=$MAKE_VERBOSE $SUDO make install From 83cac6eb7422bfa972c51000df8f2c20c90f564a Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Wed, 24 Mar 2021 14:58:00 -0600 Subject: [PATCH 082/132] Patched cgal-5.0.4 for intel compilation compatability --- .../libs/CGAL-5.1-intel-fpmodel-flag-fix.patch | 13 ------------- buildscripts/libs/build_cgal.sh | 4 ++-- .../patches/CGAL-5.0.4-intel-fpmodel-flag-fix.patch | 13 +++++++++++++ 3 files changed, 15 insertions(+), 15 deletions(-) delete mode 100644 buildscripts/libs/CGAL-5.1-intel-fpmodel-flag-fix.patch create mode 100644 buildscripts/libs/patches/CGAL-5.0.4-intel-fpmodel-flag-fix.patch diff --git a/buildscripts/libs/CGAL-5.1-intel-fpmodel-flag-fix.patch b/buildscripts/libs/CGAL-5.1-intel-fpmodel-flag-fix.patch deleted file mode 100644 index 9139991..0000000 --- a/buildscripts/libs/CGAL-5.1-intel-fpmodel-flag-fix.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/Installation/cmake/modules/CGAL_SetupCGALDependencies.cmake b/Installation/cmake/modules/CGAL_SetupCGALDependencies.cmake -index 6590e31f94..55c783f41c 100644 ---- a/Installation/cmake/modules/CGAL_SetupCGALDependencies.cmake -+++ b/Installation/cmake/modules/CGAL_SetupCGALDependencies.cmake -@@ -147,7 +147,7 @@ function(CGAL_setup_CGAL_dependencies target) - if(WIN32) - target_compile_options(${target} ${keyword} "/fp:strict") - else() -- target_compile_options(${target} ${keyword} "-fp-model" "strict") -+ target_compile_options(${target} ${keyword} "SHELL:-fp-model strict") - endif() - elseif(CMAKE_CXX_COMPILER_ID MATCHES "SunPro") - message( STATUS "Using SunPro compiler, using STLPort 4." ) diff --git a/buildscripts/libs/build_cgal.sh b/buildscripts/libs/build_cgal.sh index 62ffdc1..cc4805a 100755 --- a/buildscripts/libs/build_cgal.sh +++ b/buildscripts/libs/build_cgal.sh @@ -54,8 +54,8 @@ url="https://github.com/CGAL/cgal/releases/download/v$version/$software-library. [[ -d $software ]] || ( $WGET $url; tar -xf $software-library.tar.xz ) [[ ${DOWNLOAD_ONLY} =~ [yYtT] ]] && exit 0 [[ -d $software ]] && cd $software || ( echo "$software does not exist, ABORT!"; exit 1 ) -if [[ $version == "5.1" ]]; then - git apply ${JEDI_STACK_ROOT}/buildscripts/libs/${software}-intel-fpmodel-flag-fix.patch +if [[ $version == "5.0.4" ]]; then + git apply ${JEDI_STACK_ROOT}/buildscripts/libs/patches/${software}-intel-fpmodel-flag-fix.patch else exit 1 fi diff --git a/buildscripts/libs/patches/CGAL-5.0.4-intel-fpmodel-flag-fix.patch b/buildscripts/libs/patches/CGAL-5.0.4-intel-fpmodel-flag-fix.patch new file mode 100644 index 0000000..9d8f425 --- /dev/null +++ b/buildscripts/libs/patches/CGAL-5.0.4-intel-fpmodel-flag-fix.patch @@ -0,0 +1,13 @@ +diff --git a/cmake/modules/CGAL_SetupCGALDependencies.cmake b/cmake/modules/CGAL_SetupCGALDependencies.cmake +index 6590e31..55c783f 100644 +--- a/cmake/modules/CGAL_SetupCGALDependencies.cmake ++++ b/cmake/modules/CGAL_SetupCGALDependencies.cmake +@@ -147,7 +147,7 @@ function(CGAL_setup_CGAL_dependencies target) + if(WIN32) + target_compile_options(${target} ${keyword} "/fp:strict") + else() +- target_compile_options(${target} ${keyword} "-fp-model" "strict") ++ target_compile_options(${target} ${keyword} "$<1:-fp-model strict>") # Genexpr enforces grouping of args + endif() + elseif(CMAKE_CXX_COMPILER_ID MATCHES "SunPro") + message( STATUS "Using SunPro compiler, using STLPort 4." ) From b9d626fbada8ad51e6007495a85adebf4429cb29 Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Wed, 24 Mar 2021 15:23:25 -0600 Subject: [PATCH 083/132] Improve error message and doc --- buildscripts/libs/build_cgal.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/buildscripts/libs/build_cgal.sh b/buildscripts/libs/build_cgal.sh index cc4805a..523c9de 100755 --- a/buildscripts/libs/build_cgal.sh +++ b/buildscripts/libs/build_cgal.sh @@ -54,9 +54,13 @@ url="https://github.com/CGAL/cgal/releases/download/v$version/$software-library. [[ -d $software ]] || ( $WGET $url; tar -xf $software-library.tar.xz ) [[ ${DOWNLOAD_ONLY} =~ [yYtT] ]] && exit 0 [[ -d $software ]] && cd $software || ( echo "$software does not exist, ABORT!"; exit 1 ) + +# Apply a patch to fix CMake intel compiler flags. +# Remove when possible or update as needed. if [[ $version == "5.0.4" ]]; then git apply ${JEDI_STACK_ROOT}/buildscripts/libs/patches/${software}-intel-fpmodel-flag-fix.patch else + echo "Error: Must generate new patch for unsupported CGal version: $version" exit 1 fi From 7dbc3da2625771f7643c7f911161ba9f81dbb4e2 Mon Sep 17 00:00:00 2001 From: Stephen Herbener Date: Thu, 25 Mar 2021 10:57:43 -0600 Subject: [PATCH 084/132] Removed newline in middle of cmake call for build_gsl_lite.sh --- buildscripts/libs/build_gsl_lite.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/buildscripts/libs/build_gsl_lite.sh b/buildscripts/libs/build_gsl_lite.sh index 37f2249..ebae604 100755 --- a/buildscripts/libs/build_gsl_lite.sh +++ b/buildscripts/libs/build_gsl_lite.sh @@ -39,8 +39,7 @@ git fetch git checkout $branch [[ -d build ]] && rm -rf build mkdir -p build && cd build -cmake -DCMAKE_INSTALL_PREFIX=$prefix -DGSL_LITE_OPT_BUILD_TESTS=OFF -DGSL_LITE_OPT_INSTALL_COMPAT_HEADER=ON - -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_VERBOSE_MAKEFILE=1 .. +cmake -DCMAKE_INSTALL_PREFIX=$prefix -DGSL_LITE_OPT_BUILD_TESTS=OFF -DGSL_LITE_OPT_INSTALL_COMPAT_HEADER=ON -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_VERBOSE_MAKEFILE=1 .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} #[[ $MAKE_CHECK =~ [yYtT] ]] && make test VERBOSE=$MAKE_VERBOSE $SUDO make install From 690cb4004295a6335077974341605e9a3fda94c6 Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Fri, 26 Mar 2021 12:22:04 -0600 Subject: [PATCH 085/132] Fix CMAKE_INSTALL_LIBDIR=lib --- buildscripts/libs/build_cgal.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/buildscripts/libs/build_cgal.sh b/buildscripts/libs/build_cgal.sh index 523c9de..73957ba 100755 --- a/buildscripts/libs/build_cgal.sh +++ b/buildscripts/libs/build_cgal.sh @@ -64,9 +64,10 @@ else exit 1 fi - -cmake . -DCMAKE_INSTALL_PREFIX=$prefix -DWITH_CGAL_Qt5=0 -DCGAL_DISABLE_GMP=1 -DEIGEN3_INCLUDE_DIR=$EIGEN_ROOT/include -VERBOSE=$MAKE_VERBOSE $SUDO make install +BUILD_DIR="$(pwd)/${software}/_build" +[[ -d $BUILD_DIR ]] && rm -rf $BUILD_DIR +cmake -H. -B_build -DCMAKE_INSTALL_PREFIX=$prefix -DWITH_CGAL_Qt5=0 -DCGAL_DISABLE_GMP=1 -DEIGEN3_INCLUDE_DIR=$EIGEN_ROOT/include -DCMAKE_INSTALL_LIBDIR=lib +cd _build && VERBOSE=$MAKE_VERBOSE $SUDO make install # generate modulefile from template $MODULES && update_modules core $name $version \ From 513b14f501536173a3753f4e40b2fe7ce2190de5 Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Fri, 26 Mar 2021 12:25:30 -0600 Subject: [PATCH 086/132] Remove incorrect CMake enivronment variables for CGAL module --- modulefiles/core/cgal/cgal.lua | 2 -- 1 file changed, 2 deletions(-) diff --git a/modulefiles/core/cgal/cgal.lua b/modulefiles/core/cgal/cgal.lua index 6dcc0d9..6f8fcb8 100644 --- a/modulefiles/core/cgal/cgal.lua +++ b/modulefiles/core/cgal/cgal.lua @@ -18,8 +18,6 @@ prepend_path("CPATH", pathJoin(base,"include")) prepend_path("MANPATH", pathJoin(base,"share","man")) setenv("CGAL_ROOT", base) -setenv("CGAL_PATH", base) -setenv("CGAL_DIR", base) setenv("CGAL_INCLUDE_DIRS", pathJoin(base,"include")) setenv("CGAL_LIBRARIES", pathJoin(base,"lib")) setenv("CGAL_VERSION", pkgVersion) From 8e55d7610ef830c1d47ff071c2a7c81ae37bd77b Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Fri, 26 Mar 2021 13:14:23 -0600 Subject: [PATCH 087/132] Fix for cgal _build directory --- buildscripts/libs/build_cgal.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/buildscripts/libs/build_cgal.sh b/buildscripts/libs/build_cgal.sh index 73957ba..e5c2f53 100755 --- a/buildscripts/libs/build_cgal.sh +++ b/buildscripts/libs/build_cgal.sh @@ -64,8 +64,7 @@ else exit 1 fi -BUILD_DIR="$(pwd)/${software}/_build" -[[ -d $BUILD_DIR ]] && rm -rf $BUILD_DIR +[[ -d _build ]] && rm -rf _build cmake -H. -B_build -DCMAKE_INSTALL_PREFIX=$prefix -DWITH_CGAL_Qt5=0 -DCGAL_DISABLE_GMP=1 -DEIGEN3_INCLUDE_DIR=$EIGEN_ROOT/include -DCMAKE_INSTALL_LIBDIR=lib cd _build && VERBOSE=$MAKE_VERBOSE $SUDO make install From 95220e574720493057eda1c232968903fec85157 Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Tue, 30 Mar 2021 17:46:10 -0600 Subject: [PATCH 088/132] Use patch utility to apply patch --- buildscripts/libs/build_cgal.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_cgal.sh b/buildscripts/libs/build_cgal.sh index e5c2f53..63c5148 100755 --- a/buildscripts/libs/build_cgal.sh +++ b/buildscripts/libs/build_cgal.sh @@ -58,7 +58,7 @@ url="https://github.com/CGAL/cgal/releases/download/v$version/$software-library. # Apply a patch to fix CMake intel compiler flags. # Remove when possible or update as needed. if [[ $version == "5.0.4" ]]; then - git apply ${JEDI_STACK_ROOT}/buildscripts/libs/patches/${software}-intel-fpmodel-flag-fix.patch + patch --merge -p1 < ${JEDI_STACK_ROOT}/buildscripts/libs/patches/${software}-intel-fpmodel-flag-fix.patch else echo "Error: Must generate new patch for unsupported CGal version: $version" exit 1 From f63e19ebb8f55d15f60605094aacaa289aa88683 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 31 Mar 2021 14:52:40 -0600 Subject: [PATCH 089/132] upgrade ecbuild, eckit, fckit, atlas --- buildscripts/build_stack.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 2b33323..b251509 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -87,7 +87,7 @@ build_lib LAPACK lapack 3.8.0 build_lib BOOST_HDRS boost 1.68.0 headers-only build_lib EIGEN3 eigen 3.3.7 build_lib BUFR bufr jcsda-internal 11.4.0.jcsda2 -build_lib ECBUILD ecbuild jcsda-internal 3.3.2.jcsda3 +build_lib ECBUILD ecbuild ecmwf 3.5.0 build_lib CGAL cgal 5.0.2 build_lib GITLFS git-lfs 2.11.0 @@ -97,9 +97,9 @@ build_lib HDF5 hdf5 1.12.0 build_lib PNETCDF pnetcdf 1.12.1 build_lib NETCDF netcdf 4.7.4 4.5.3 4.3.0 build_lib NCCMP nccmp 1.8.7.0 -build_lib ECKIT eckit jcsda-internal 1.11.6.jcsda2 -build_lib FCKIT fckit jcsda-internal 0.7.0.jcsda1 -build_lib ATLAS atlas jcsda-internal 0.20.2.jcsda1 +build_lib ECKIT eckit ecmwf 1.15. +build_lib FCKIT fckit ecmwf 0.9.1 +build_lib ATLAS atlas ecmwf 0.23.0 build_lib ODB odb 0.18.1.r2 build_lib ODC odc jcsda-internal 1.0.3 From fe4e66d7745e739b0380aa7cf79b132a1f9abba3 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 31 Mar 2021 15:11:17 -0600 Subject: [PATCH 090/132] typo --- buildscripts/build_stack.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index b251509..49b1aa5 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -97,7 +97,7 @@ build_lib HDF5 hdf5 1.12.0 build_lib PNETCDF pnetcdf 1.12.1 build_lib NETCDF netcdf 4.7.4 4.5.3 4.3.0 build_lib NCCMP nccmp 1.8.7.0 -build_lib ECKIT eckit ecmwf 1.15. +build_lib ECKIT eckit ecmwf 1.15.4 build_lib FCKIT fckit ecmwf 0.9.1 build_lib ATLAS atlas ecmwf 0.23.0 build_lib ODB odb 0.18.1.r2 From 45671ac27f8b930038bbf9c6c0dd8205def4d1e4 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Thu, 1 Apr 2021 17:19:54 -0600 Subject: [PATCH 091/132] eckit 1.16 released! --- buildscripts/build_stack.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 49b1aa5..b3d1f21 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -97,7 +97,7 @@ build_lib HDF5 hdf5 1.12.0 build_lib PNETCDF pnetcdf 1.12.1 build_lib NETCDF netcdf 4.7.4 4.5.3 4.3.0 build_lib NCCMP nccmp 1.8.7.0 -build_lib ECKIT eckit ecmwf 1.15.4 +build_lib ECKIT eckit ecmwf 1.16.0 build_lib FCKIT fckit ecmwf 0.9.1 build_lib ATLAS atlas ecmwf 0.23.0 build_lib ODB odb 0.18.1.r2 From 99710aa7709138c541555c2d849079634d394342 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Thu, 1 Apr 2021 17:22:51 -0600 Subject: [PATCH 092/132] also new versions of fckit, ecbuild --- buildscripts/build_stack.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index b3d1f21..19a69b7 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -87,7 +87,7 @@ build_lib LAPACK lapack 3.8.0 build_lib BOOST_HDRS boost 1.68.0 headers-only build_lib EIGEN3 eigen 3.3.7 build_lib BUFR bufr jcsda-internal 11.4.0.jcsda2 -build_lib ECBUILD ecbuild ecmwf 3.5.0 +build_lib ECBUILD ecbuild ecmwf 3.6.1 build_lib CGAL cgal 5.0.2 build_lib GITLFS git-lfs 2.11.0 @@ -98,7 +98,7 @@ build_lib PNETCDF pnetcdf 1.12.1 build_lib NETCDF netcdf 4.7.4 4.5.3 4.3.0 build_lib NCCMP nccmp 1.8.7.0 build_lib ECKIT eckit ecmwf 1.16.0 -build_lib FCKIT fckit ecmwf 0.9.1 +build_lib FCKIT fckit ecmwf 0.9.2 build_lib ATLAS atlas ecmwf 0.23.0 build_lib ODB odb 0.18.1.r2 build_lib ODC odc jcsda-internal 1.0.3 From 17e8b60ea0b43ba6ffeddec3efd4632ffd2c91ad Mon Sep 17 00:00:00 2001 From: mmiesch Date: Thu, 1 Apr 2021 17:35:58 -0600 Subject: [PATCH 093/132] modified build scripts for new ecbuild --- buildscripts/libs/build_atlas.sh | 2 +- buildscripts/libs/build_eckit.sh | 2 +- buildscripts/libs/build_fckit.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/buildscripts/libs/build_atlas.sh b/buildscripts/libs/build_atlas.sh index 713bfc8..c937f70 100755 --- a/buildscripts/libs/build_atlas.sh +++ b/buildscripts/libs/build_atlas.sh @@ -51,7 +51,7 @@ git checkout $version [[ -d build ]] && $SUDO rm -rf build mkdir -p build && cd build -ecbuild --prefix=$prefix --build=Release .. +ecbuild --prefix=$prefix --build=release .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make -j${NTHREADS:-4} install diff --git a/buildscripts/libs/build_eckit.sh b/buildscripts/libs/build_eckit.sh index 42145de..ea93b4b 100755 --- a/buildscripts/libs/build_eckit.sh +++ b/buildscripts/libs/build_eckit.sh @@ -53,7 +53,7 @@ sed -i -e 's/project( eckit CXX/project( eckit CXX Fortran/' CMakeLists.txt [[ -d build ]] && $SUDO rm -rf build mkdir -p build && cd build -ecbuild -DCMAKE_INSTALL_PREFIX=$prefix --build=Release .. +ecbuild --build=release --prefix=$prefix .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install diff --git a/buildscripts/libs/build_fckit.sh b/buildscripts/libs/build_fckit.sh index 957f400..c590ff4 100755 --- a/buildscripts/libs/build_fckit.sh +++ b/buildscripts/libs/build_fckit.sh @@ -49,7 +49,7 @@ git checkout $version [[ -d build ]] && $SUDO rm -rf build mkdir -p build && cd build -ecbuild -DCMAKE_INSTALL_PREFIX=$prefix --build=Release .. +ecbuild --build=release --prefix=$prefix .. VERBOSE=$MAKE_VERBOSE $SUDO make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install From 29616f65233a7abebb654fa7b1d8d6db84a131fb Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 7 Apr 2021 16:03:07 -0600 Subject: [PATCH 094/132] new atlas realease --- buildscripts/build_stack.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 6ac33c4..19ad25d 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -99,7 +99,7 @@ build_lib NETCDF netcdf 4.7.4 4.5.3 4.3.0 build_lib NCCMP nccmp 1.8.7.0 build_lib ECKIT eckit ecmwf 1.16.0 build_lib FCKIT fckit ecmwf 0.9.2 -build_lib ATLAS atlas ecmwf 0.23.0 +build_lib ATLAS atlas ecmwf 0.24.1 build_lib ODB odb 0.18.1.r2 build_lib ODC odc jcsda-internal 1.0.3 From 339f355cc4bd98049f2ba1dac36589f4b731fbed Mon Sep 17 00:00:00 2001 From: mmiesch Date: Sat, 17 Apr 2021 09:07:12 -0600 Subject: [PATCH 095/132] add a config for gnu stack on AWS --- .../config/config_ami-gnu-openmpi-dev.sh | 85 +++++++++++++++++++ .../config_container-gnu-openmpi-dev.sh | 8 +- 2 files changed, 89 insertions(+), 4 deletions(-) create mode 100644 buildscripts/config/config_ami-gnu-openmpi-dev.sh diff --git a/buildscripts/config/config_ami-gnu-openmpi-dev.sh b/buildscripts/config/config_ami-gnu-openmpi-dev.sh new file mode 100644 index 0000000..bb22f96 --- /dev/null +++ b/buildscripts/config/config_ami-gnu-openmpi-dev.sh @@ -0,0 +1,85 @@ +#!/bin/bash +# © Copyright 2020 UCAR +# This software is licensed under the terms of the Apache Licence Version 2.0 which can be obtained at +# http://www.apache.org/licenses/LICENSE-2.0. + + +# Compiler/MPI combination +export JEDI_COMPILER="gnu/7.3.0" +export JEDI_MPI="openmpi/3.1.2" + +# This tells jedi-stack how you want to build the compiler and mpi modules +# valid options include: +# native-module: load a pre-existing module (common for HPC systems) +# native-pkg: use pre-installed executables located in /usr/bin or /usr/local/bin, +# as installed by package managers like apt-get or hombrewo. +# This is a common option for, e.g., gcc/g++/gfortrant +# from-source: This is to build from source +export COMPILER_BUILD="native-pkg" +export MPI_BUILD="from-source" + +# Build options +export PREFIX=/usr/local +export USE_SUDO=N +export PKGDIR=pkg +export LOGDIR=buildscripts/log +export OVERWRITE=N +export NTHREADS=4 +export MAKE_CHECK=N +export MAKE_VERBOSE=N +export MAKE_CLEAN=Y +export DOWNLOAD_ONLY=F +export STACK_EXIT_ON_FAIL=T +export WGET="wget -nv" +#Global compiler flags +export FFLAGS="" +export CFLAGS="" +export CXXFLAGS="" +export LDFLAGS="" + +# Minimal JEDI Stack +export STACK_BUILD_CMAKE=N +export STACK_BUILD_GITLFS=N +export STACK_BUILD_SZIP=Y +export STACK_BUILD_UDUNITS=Y +export STACK_BUILD_ZLIB=Y +export STACK_BUILD_LAPACK=Y +export STACK_BUILD_BOOST_HDRS=Y +export STACK_BUILD_EIGEN3=Y +export STACK_BUILD_HDF5=Y +export STACK_BUILD_BUFR=Y +export STACK_BUILD_PNETCDF=Y +export STACK_BUILD_NETCDF=Y +export STACK_BUILD_NCCMP=Y +export STACK_BUILD_NCO=Y +export STACK_BUILD_ECBUILD=Y +export STACK_BUILD_ECKIT=Y +export STACK_BUILD_FCKIT=N +export STACK_BUILD_ATLAS=N +export STACK_BUILD_PYBIND11=Y +export STACK_BUILD_GSL_LITE=Y + +# Optional Additions +export STACK_BUILD_ODC=N +export STACK_BUILD_PIO=Y +export STACK_BUILD_GPTL=N +export STACK_BUILD_PYJEDI=Y +export STACK_BUILD_NCEPLIBS=N +export STACK_BUILD_JPEG=N +export STACK_BUILD_PNG=N +export STACK_BUILD_JASPER=N +export STACK_BUILD_ARMADILLO=N +export STACK_BUILD_XERCES=N +export STACK_BUILD_TKDIFF=N +export STACK_BUILD_BOOST_FULL=N +export STACK_BUILD_ESMF=N +export STACK_BUILD_BASELIBS=N +export STACK_BUILD_PDTOOLKIT=N +export STACK_BUILD_TAU2=N +export STACK_BUILD_CGAL=Y +export STACK_BUILD_GEOS=N +export STACK_BUILD_SQLITE=N +export STACK_BUILD_PROJ=N +export STACK_BUILD_JSON=Y +export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y +export STACK_BUILD_FMS=N diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index bb22f96..3c23340 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -5,8 +5,8 @@ # Compiler/MPI combination -export JEDI_COMPILER="gnu/7.3.0" -export JEDI_MPI="openmpi/3.1.2" +export JEDI_COMPILER="gnu/9.3.0" +export JEDI_MPI="openmpi/4.1.0" # This tells jedi-stack how you want to build the compiler and mpi modules # valid options include: @@ -19,7 +19,7 @@ export COMPILER_BUILD="native-pkg" export MPI_BUILD="from-source" # Build options -export PREFIX=/usr/local +export PREFIX=/optjedi export USE_SUDO=N export PKGDIR=pkg export LOGDIR=buildscripts/log @@ -38,7 +38,7 @@ export CXXFLAGS="" export LDFLAGS="" # Minimal JEDI Stack -export STACK_BUILD_CMAKE=N +export STACK_BUILD_CMAKE=Y export STACK_BUILD_GITLFS=N export STACK_BUILD_SZIP=Y export STACK_BUILD_UDUNITS=Y From 2dc9427b2d31fdb11e5206333d2c7c6bb4f1f25c Mon Sep 17 00:00:00 2001 From: mmiesch Date: Sat, 17 Apr 2021 09:40:07 -0600 Subject: [PATCH 096/132] add intel ami builder and update cmake --- buildscripts/build_stack.sh | 2 +- .../config/config_ami-gnu-openmpi-dev.sh | 2 +- .../config/config_ami-intel-impi-dev.sh | 86 +++++++++++++++++++ buildscripts/libs/build_cmake.sh | 1 - 4 files changed, 88 insertions(+), 3 deletions(-) create mode 100644 buildscripts/config/config_ami-intel-impi-dev.sh diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 8e02092..9e3dd78 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -77,7 +77,7 @@ $MODULES && (set +x; source $MODULESHOME/init/bash; module purge; set -x) # - should add a check at some point to see if they are already there. # this can be done in each script individually # it might warrant a --force flag to force rebuild when desired -build_lib CMAKE cmake 3.17.2 +build_lib CMAKE cmake 3.20.0 build_lib UDUNITS udunits 2.2.28 build_lib JPEG jpeg 9.1.0 build_lib ZLIB zlib 1.2.11 diff --git a/buildscripts/config/config_ami-gnu-openmpi-dev.sh b/buildscripts/config/config_ami-gnu-openmpi-dev.sh index bb22f96..71115ed 100644 --- a/buildscripts/config/config_ami-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_ami-gnu-openmpi-dev.sh @@ -38,7 +38,7 @@ export CXXFLAGS="" export LDFLAGS="" # Minimal JEDI Stack -export STACK_BUILD_CMAKE=N +export STACK_BUILD_CMAKE=Y export STACK_BUILD_GITLFS=N export STACK_BUILD_SZIP=Y export STACK_BUILD_UDUNITS=Y diff --git a/buildscripts/config/config_ami-intel-impi-dev.sh b/buildscripts/config/config_ami-intel-impi-dev.sh new file mode 100644 index 0000000..dbd666b --- /dev/null +++ b/buildscripts/config/config_ami-intel-impi-dev.sh @@ -0,0 +1,86 @@ +#!/bin/bash +# © Copyright 2020 UCAR +# This software is licensed under the terms of the Apache Licence Version 2.0 which can be obtained at +# http://www.apache.org/licenses/LICENSE-2.0. + + +# Compiler/MPI combination +export JEDI_COMPILER="intel/2021.1" +export JEDI_MPI="impi/2021.1" +export PATH=/usr/local/bin:$PATH +export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH +export LIBRARY_PATH=/usr/local/lib:$LIBRARY_PATH +export CPATH=/usr/local/include:$CPATH + +# This tells jedi-stack how you want to build the compiler and mpi modules +# valid options include: +# native-module: load a pre-existing module (common for HPC systems) +# native-pkg: use pre-installed executables located in /usr/bin or /usr/local/bin, +# as installed by package managers like apt-get or hombrewo. +# This is a common option for, e.g., gcc/g++/gfortran +# from-source: This is to build from source +export COMPILER_BUILD="native-pkg" +export MPI_BUILD="native-pkg" + +# Build options +export PREFIX=/optjedi/modules +export USE_SUDO=N +export PKGDIR=pkg +export LOGDIR=buildscripts/log +export OVERWRITE=N +export NTHREADS=4 +export MAKE_CHECK=N +export MAKE_VERBOSE=Y +export MAKE_CLEAN=N +export DOWNLOAD_ONLY=F +export STACK_EXIT_ON_FAIL=T +export WGET="wget -nv" +#Global compiler flags +export FFLAGS="" +export CFLAGS="" +export CXXFLAGS="" +export LDFLAGS="" + +# Minimal JEDI Stack +export STACK_BUILD_CMAKE=N +export STACK_BUILD_GITLFS=N +export STACK_BUILD_SZIP=Y +export STACK_BUILD_UDUNITS=Y +export STACK_BUILD_ZLIB=Y +export STACK_BUILD_LAPACK=N +export STACK_BUILD_BOOST_HDRS=N +export STACK_BUILD_EIGEN3=N +export STACK_BUILD_BUFR=Y +export STACK_BUILD_HDF5=Y +export STACK_BUILD_PNETCDF=Y +export STACK_BUILD_NETCDF=Y +export STACK_BUILD_NCCMP=Y +export STACK_BUILD_NCO=N +export STACK_BUILD_ECBUILD=N +export STACK_BUILD_ECKIT=Y +export STACK_BUILD_FCKIT=Y +export STACK_BUILD_ATLAS=Y +export STACK_BUILD_PYBIND11=N +export STACK_BUILD_GSL_LITE=N + +# Optional Additions +export STACK_BUILD_ODC=N +export STACK_BUILD_PIO=N +export STACK_BUILD_GPTL=N +export STACK_BUILD_PYJEDI=N +export STACK_BUILD_NCEPLIBS=N +export STACK_BUILD_JPEG=N +export STACK_BUILD_PNG=N +export STACK_BUILD_JASPER=N +export STACK_BUILD_ARMADILLO=N +export STACK_BUILD_XERCES=N +export STACK_BUILD_TKDIFF=N +export STACK_BUILD_BOOST_FULL=N +export STACK_BUILD_ESMF=N +export STACK_BUILD_BASELIBS=N +export STACK_BUILD_PDTOOLKIT=N +export STACK_BUILD_TAU2=N +export STACK_BUILD_CGAL=N +export STACK_BUILD_JSON=N +export STACK_BUILD_JSON_SCHEMA_VALIDATOR=N +export STACK_BUILD_FMS=N diff --git a/buildscripts/libs/build_cmake.sh b/buildscripts/libs/build_cmake.sh index 78e045c..006ba17 100755 --- a/buildscripts/libs/build_cmake.sh +++ b/buildscripts/libs/build_cmake.sh @@ -15,7 +15,6 @@ version=$1 if $MODULES; then module load jedi-$JEDI_COMPILER - module try-load cmake module list prefix="${PREFIX:-"/opt/modules"}/core/$name/$version" From b9bc98baaef6abcf8bab34b92b80752c7effcad1 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Sat, 17 Apr 2021 10:09:21 -0600 Subject: [PATCH 097/132] configuration tweaks --- buildscripts/config/config_ami-gnu-openmpi-dev.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/buildscripts/config/config_ami-gnu-openmpi-dev.sh b/buildscripts/config/config_ami-gnu-openmpi-dev.sh index 71115ed..6edc281 100644 --- a/buildscripts/config/config_ami-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_ami-gnu-openmpi-dev.sh @@ -19,7 +19,7 @@ export COMPILER_BUILD="native-pkg" export MPI_BUILD="from-source" # Build options -export PREFIX=/usr/local +export PREFIX=/optjedi/modules export USE_SUDO=N export PKGDIR=pkg export LOGDIR=buildscripts/log @@ -54,16 +54,16 @@ export STACK_BUILD_NCCMP=Y export STACK_BUILD_NCO=Y export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y -export STACK_BUILD_FCKIT=N -export STACK_BUILD_ATLAS=N +export STACK_BUILD_FCKIT=Y +export STACK_BUILD_ATLAS=Y export STACK_BUILD_PYBIND11=Y export STACK_BUILD_GSL_LITE=Y # Optional Additions export STACK_BUILD_ODC=N -export STACK_BUILD_PIO=Y +export STACK_BUILD_PIO=N export STACK_BUILD_GPTL=N -export STACK_BUILD_PYJEDI=Y +export STACK_BUILD_PYJEDI=N export STACK_BUILD_NCEPLIBS=N export STACK_BUILD_JPEG=N export STACK_BUILD_PNG=N From 0328faa60d8d52e7342949611c84afbe4666d8dd Mon Sep 17 00:00:00 2001 From: mmiesch Date: Sun, 18 Apr 2021 18:59:57 +0000 Subject: [PATCH 098/132] config updates --- buildscripts/config/config_ami-gnu-openmpi-dev.sh | 6 +++--- buildscripts/config/config_ami-intel-impi-dev.sh | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/buildscripts/config/config_ami-gnu-openmpi-dev.sh b/buildscripts/config/config_ami-gnu-openmpi-dev.sh index 6edc281..c8c3a5c 100644 --- a/buildscripts/config/config_ami-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_ami-gnu-openmpi-dev.sh @@ -5,8 +5,8 @@ # Compiler/MPI combination -export JEDI_COMPILER="gnu/7.3.0" -export JEDI_MPI="openmpi/3.1.2" +export JEDI_COMPILER="gnu/9.3.0" +export JEDI_MPI="openmpi/4.1.0" # This tells jedi-stack how you want to build the compiler and mpi modules # valid options include: @@ -20,7 +20,7 @@ export MPI_BUILD="from-source" # Build options export PREFIX=/optjedi/modules -export USE_SUDO=N +export USE_SUDO=Y export PKGDIR=pkg export LOGDIR=buildscripts/log export OVERWRITE=N diff --git a/buildscripts/config/config_ami-intel-impi-dev.sh b/buildscripts/config/config_ami-intel-impi-dev.sh index dbd666b..c74734a 100644 --- a/buildscripts/config/config_ami-intel-impi-dev.sh +++ b/buildscripts/config/config_ami-intel-impi-dev.sh @@ -24,7 +24,7 @@ export MPI_BUILD="native-pkg" # Build options export PREFIX=/optjedi/modules -export USE_SUDO=N +export USE_SUDO=Y export PKGDIR=pkg export LOGDIR=buildscripts/log export OVERWRITE=N From cecae2f0984828374fbb356db94ad60935f8bf5b Mon Sep 17 00:00:00 2001 From: mmiesch Date: Sun, 18 Apr 2021 19:12:56 +0000 Subject: [PATCH 099/132] use choose_modules for amis --- buildscripts/config/choose_modules.sh | 16 ++--- .../config/config_ami-gnu-openmpi-dev.sh | 46 -------------- .../config/config_ami-intel-impi-dev.sh | 62 ------------------- 3 files changed, 8 insertions(+), 116 deletions(-) diff --git a/buildscripts/config/choose_modules.sh b/buildscripts/config/choose_modules.sh index f81e997..7b62d4d 100644 --- a/buildscripts/config/choose_modules.sh +++ b/buildscripts/config/choose_modules.sh @@ -4,12 +4,12 @@ # http://www.apache.org/licenses/LICENSE-2.0. # Minimal JEDI Stack -export STACK_BUILD_CMAKE=N +export STACK_BUILD_CMAKE=Y export STACK_BUILD_GITLFS=N export STACK_BUILD_SZIP=Y export STACK_BUILD_UDUNITS=Y export STACK_BUILD_ZLIB=Y -export STACK_BUILD_LAPACK=N +export STACK_BUILD_LAPACK=Y export STACK_BUILD_BOOST_HDRS=Y export STACK_BUILD_BUFR=Y export STACK_BUILD_EIGEN3=Y @@ -19,17 +19,17 @@ export STACK_BUILD_NETCDF=Y export STACK_BUILD_NCCMP=Y export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y -export STACK_BUILD_FCKIT=N -export STACK_BUILD_ATLAS=N +export STACK_BUILD_FCKIT=Y +export STACK_BUILD_ATLAS=Y export STACK_BUILD_GSL_LITE=Y export STACK_BUILD_PYBIND11=Y # Optional Additions export STACK_BUILD_ODC=N -export STACK_BUILD_PIO=Y +export STACK_BUILD_PIO=N export STACK_BUILD_GPTL=N export STACK_BUILD_NCO=N -export STACK_BUILD_PYJEDI=Y +export STACK_BUILD_PYJEDI=N export STACK_BUILD_NCEPLIBS=N export STACK_BUILD_JPEG=N export STACK_BUILD_PNG=N @@ -47,6 +47,6 @@ export STACK_BUILD_GEOS=N export STACK_BUILD_SQLITE=N export STACK_BUILD_PROJ=N export STACK_BUILD_FMS=N -export STACK_BUILD_JSON=N -export STACK_BUILD_JSON_SCHEMA_VALIDATOR=N +export STACK_BUILD_JSON=Y +export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y export STACK_BUILD_ECFLOW=N diff --git a/buildscripts/config/config_ami-gnu-openmpi-dev.sh b/buildscripts/config/config_ami-gnu-openmpi-dev.sh index c8c3a5c..cf73fb6 100644 --- a/buildscripts/config/config_ami-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_ami-gnu-openmpi-dev.sh @@ -37,49 +37,3 @@ export CFLAGS="" export CXXFLAGS="" export LDFLAGS="" -# Minimal JEDI Stack -export STACK_BUILD_CMAKE=Y -export STACK_BUILD_GITLFS=N -export STACK_BUILD_SZIP=Y -export STACK_BUILD_UDUNITS=Y -export STACK_BUILD_ZLIB=Y -export STACK_BUILD_LAPACK=Y -export STACK_BUILD_BOOST_HDRS=Y -export STACK_BUILD_EIGEN3=Y -export STACK_BUILD_HDF5=Y -export STACK_BUILD_BUFR=Y -export STACK_BUILD_PNETCDF=Y -export STACK_BUILD_NETCDF=Y -export STACK_BUILD_NCCMP=Y -export STACK_BUILD_NCO=Y -export STACK_BUILD_ECBUILD=Y -export STACK_BUILD_ECKIT=Y -export STACK_BUILD_FCKIT=Y -export STACK_BUILD_ATLAS=Y -export STACK_BUILD_PYBIND11=Y -export STACK_BUILD_GSL_LITE=Y - -# Optional Additions -export STACK_BUILD_ODC=N -export STACK_BUILD_PIO=N -export STACK_BUILD_GPTL=N -export STACK_BUILD_PYJEDI=N -export STACK_BUILD_NCEPLIBS=N -export STACK_BUILD_JPEG=N -export STACK_BUILD_PNG=N -export STACK_BUILD_JASPER=N -export STACK_BUILD_ARMADILLO=N -export STACK_BUILD_XERCES=N -export STACK_BUILD_TKDIFF=N -export STACK_BUILD_BOOST_FULL=N -export STACK_BUILD_ESMF=N -export STACK_BUILD_BASELIBS=N -export STACK_BUILD_PDTOOLKIT=N -export STACK_BUILD_TAU2=N -export STACK_BUILD_CGAL=Y -export STACK_BUILD_GEOS=N -export STACK_BUILD_SQLITE=N -export STACK_BUILD_PROJ=N -export STACK_BUILD_JSON=Y -export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y -export STACK_BUILD_FMS=N diff --git a/buildscripts/config/config_ami-intel-impi-dev.sh b/buildscripts/config/config_ami-intel-impi-dev.sh index c74734a..34fcd39 100644 --- a/buildscripts/config/config_ami-intel-impi-dev.sh +++ b/buildscripts/config/config_ami-intel-impi-dev.sh @@ -22,65 +22,3 @@ export CPATH=/usr/local/include:$CPATH export COMPILER_BUILD="native-pkg" export MPI_BUILD="native-pkg" -# Build options -export PREFIX=/optjedi/modules -export USE_SUDO=Y -export PKGDIR=pkg -export LOGDIR=buildscripts/log -export OVERWRITE=N -export NTHREADS=4 -export MAKE_CHECK=N -export MAKE_VERBOSE=Y -export MAKE_CLEAN=N -export DOWNLOAD_ONLY=F -export STACK_EXIT_ON_FAIL=T -export WGET="wget -nv" -#Global compiler flags -export FFLAGS="" -export CFLAGS="" -export CXXFLAGS="" -export LDFLAGS="" - -# Minimal JEDI Stack -export STACK_BUILD_CMAKE=N -export STACK_BUILD_GITLFS=N -export STACK_BUILD_SZIP=Y -export STACK_BUILD_UDUNITS=Y -export STACK_BUILD_ZLIB=Y -export STACK_BUILD_LAPACK=N -export STACK_BUILD_BOOST_HDRS=N -export STACK_BUILD_EIGEN3=N -export STACK_BUILD_BUFR=Y -export STACK_BUILD_HDF5=Y -export STACK_BUILD_PNETCDF=Y -export STACK_BUILD_NETCDF=Y -export STACK_BUILD_NCCMP=Y -export STACK_BUILD_NCO=N -export STACK_BUILD_ECBUILD=N -export STACK_BUILD_ECKIT=Y -export STACK_BUILD_FCKIT=Y -export STACK_BUILD_ATLAS=Y -export STACK_BUILD_PYBIND11=N -export STACK_BUILD_GSL_LITE=N - -# Optional Additions -export STACK_BUILD_ODC=N -export STACK_BUILD_PIO=N -export STACK_BUILD_GPTL=N -export STACK_BUILD_PYJEDI=N -export STACK_BUILD_NCEPLIBS=N -export STACK_BUILD_JPEG=N -export STACK_BUILD_PNG=N -export STACK_BUILD_JASPER=N -export STACK_BUILD_ARMADILLO=N -export STACK_BUILD_XERCES=N -export STACK_BUILD_TKDIFF=N -export STACK_BUILD_BOOST_FULL=N -export STACK_BUILD_ESMF=N -export STACK_BUILD_BASELIBS=N -export STACK_BUILD_PDTOOLKIT=N -export STACK_BUILD_TAU2=N -export STACK_BUILD_CGAL=N -export STACK_BUILD_JSON=N -export STACK_BUILD_JSON_SCHEMA_VALIDATOR=N -export STACK_BUILD_FMS=N From ccfa08224fb313389177f60e08469b82f9b1a6e6 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Sun, 18 Apr 2021 19:45:00 +0000 Subject: [PATCH 100/132] config adjustments --- .../config/config_ami-gnu-openmpi-dev.sh | 2 +- .../config/config_ami-intel-impi-dev.sh | 20 +++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/buildscripts/config/config_ami-gnu-openmpi-dev.sh b/buildscripts/config/config_ami-gnu-openmpi-dev.sh index cf73fb6..2d7c600 100644 --- a/buildscripts/config/config_ami-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_ami-gnu-openmpi-dev.sh @@ -27,7 +27,7 @@ export OVERWRITE=N export NTHREADS=4 export MAKE_CHECK=N export MAKE_VERBOSE=N -export MAKE_CLEAN=Y +export MAKE_CLEAN=N export DOWNLOAD_ONLY=F export STACK_EXIT_ON_FAIL=T export WGET="wget -nv" diff --git a/buildscripts/config/config_ami-intel-impi-dev.sh b/buildscripts/config/config_ami-intel-impi-dev.sh index 34fcd39..ce06695 100644 --- a/buildscripts/config/config_ami-intel-impi-dev.sh +++ b/buildscripts/config/config_ami-intel-impi-dev.sh @@ -22,3 +22,23 @@ export CPATH=/usr/local/include:$CPATH export COMPILER_BUILD="native-pkg" export MPI_BUILD="native-pkg" +# Build options +export PREFIX=/optjedi/modules +export USE_SUDO=Y +export PKGDIR=pkg +export LOGDIR=buildscripts/log +export OVERWRITE=N +export NTHREADS=4 +export MAKE_CHECK=N +export MAKE_VERBOSE=N +export MAKE_CLEAN=N +export DOWNLOAD_ONLY=F +export STACK_EXIT_ON_FAIL=T +export WGET="wget -nv" + +#Global compiler flags +export FFLAGS="" +export CFLAGS="" +export CXXFLAGS="" +export LDFLAGS="" + From f2fc16b6babd92fb694e379c4d3cbdc1cea83574 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Sun, 18 Apr 2021 20:01:42 +0000 Subject: [PATCH 101/132] fix gnu app module --- modulefiles/apps/jedi/gnu-openmpi.lua | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/modulefiles/apps/jedi/gnu-openmpi.lua b/modulefiles/apps/jedi/gnu-openmpi.lua index a4d9846..484597f 100644 --- a/modulefiles/apps/jedi/gnu-openmpi.lua +++ b/modulefiles/apps/jedi/gnu-openmpi.lua @@ -8,23 +8,32 @@ local pkgNameVer = myModuleFullName() conflict(pkgName) +load("cmake") load("jedi-gnu") load("szip") +load("zlib") load("jedi-openmpi") +load("udunits") +load("lapack") + load("hdf5") load("pnetcdf") load("netcdf") +load("nccmp") -load("lapack") load("boost-headers") load("eigen") load("json") load("json-schema-validator") +load("gsl_lite") +load("pybind11") +load("bufr") -laod("ecbuild") +load("ecbuild") load("eckit") -load("gsl_lite") +load("fckit") +load("atlas") whatis("Name: ".. pkgName) whatis("Version: ".. pkgVersion) From 7becac1fc7d973f2761271849e3d9add172cb7c8 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Sun, 18 Apr 2021 20:39:48 +0000 Subject: [PATCH 102/132] intel ami updates --- .../config/config_ami-intel-impi-dev.sh | 4 ++-- modulefiles/apps/jedi/intel-impi.lua | 20 ++++++++++--------- 2 files changed, 13 insertions(+), 11 deletions(-) diff --git a/buildscripts/config/config_ami-intel-impi-dev.sh b/buildscripts/config/config_ami-intel-impi-dev.sh index ce06695..004d616 100644 --- a/buildscripts/config/config_ami-intel-impi-dev.sh +++ b/buildscripts/config/config_ami-intel-impi-dev.sh @@ -5,8 +5,8 @@ # Compiler/MPI combination -export JEDI_COMPILER="intel/2021.1" -export JEDI_MPI="impi/2021.1" +export JEDI_COMPILER="intel/2021.2" +export JEDI_MPI="impi/2021.2" export PATH=/usr/local/bin:$PATH export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH export LIBRARY_PATH=/usr/local/lib:$LIBRARY_PATH diff --git a/modulefiles/apps/jedi/intel-impi.lua b/modulefiles/apps/jedi/intel-impi.lua index c64cabf..9288d78 100644 --- a/modulefiles/apps/jedi/intel-impi.lua +++ b/modulefiles/apps/jedi/intel-impi.lua @@ -1,5 +1,5 @@ help([[ -Load environment for running JEDI applications with GNU compilers and OpenMPI. +Load environment for running JEDI applications with Intel OneAPI ]]) local pkgName = myModuleName() @@ -8,10 +8,14 @@ local pkgNameVer = myModuleFullName() conflict(pkgName) +load("cmake") load("jedi-intel") load("szip") +load("zlib") load("jedi-impi") +load("udunits") + load("hdf5") load("pnetcdf") load("netcdf") @@ -19,20 +23,18 @@ load("nccmp") load("boost-headers") load("eigen") -load("bufr") load("json") load("json-schema-validator") +load("gsl_lite") +load("pybind11") +load("bufr") load("ecbuild") load("eckit") -load("gsl_lite") - - -setenv("CC","mpiicc") -setenv("FC","mpiifort") -setenv("CXX","mpiicpc") +load("fckit") +load("atlas") whatis("Name: ".. pkgName) whatis("Version: ".. pkgVersion) whatis("Category: Application") -whatis("Description: JEDI Environment with Intel17") +whatis("Description: JEDI Environment with Intel OneAPI") From 941464269ff165f6a5fc3de124752b2d0eb52983 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Sun, 18 Apr 2021 23:54:14 +0000 Subject: [PATCH 103/132] bugfix in build_fckit --- buildscripts/libs/build_fckit.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_fckit.sh b/buildscripts/libs/build_fckit.sh index c590ff4..e7d9b3a 100755 --- a/buildscripts/libs/build_fckit.sh +++ b/buildscripts/libs/build_fckit.sh @@ -50,7 +50,7 @@ git checkout $version mkdir -p build && cd build ecbuild --build=release --prefix=$prefix .. -VERBOSE=$MAKE_VERBOSE $SUDO make -j${NTHREADS:-4} +VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install # generate modulefile from template From fe5305954f9a5a95772c0a5194fe8cac2e346a98 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 20 Apr 2021 12:10:25 -0600 Subject: [PATCH 104/132] typo in lapack build --- buildscripts/libs/build_lapack.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/buildscripts/libs/build_lapack.sh b/buildscripts/libs/build_lapack.sh index c9db5f5..2db62c0 100755 --- a/buildscripts/libs/build_lapack.sh +++ b/buildscripts/libs/build_lapack.sh @@ -34,6 +34,7 @@ export FC=$SERIAL_FC export CC=$SERIAL_CC export FFLAGS="-fPIC ${FFLAGS}" +export FCLAGS="-fPIC ${FCLAGS}" export CFLAGS="-fPIC ${CFLAGS}" cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} From 571a3e0bbd5852cf092a183a4bac8c9228a0629b Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 20 Apr 2021 12:28:51 -0600 Subject: [PATCH 105/132] another typo!! --- buildscripts/libs/build_lapack.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_lapack.sh b/buildscripts/libs/build_lapack.sh index 2db62c0..7b2493a 100755 --- a/buildscripts/libs/build_lapack.sh +++ b/buildscripts/libs/build_lapack.sh @@ -34,7 +34,7 @@ export FC=$SERIAL_FC export CC=$SERIAL_CC export FFLAGS="-fPIC ${FFLAGS}" -export FCLAGS="-fPIC ${FCLAGS}" +export FCFLAGS="-fPIC ${FCFLAGS}" export CFLAGS="-fPIC ${CFLAGS}" cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} From 69dd22639cdf3feeeb11bb6ed5e4bb39f7eaab5a Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 20 Apr 2021 12:52:01 -0600 Subject: [PATCH 106/132] MAKE_CLEAN should be F --- buildscripts/config/config_container-clang-mpich-dev.sh | 2 +- buildscripts/config/config_container-gnu-openmpi-dev.sh | 2 +- buildscripts/config/config_container-intel-impi-app.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/buildscripts/config/config_container-clang-mpich-dev.sh b/buildscripts/config/config_container-clang-mpich-dev.sh index 9913665..d4c60f6 100644 --- a/buildscripts/config/config_container-clang-mpich-dev.sh +++ b/buildscripts/config/config_container-clang-mpich-dev.sh @@ -27,7 +27,7 @@ export OVERWRITE=N export NTHREADS=4 export MAKE_CHECK=N export MAKE_VERBOSE=N -export MAKE_CLEAN=Y +export MAKE_CLEAN=N export DOWNLOAD_ONLY=F export STACK_EXIT_ON_FAIL=T export WGET="wget -nv" diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index bb22f96..5cafc21 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -27,7 +27,7 @@ export OVERWRITE=N export NTHREADS=4 export MAKE_CHECK=N export MAKE_VERBOSE=N -export MAKE_CLEAN=Y +export MAKE_CLEAN=N export DOWNLOAD_ONLY=F export STACK_EXIT_ON_FAIL=T export WGET="wget -nv" diff --git a/buildscripts/config/config_container-intel-impi-app.sh b/buildscripts/config/config_container-intel-impi-app.sh index d7b4805..3a7fad1 100644 --- a/buildscripts/config/config_container-intel-impi-app.sh +++ b/buildscripts/config/config_container-intel-impi-app.sh @@ -32,7 +32,7 @@ export OVERWRITE=N export NTHREADS=4 export MAKE_CHECK=N export MAKE_VERBOSE=N -export MAKE_CLEAN=Y +export MAKE_CLEAN=N export DOWNLOAD_ONLY=F export STACK_EXIT_ON_FAIL=T export WGET="wget -nv" From c685da4d1cad39ebf504046770f05772b30dae84 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 20 Apr 2021 13:28:45 -0600 Subject: [PATCH 107/132] include fckit and atlas in container --- buildscripts/config/config_container-clang-mpich-dev.sh | 4 ++-- buildscripts/config/config_container-gnu-openmpi-dev.sh | 4 ++-- buildscripts/config/config_container-intel-impi-dev.sh | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/buildscripts/config/config_container-clang-mpich-dev.sh b/buildscripts/config/config_container-clang-mpich-dev.sh index d4c60f6..d471332 100644 --- a/buildscripts/config/config_container-clang-mpich-dev.sh +++ b/buildscripts/config/config_container-clang-mpich-dev.sh @@ -54,8 +54,8 @@ export STACK_BUILD_NCCMP=Y export STACK_BUILD_NCO=Y export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y -export STACK_BUILD_FCKIT=N -export STACK_BUILD_ATLAS=N +export STACK_BUILD_FCKIT=Y +export STACK_BUILD_ATLAS=Y export STACK_BUILD_PYBIND11=Y export STACK_BUILD_GSL_LITE=Y diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index 5cafc21..bfc99a5 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -54,8 +54,8 @@ export STACK_BUILD_NCCMP=Y export STACK_BUILD_NCO=Y export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y -export STACK_BUILD_FCKIT=N -export STACK_BUILD_ATLAS=N +export STACK_BUILD_FCKIT=Y +export STACK_BUILD_ATLAS=Y export STACK_BUILD_PYBIND11=Y export STACK_BUILD_GSL_LITE=Y diff --git a/buildscripts/config/config_container-intel-impi-dev.sh b/buildscripts/config/config_container-intel-impi-dev.sh index 7bdfe20..a78da9d 100644 --- a/buildscripts/config/config_container-intel-impi-dev.sh +++ b/buildscripts/config/config_container-intel-impi-dev.sh @@ -58,8 +58,8 @@ export STACK_BUILD_NCCMP=Y export STACK_BUILD_NCO=N export STACK_BUILD_ECBUILD=Y export STACK_BUILD_ECKIT=Y -export STACK_BUILD_FCKIT=N -export STACK_BUILD_ATLAS=N +export STACK_BUILD_FCKIT=Y +export STACK_BUILD_ATLAS=Y export STACK_BUILD_PYBIND11=Y export STACK_BUILD_GSL_LITE=Y From 2d8a4848ff1e2362431591f974a529f28778f62a Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Tue, 27 Apr 2021 10:03:45 -0600 Subject: [PATCH 108/132] MPICH: Don't propogate the gfortran compatability flags with mpifort wrapper. --- buildscripts/libs/build_mpi.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/buildscripts/libs/build_mpi.sh b/buildscripts/libs/build_mpi.sh index 532f78f..3c6a0b6 100755 --- a/buildscripts/libs/build_mpi.sh +++ b/buildscripts/libs/build_mpi.sh @@ -33,7 +33,6 @@ export CXX=$SERIAL_CXX export FC=$SERIAL_FC export FFLAGS+=" -fPIC" -[[ -n $FC_GFORTRAN_10 ]] && export FFLAGS+=" -fallow-argument-mismatch -fallow-invalid-boz" export CFLAGS+=" -fPIC" export CXXFLAGS+=" -fPIC" export FCFLAGS=${FFLAGS} @@ -82,6 +81,13 @@ case "$name" in else extra_conf="--enable-fortran --enable-cxx" fi + # Only enable Gfortran-10+ compatibility flags for MPICH Library itself + # Do not propogate with mpifort wrapper which will confuse FindMPI.cmake + if [[ -n $FC_GFORTRAN_10 ]]; then + export FCFLAGS+=" -fallow-argument-mismatch -fallow-invalid-boz" + export FFLAGS=${FCFLAGS} + export MPICH_MPIFORT_FCFLAGS="" + fi [[ -n $HWLOC_ROOT ]] && extra_conf+=" --with-hwloc-prefix=${HWLOC_ROOT}" ;; * ) From 644b8d9516a0549944b9ccd056b5fad781512d6a Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Fri, 14 May 2021 17:59:54 -0600 Subject: [PATCH 109/132] update for CMAKE_INSTALL_PREFIX and CMAKE_INSTALL_LIB --- buildscripts/libs/build_atlas.sh | 3 ++- buildscripts/libs/build_ecbuild.sh | 3 ++- buildscripts/libs/build_eckit.sh | 3 ++- buildscripts/libs/build_fckit.sh | 3 ++- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/buildscripts/libs/build_atlas.sh b/buildscripts/libs/build_atlas.sh index c937f70..3f7d073 100755 --- a/buildscripts/libs/build_atlas.sh +++ b/buildscripts/libs/build_atlas.sh @@ -51,7 +51,8 @@ git checkout $version [[ -d build ]] && $SUDO rm -rf build mkdir -p build && cd build -ecbuild --prefix=$prefix --build=release .. +# set install prefix and CMAKE_INSTALL_LIBDIR to make sure it installs as lib, not lib64 +ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --prefix=$prefix --build=release .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make -j${NTHREADS:-4} install diff --git a/buildscripts/libs/build_ecbuild.sh b/buildscripts/libs/build_ecbuild.sh index a415f47..88afbc8 100755 --- a/buildscripts/libs/build_ecbuild.sh +++ b/buildscripts/libs/build_ecbuild.sh @@ -38,7 +38,8 @@ git checkout $version [[ -d build ]] && $SUDO rm -rf build mkdir -p build && cd build -cmake -DCMAKE_INSTALL_PREFIX=$prefix .. +# set install prefix and CMAKE_INSTALL_LIBDIR to make sure it installs as lib, not lib64 +cmake -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_INSTALL_PREFIX=$prefix .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install diff --git a/buildscripts/libs/build_eckit.sh b/buildscripts/libs/build_eckit.sh index ea93b4b..e4e74d1 100755 --- a/buildscripts/libs/build_eckit.sh +++ b/buildscripts/libs/build_eckit.sh @@ -53,7 +53,8 @@ sed -i -e 's/project( eckit CXX/project( eckit CXX Fortran/' CMakeLists.txt [[ -d build ]] && $SUDO rm -rf build mkdir -p build && cd build -ecbuild --build=release --prefix=$prefix .. +# set install prefix and CMAKE_INSTALL_LIBDIR to make sure it installs as lib, not lib64 +ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --build=release --prefix=$prefix .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install diff --git a/buildscripts/libs/build_fckit.sh b/buildscripts/libs/build_fckit.sh index e7d9b3a..04b06e8 100755 --- a/buildscripts/libs/build_fckit.sh +++ b/buildscripts/libs/build_fckit.sh @@ -49,7 +49,8 @@ git checkout $version [[ -d build ]] && $SUDO rm -rf build mkdir -p build && cd build -ecbuild --build=release --prefix=$prefix .. +# set install prefix and CMAKE_INSTALL_LIBDIR to make sure it installs as lib, not lib64 +ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --build=release --prefix=$prefix .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install From ec8701ed6e653aca36d81473b8ad0c3664ef0ca5 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Fri, 14 May 2021 18:34:47 -0600 Subject: [PATCH 110/132] Update build_atlas.sh --- buildscripts/libs/build_atlas.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_atlas.sh b/buildscripts/libs/build_atlas.sh index 3f7d073..9ab8794 100755 --- a/buildscripts/libs/build_atlas.sh +++ b/buildscripts/libs/build_atlas.sh @@ -52,7 +52,7 @@ git checkout $version mkdir -p build && cd build # set install prefix and CMAKE_INSTALL_LIBDIR to make sure it installs as lib, not lib64 -ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --prefix=$prefix --build=release .. +ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --build=release .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make -j${NTHREADS:-4} install From cac06143e146745caeca8f4b37ac6ada6dc75b92 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Fri, 14 May 2021 18:35:53 -0600 Subject: [PATCH 111/132] Update build_eckit.sh --- buildscripts/libs/build_eckit.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_eckit.sh b/buildscripts/libs/build_eckit.sh index e4e74d1..f732610 100755 --- a/buildscripts/libs/build_eckit.sh +++ b/buildscripts/libs/build_eckit.sh @@ -54,7 +54,7 @@ sed -i -e 's/project( eckit CXX/project( eckit CXX Fortran/' CMakeLists.txt mkdir -p build && cd build # set install prefix and CMAKE_INSTALL_LIBDIR to make sure it installs as lib, not lib64 -ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --build=release --prefix=$prefix .. +ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --build=release .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install From 080f8d50eef1f37362a6c1527c7bfa7d3fdf827a Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Fri, 14 May 2021 18:36:10 -0600 Subject: [PATCH 112/132] Update build_fckit.sh --- buildscripts/libs/build_fckit.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_fckit.sh b/buildscripts/libs/build_fckit.sh index 04b06e8..d6eda17 100755 --- a/buildscripts/libs/build_fckit.sh +++ b/buildscripts/libs/build_fckit.sh @@ -50,7 +50,7 @@ git checkout $version mkdir -p build && cd build # set install prefix and CMAKE_INSTALL_LIBDIR to make sure it installs as lib, not lib64 -ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --build=release --prefix=$prefix .. +ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --build=release .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install From 348908579e7d6ccf55239361674d6b826dae1dae Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Fri, 14 May 2021 18:36:47 -0600 Subject: [PATCH 113/132] Update build_ecbuild.sh --- buildscripts/libs/build_ecbuild.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_ecbuild.sh b/buildscripts/libs/build_ecbuild.sh index 88afbc8..2e09d14 100755 --- a/buildscripts/libs/build_ecbuild.sh +++ b/buildscripts/libs/build_ecbuild.sh @@ -39,7 +39,7 @@ git checkout $version mkdir -p build && cd build # set install prefix and CMAKE_INSTALL_LIBDIR to make sure it installs as lib, not lib64 -cmake -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_INSTALL_PREFIX=$prefix .. +cmake -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install From 69c9e1b3fad8fd2efe1a739536caa6334c755829 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Mon, 17 May 2021 18:36:42 -0600 Subject: [PATCH 114/132] update documentation for new ecbuild --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 5dca1af..635c63f 100644 --- a/README.md +++ b/README.md @@ -28,12 +28,12 @@ We want to provide a common set of software libraries to JEDI users and develope | lapack | 3.8.0 | Can be replaced by intel mkl | | Boost | 1.68.0 | headers only | | Eigen | 3.3.7 | | -| ecbuild | jcsda/3.3.2.jcsda3 | Should move to ecmwf for future releases | +| ecbuild | jcsda/3.3.2.jcsda3 | Now `ecmwf/3.6.1` in develop | | hdf5 | 1.12.0 | | | pnetcdf | 1.12.1 | | | netcdf | 4.7.4, 4.5.3, 4.3.0 | versions for C, Fortran, and C++ | | nccmp | 1.8.7.0 | Needed for running tests | -| eckit | jcsda/1.11.6.jcsda2 | Should move to ecmwf for next release | +| eckit | jcsda/1.11.6.jcsda2 | Now `ecmwf/1.16.0` in develop | | bufrlib | 11.3.2 | deprecated: replaced by NCEP-bufr | | pybind11 | 2.5.0 | | | gsl_lite | 0.34.0 | upgraded to 0.37.0 in develop | @@ -68,8 +68,8 @@ These can be build by jedi-stack but they are not required for jedi. | software | version | Notes | | -------- | ------- | ----- | | NCO | 4.7.9 | Can use a native module or package installation? | -| fckit | jcsda/0.7.0.jcsda1 | Usually not included in stack; should move to ecmwf versions for next releases | -| atlas | jcsda/0.20.2.jcsda1 | Usually not included in stack; should move to ecmwf versions for next release | +| fckit | jcsda/0.7.0.jcsda1 | Now using `ecmwf/0.9.2` and now included in default stack | +| atlas | jcsda/0.20.2.jcsda1 | Now using `ecmwf/0.24.1` and now included in default stack | | fms | jcsda/release-stable | Currently not included in stack but moving toward including it| | gptl | 8.0.3 | profiling tool | | fftw | 3.3.8 | | From 4e0e837685691142c9dd9ae0c10c3dcf94c20878 Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Thu, 20 May 2021 15:54:49 -0600 Subject: [PATCH 115/132] reorder cmake / ecbuild options to specify ecbuild options first --- buildscripts/libs/build_atlas.sh | 2 +- buildscripts/libs/build_eckit.sh | 2 +- buildscripts/libs/build_fckit.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/buildscripts/libs/build_atlas.sh b/buildscripts/libs/build_atlas.sh index 9ab8794..0c7dd5b 100755 --- a/buildscripts/libs/build_atlas.sh +++ b/buildscripts/libs/build_atlas.sh @@ -52,7 +52,7 @@ git checkout $version mkdir -p build && cd build # set install prefix and CMAKE_INSTALL_LIBDIR to make sure it installs as lib, not lib64 -ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --build=release .. +ecbuild --build=release -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make -j${NTHREADS:-4} install diff --git a/buildscripts/libs/build_eckit.sh b/buildscripts/libs/build_eckit.sh index f732610..315f546 100755 --- a/buildscripts/libs/build_eckit.sh +++ b/buildscripts/libs/build_eckit.sh @@ -54,7 +54,7 @@ sed -i -e 's/project( eckit CXX/project( eckit CXX Fortran/' CMakeLists.txt mkdir -p build && cd build # set install prefix and CMAKE_INSTALL_LIBDIR to make sure it installs as lib, not lib64 -ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --build=release .. +ecbuild --build=release -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install diff --git a/buildscripts/libs/build_fckit.sh b/buildscripts/libs/build_fckit.sh index d6eda17..f3986cc 100755 --- a/buildscripts/libs/build_fckit.sh +++ b/buildscripts/libs/build_fckit.sh @@ -50,7 +50,7 @@ git checkout $version mkdir -p build && cd build # set install prefix and CMAKE_INSTALL_LIBDIR to make sure it installs as lib, not lib64 -ecbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib --build=release .. +ecbuild --build=release -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_INSTALL_LIBDIR=lib .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install From 2cc48e4940d9bad2f6d4db7b5fe3c124073cd7f0 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Fri, 21 May 2021 09:45:24 -0600 Subject: [PATCH 116/132] upgrade bufr and nco --- buildscripts/build_stack.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index f8b5552..1a75621 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -86,7 +86,7 @@ build_lib SZIP szip 2.1.1 build_lib LAPACK lapack 3.8.0 build_lib BOOST_HDRS boost 1.68.0 headers-only build_lib EIGEN3 eigen 3.3.7 -build_lib BUFR bufr jcsda-internal 11.4.0.jcsda2 +build_lib BUFR bufr noaa-emc 11.5.0 build_lib ECBUILD ecbuild ecmwf 3.6.1 build_lib CGAL cgal 5.0.4 build_lib GITLFS git-lfs 2.11.0 @@ -126,7 +126,7 @@ build_lib ECFLOW ecflow ecmwf 5.5.3 boost 1.68.0 #---------------------- # These must be rebuilt for each MPI implementation build_lib GPTL gptl 8.0.3 -build_lib NCO nco 4.7.9 +build_lib NCO nco 4.9.9 build_lib PIO pio 2.5.1 build_lib FFTW fftw 3.3.8 build_lib BOOST_FULL boost 1.68.0 From 76489da0aaa92f230722c6625a7efba489d45628 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Fri, 21 May 2021 11:34:18 -0600 Subject: [PATCH 117/132] update README --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 635c63f..1d5eb40 100644 --- a/README.md +++ b/README.md @@ -43,7 +43,7 @@ We want to provide a common set of software libraries to JEDI users and develope | software | version | Notes | | -------- | ------- | ----- | | CGAL | 5.0.2 | Optional in principle but may become required in practice for efficiency reasons. Can be installed without gmp, mpfr dependencies | -| bufr | 11.4.0.jcsda1 | NCEP version replaces previous bufrlib | +| bufr | 11.5.0 | NCEP upstream replaces previous bufrlib | ## Required for certain components or models @@ -67,7 +67,7 @@ These can be build by jedi-stack but they are not required for jedi. | software | version | Notes | | -------- | ------- | ----- | -| NCO | 4.7.9 | Can use a native module or package installation? | +| NCO | 4.7.9 | Upgraded to 4.9.9 in develop. Can use a native module or package installation? | | fckit | jcsda/0.7.0.jcsda1 | Now using `ecmwf/0.9.2` and now included in default stack | | atlas | jcsda/0.20.2.jcsda1 | Now using `ecmwf/0.24.1` and now included in default stack | | fms | jcsda/release-stable | Currently not included in stack but moving toward including it| From d1c6b555b3d7cfcfc3477dc77d06585c0ff6ca2d Mon Sep 17 00:00:00 2001 From: Rick Grubin Date: Fri, 21 May 2021 14:51:52 -0600 Subject: [PATCH 118/132] add env var for F90 and new idiom to set pythonVersion --- buildscripts/libs/build_bufr.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/buildscripts/libs/build_bufr.sh b/buildscripts/libs/build_bufr.sh index 8494222..8380836 100755 --- a/buildscripts/libs/build_bufr.sh +++ b/buildscripts/libs/build_bufr.sh @@ -34,6 +34,7 @@ else fi export FC=$SERIAL_FC +export F90=$SERIAL_FC export CC=$SERIAL_CC software=NCEPLIBS-bufr @@ -63,6 +64,6 @@ VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make install # generate modulefile from template -pythonVersion="$(python --version | cut -d " " -f2 | cut -d. -f1-2)" +pythonVersion=$(`which python3` -c 'import sys;print(sys.version_info[0],".",sys.version_info[1],sep="")') $MODULES && update_modules compiler $name $source-$version $pythonVersion \ || echo $name $source-$version >> ${JEDI_STACK_ROOT}/jedi-stack-contents.log From 83aca3847bdafe424f6f68a013c06db394a92c6d Mon Sep 17 00:00:00 2001 From: Ubuntu Date: Mon, 24 May 2021 21:28:45 +0000 Subject: [PATCH 119/132] bugfix on install location for container --- buildscripts/config/config_container-gnu-openmpi-dev.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index 12e7197..cf5cb20 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -19,7 +19,7 @@ export COMPILER_BUILD="native-pkg" export MPI_BUILD="from-source" # Build options -export PREFIX=/optjedi +export PREFIX=/usr/local export USE_SUDO=N export PKGDIR=pkg export LOGDIR=buildscripts/log From bc3f4dec821ed37a4276e2688d721bcb35335e95 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 25 May 2021 10:17:43 -0600 Subject: [PATCH 120/132] update odc --- buildscripts/build_stack.sh | 2 +- buildscripts/libs/build_odc.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/buildscripts/build_stack.sh b/buildscripts/build_stack.sh index 1a75621..56ed809 100755 --- a/buildscripts/build_stack.sh +++ b/buildscripts/build_stack.sh @@ -101,7 +101,7 @@ build_lib ECKIT eckit ecmwf 1.16.0 build_lib FCKIT fckit ecmwf 0.9.2 build_lib ATLAS atlas ecmwf 0.24.1 build_lib ODB odb 0.18.1.r2 -build_lib ODC odc jcsda-internal 1.0.3 +build_lib ODC odc ecmwf 2021.03.0 # =============================================================================== # Optional Extensions to the JEDI Stack diff --git a/buildscripts/libs/build_odc.sh b/buildscripts/libs/build_odc.sh index 32eb459..2bd0d49 100755 --- a/buildscripts/libs/build_odc.sh +++ b/buildscripts/libs/build_odc.sh @@ -50,7 +50,7 @@ git checkout $version [[ -d build ]] && $SUDO rm -rf build mkdir -p build && cd build -ecbuild -DCMAKE_INSTALL_PREFIX=$prefix --build=Release .. +ecbuild --build=Release -DCMAKE_INSTALL_PREFIX=$prefix .. VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} VERBOSE=$MAKE_VERBOSE $SUDO make -j${NTHREADS:-4} install From a98069f59c6cd4c5a50df2208f6d96b666e50fec Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 25 May 2021 10:20:14 -0600 Subject: [PATCH 121/132] add odc to containers --- buildscripts/config/config_container-clang-mpich-dev.sh | 2 +- buildscripts/config/config_container-gnu-openmpi-dev.sh | 2 +- buildscripts/config/config_container-intel-impi-app.sh | 2 +- buildscripts/config/config_container-intel-impi-dev.sh | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/buildscripts/config/config_container-clang-mpich-dev.sh b/buildscripts/config/config_container-clang-mpich-dev.sh index d471332..df4570e 100644 --- a/buildscripts/config/config_container-clang-mpich-dev.sh +++ b/buildscripts/config/config_container-clang-mpich-dev.sh @@ -60,7 +60,7 @@ export STACK_BUILD_PYBIND11=Y export STACK_BUILD_GSL_LITE=Y # Optional Additions -export STACK_BUILD_ODC=N +export STACK_BUILD_ODC=Y export STACK_BUILD_PIO=Y export STACK_BUILD_GPTL=N export STACK_BUILD_PYJEDI=Y diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index cf5cb20..db70559 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -60,7 +60,7 @@ export STACK_BUILD_PYBIND11=Y export STACK_BUILD_GSL_LITE=Y # Optional Additions -export STACK_BUILD_ODC=N +export STACK_BUILD_ODC=Y export STACK_BUILD_PIO=Y export STACK_BUILD_GPTL=N export STACK_BUILD_PYJEDI=Y diff --git a/buildscripts/config/config_container-intel-impi-app.sh b/buildscripts/config/config_container-intel-impi-app.sh index 3a7fad1..d237327 100644 --- a/buildscripts/config/config_container-intel-impi-app.sh +++ b/buildscripts/config/config_container-intel-impi-app.sh @@ -65,7 +65,7 @@ export STACK_BUILD_PYBIND11=Y export STACK_BUILD_GSL_LITE=Y # Optional Additions -export STACK_BUILD_ODC=N +export STACK_BUILD_ODC=Y export STACK_BUILD_PIO=N export STACK_BUILD_PYJEDI=N export STACK_BUILD_NCEPLIBS=N diff --git a/buildscripts/config/config_container-intel-impi-dev.sh b/buildscripts/config/config_container-intel-impi-dev.sh index a78da9d..6814c79 100644 --- a/buildscripts/config/config_container-intel-impi-dev.sh +++ b/buildscripts/config/config_container-intel-impi-dev.sh @@ -64,7 +64,7 @@ export STACK_BUILD_PYBIND11=Y export STACK_BUILD_GSL_LITE=Y # Optional Additions -export STACK_BUILD_ODC=N +export STACK_BUILD_ODC=Y export STACK_BUILD_PIO=Y export STACK_BUILD_GPTL=N export STACK_BUILD_PYJEDI=Y From 2ebb5f83af62f208e95281b392826ebaafbe7acc Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 25 May 2021 10:30:14 -0600 Subject: [PATCH 122/132] update clang container --- buildscripts/config/config_container-clang-mpich-dev.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/buildscripts/config/config_container-clang-mpich-dev.sh b/buildscripts/config/config_container-clang-mpich-dev.sh index df4570e..4c31f2c 100644 --- a/buildscripts/config/config_container-clang-mpich-dev.sh +++ b/buildscripts/config/config_container-clang-mpich-dev.sh @@ -38,7 +38,7 @@ export CXXFLAGS="" export LDFLAGS="" # Minimal JEDI Stack -export STACK_BUILD_CMAKE=N +export STACK_BUILD_CMAKE=Y export STACK_BUILD_GITLFS=N export STACK_BUILD_SZIP=Y export STACK_BUILD_UDUNITS=Y @@ -76,7 +76,7 @@ export STACK_BUILD_ESMF=N export STACK_BUILD_BASELIBS=N export STACK_BUILD_PDTOOLKIT=N export STACK_BUILD_TAU2=N -export STACK_BUILD_CGAL=N +export STACK_BUILD_CGAL=Y export STACK_BUILD_GEOS=N export STACK_BUILD_SQLITE=N export STACK_BUILD_PROJ=N From d60f2b48f4df0ea9ae4bc49d9e51d6b446a86e47 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 25 May 2021 11:28:22 -0600 Subject: [PATCH 123/132] bugfix in lapack build --- buildscripts/libs/build_lapack.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/buildscripts/libs/build_lapack.sh b/buildscripts/libs/build_lapack.sh index 7b2493a..01f4852 100755 --- a/buildscripts/libs/build_lapack.sh +++ b/buildscripts/libs/build_lapack.sh @@ -33,9 +33,9 @@ fi export FC=$SERIAL_FC export CC=$SERIAL_CC -export FFLAGS="-fPIC ${FFLAGS}" -export FCFLAGS="-fPIC ${FCFLAGS}" -export CFLAGS="-fPIC ${CFLAGS}" +export FFLAGS+=" -fPIC" +export FCFLAGS+=" -fPIC" +export CFLAGS+=" -fPIC" cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} From a06535bf8c79e75adff803a5c3f725734ffcccd6 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 25 May 2021 11:38:55 -0600 Subject: [PATCH 124/132] still does not work in clang container --- buildscripts/libs/build_lapack.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/buildscripts/libs/build_lapack.sh b/buildscripts/libs/build_lapack.sh index 01f4852..d1e780e 100755 --- a/buildscripts/libs/build_lapack.sh +++ b/buildscripts/libs/build_lapack.sh @@ -33,9 +33,9 @@ fi export FC=$SERIAL_FC export CC=$SERIAL_CC -export FFLAGS+=" -fPIC" -export FCFLAGS+=" -fPIC" -export CFLAGS+=" -fPIC" +export FFLAGS="-fPIC" +export FCFLAGS="-fPIC" +export CFLAGS="-fPIC" cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} From deb0755dabb8e70c6bb5f205cb25312c7969a7f4 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 25 May 2021 13:28:15 -0600 Subject: [PATCH 125/132] change boost source --- buildscripts/libs/build_boost.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_boost.sh b/buildscripts/libs/build_boost.sh index 7d0cb48..2744dfa 100755 --- a/buildscripts/libs/build_boost.sh +++ b/buildscripts/libs/build_boost.sh @@ -11,7 +11,7 @@ version=$1 cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} software=$name\_$(echo $version | sed 's/\./_/g') -url="https://dl.bintray.com/boostorg/release/$version/source/$software.tar.gz" +url="https://boostorg.jfrog.io/artifactory/main/release/$version/$software.tar.gz" [[ -d $software ]] || ( $WGET $url; tar -xf $software.tar.gz ) [[ ${DOWNLOAD_ONLY} =~ [yYtT] ]] && exit 0 [[ -d $software ]] && cd $software || ( echo "$software does not exist, ABORT!"; exit 1 ) From e57433d3794d13c2615e4c0923d1e6dfcd67ff36 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Tue, 25 May 2021 14:02:19 -0600 Subject: [PATCH 126/132] build lapack as shared libraries --- buildscripts/libs/build_lapack.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_lapack.sh b/buildscripts/libs/build_lapack.sh index d1e780e..0b05c37 100755 --- a/buildscripts/libs/build_lapack.sh +++ b/buildscripts/libs/build_lapack.sh @@ -49,7 +49,7 @@ url="https://github.com/Reference-LAPACK/lapack/archive/$tarball" # Add CMAKE_INSTALL_LIBDIR to make sure it will be installed under lib not lib64 cmake -H. -Bbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_LIBDIR=lib \ - -DCMAKE_Fortran_COMPILER=$SERIAL_FC -DCMAKE_Fortran_FLAGS=$FCFLAGS + -DCMAKE_Fortran_COMPILER=$SERIAL_FC -DCMAKE_Fortran_FLAGS=$FCFLAGS -DBUILD_SHARED_LIBS=ON cd build VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} [[ $MAKE_CHECK =~ [yYtT] ]] && make check From 2a449e5edf7d049310ada7d8f9ab1c0fe027262b Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Tue, 25 May 2021 14:04:10 -0600 Subject: [PATCH 127/132] Create shared libraries for lapack --- buildscripts/libs/build_lapack.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_lapack.sh b/buildscripts/libs/build_lapack.sh index 7b2493a..0f12f07 100755 --- a/buildscripts/libs/build_lapack.sh +++ b/buildscripts/libs/build_lapack.sh @@ -49,7 +49,7 @@ url="https://github.com/Reference-LAPACK/lapack/archive/$tarball" # Add CMAKE_INSTALL_LIBDIR to make sure it will be installed under lib not lib64 cmake -H. -Bbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_LIBDIR=lib \ - -DCMAKE_Fortran_COMPILER=$SERIAL_FC -DCMAKE_Fortran_FLAGS=$FCFLAGS + -DBUILD_SHARED_LIBS=1 -DCMAKE_Fortran_COMPILER=$SERIAL_FC -DCMAKE_Fortran_FLAGS=$FCFLAGS cd build VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} [[ $MAKE_CHECK =~ [yYtT] ]] && make check From dc965e5e7891d02078824c9536d75ed072f84e80 Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Tue, 25 May 2021 16:51:14 -0600 Subject: [PATCH 128/132] User /usr/local as prefix for container builds --- buildscripts/config/config_container-gnu-openmpi-dev.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/config/config_container-gnu-openmpi-dev.sh b/buildscripts/config/config_container-gnu-openmpi-dev.sh index 12e7197..cf5cb20 100644 --- a/buildscripts/config/config_container-gnu-openmpi-dev.sh +++ b/buildscripts/config/config_container-gnu-openmpi-dev.sh @@ -19,7 +19,7 @@ export COMPILER_BUILD="native-pkg" export MPI_BUILD="from-source" # Build options -export PREFIX=/optjedi +export PREFIX=/usr/local export USE_SUDO=N export PKGDIR=pkg export LOGDIR=buildscripts/log From 2be28c80d35fada08b36db6ff1a57ce45fcaad67 Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Wed, 26 May 2021 12:31:39 -0600 Subject: [PATCH 129/132] 1 -> ON --- buildscripts/libs/build_lapack.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_lapack.sh b/buildscripts/libs/build_lapack.sh index 0f12f07..e34166f 100755 --- a/buildscripts/libs/build_lapack.sh +++ b/buildscripts/libs/build_lapack.sh @@ -49,7 +49,7 @@ url="https://github.com/Reference-LAPACK/lapack/archive/$tarball" # Add CMAKE_INSTALL_LIBDIR to make sure it will be installed under lib not lib64 cmake -H. -Bbuild -DCMAKE_INSTALL_PREFIX=$prefix -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_LIBDIR=lib \ - -DBUILD_SHARED_LIBS=1 -DCMAKE_Fortran_COMPILER=$SERIAL_FC -DCMAKE_Fortran_FLAGS=$FCFLAGS + -DBUILD_SHARED_LIBS=ON -DCMAKE_Fortran_COMPILER=$SERIAL_FC -DCMAKE_Fortran_FLAGS=$FCFLAGS cd build VERBOSE=$MAKE_VERBOSE make -j${NTHREADS:-4} [[ $MAKE_CHECK =~ [yYtT] ]] && make check From 9c76815890105c822671f542f5eaa47d7e501bab Mon Sep 17 00:00:00 2001 From: "Mark J. Olah" Date: Wed, 26 May 2021 15:44:05 -0600 Subject: [PATCH 130/132] Fix for MPICH gfortran flags --- buildscripts/libs/build_mpi.sh | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/buildscripts/libs/build_mpi.sh b/buildscripts/libs/build_mpi.sh index 3c6a0b6..f99d642 100755 --- a/buildscripts/libs/build_mpi.sh +++ b/buildscripts/libs/build_mpi.sh @@ -81,12 +81,13 @@ case "$name" in else extra_conf="--enable-fortran --enable-cxx" fi - # Only enable Gfortran-10+ compatibility flags for MPICH Library itself - # Do not propogate with mpifort wrapper which will confuse FindMPI.cmake + # gfortran-10+ compatibility flags if [[ -n $FC_GFORTRAN_10 ]]; then - export FCFLAGS+=" -fallow-argument-mismatch -fallow-invalid-boz" - export FFLAGS=${FCFLAGS} - export MPICH_MPIFORT_FCFLAGS="" + # Use these flags to build MPICH itself, but don't add to WRAPPER_FCFLAGS + export MPICHLIB_FCFLAGS+=" -fallow-argument-mismatch -fallow-invalid-boz" + export MPICHLIB_FFLAGS=${MPICHLIB_FCFLAGS} + # Disable check for mismatched args flags in confdb/aclocal_f77.ac + export pac_cv_prog_f77_mismatched_args=yes fi [[ -n $HWLOC_ROOT ]] && extra_conf+=" --with-hwloc-prefix=${HWLOC_ROOT}" ;; From 7e1b383fca466bf0292dfd8a211c589f99e6f762 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Thu, 27 May 2021 11:45:03 -0600 Subject: [PATCH 131/132] review comments --- buildscripts/config/config_container-intel-impi-app.sh | 6 ++++-- buildscripts/config/config_container-intel-impi-dev.sh | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/buildscripts/config/config_container-intel-impi-app.sh b/buildscripts/config/config_container-intel-impi-app.sh index d237327..edf3e3e 100644 --- a/buildscripts/config/config_container-intel-impi-app.sh +++ b/buildscripts/config/config_container-intel-impi-app.sh @@ -43,7 +43,7 @@ export CXXFLAGS="" export LDFLAGS="" # Minimal JEDI Stack -export STACK_BUILD_CMAKE=N +export STACK_BUILD_CMAKE=Y export STACK_BUILD_GITLFS=N export STACK_BUILD_SZIP=Y export STACK_BUILD_UDUNITS=Y @@ -66,7 +66,7 @@ export STACK_BUILD_GSL_LITE=Y # Optional Additions export STACK_BUILD_ODC=Y -export STACK_BUILD_PIO=N +export STACK_BUILD_PIO=Y export STACK_BUILD_PYJEDI=N export STACK_BUILD_NCEPLIBS=N export STACK_BUILD_JASPER=N @@ -78,6 +78,8 @@ export STACK_BUILD_ESMF=N export STACK_BUILD_BASELIBS=N export STACK_BUILD_PDTOOLKIT=N export STACK_BUILD_TAU2=N +export STACK_BUILD_CGAL=Y + # For help with finding packages export PATH=${PREFIX}/bin:$PATH diff --git a/buildscripts/config/config_container-intel-impi-dev.sh b/buildscripts/config/config_container-intel-impi-dev.sh index 6814c79..b16f118 100644 --- a/buildscripts/config/config_container-intel-impi-dev.sh +++ b/buildscripts/config/config_container-intel-impi-dev.sh @@ -42,7 +42,7 @@ export CXXFLAGS="" export LDFLAGS="" # Minimal JEDI Stack -export STACK_BUILD_CMAKE=N +export STACK_BUILD_CMAKE=Y export STACK_BUILD_GITLFS=N export STACK_BUILD_SZIP=Y export STACK_BUILD_UDUNITS=Y @@ -80,7 +80,7 @@ export STACK_BUILD_ESMF=N export STACK_BUILD_BASELIBS=N export STACK_BUILD_PDTOOLKIT=N export STACK_BUILD_TAU2=N -export STACK_BUILD_CGAL=N +export STACK_BUILD_CGAL=Y export STACK_BUILD_JSON=Y export STACK_BUILD_JSON_SCHEMA_VALIDATOR=Y export STACK_BUILD_FMS=N From cb1b181eda97825d10e2778877857669ec4a0ff8 Mon Sep 17 00:00:00 2001 From: mmiesch Date: Wed, 2 Jun 2021 18:47:06 -0600 Subject: [PATCH 132/132] boost download site --- buildscripts/libs/build_boost.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildscripts/libs/build_boost.sh b/buildscripts/libs/build_boost.sh index 2744dfa..feaee83 100755 --- a/buildscripts/libs/build_boost.sh +++ b/buildscripts/libs/build_boost.sh @@ -11,7 +11,7 @@ version=$1 cd ${JEDI_STACK_ROOT}/${PKGDIR:-"pkg"} software=$name\_$(echo $version | sed 's/\./_/g') -url="https://boostorg.jfrog.io/artifactory/main/release/$version/$software.tar.gz" +url="https://boostorg.jfrog.io/artifactory/main/release/$version/source/$software.tar.gz" [[ -d $software ]] || ( $WGET $url; tar -xf $software.tar.gz ) [[ ${DOWNLOAD_ONLY} =~ [yYtT] ]] && exit 0 [[ -d $software ]] && cd $software || ( echo "$software does not exist, ABORT!"; exit 1 )