From 5cfeca294a68a2a1e2a48da091b5641c5ffc48a4 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 09:50:23 +0800 Subject: [PATCH 01/21] Removes adios2 and awscli. Not needed anymore. --- .../packages/adios2/2.5-fix-clear_cache.patch | 213 ----- .../adios2/2.6-fix-gcc10-symbols.patch | 32 - .../adios2/2.7-fix-python-test-deps.patch | 175 ---- .../adios2/cmake-update-findmpi.patch | 837 ------------------ repo/packages/adios2/package.py | 255 ------ repo/packages/awscli/package.py | 38 - 6 files changed, 1550 deletions(-) delete mode 100644 repo/packages/adios2/2.5-fix-clear_cache.patch delete mode 100644 repo/packages/adios2/2.6-fix-gcc10-symbols.patch delete mode 100644 repo/packages/adios2/2.7-fix-python-test-deps.patch delete mode 100644 repo/packages/adios2/cmake-update-findmpi.patch delete mode 100644 repo/packages/adios2/package.py delete mode 100644 repo/packages/awscli/package.py diff --git a/repo/packages/adios2/2.5-fix-clear_cache.patch b/repo/packages/adios2/2.5-fix-clear_cache.patch deleted file mode 100644 index 2a2e86cc..00000000 --- a/repo/packages/adios2/2.5-fix-clear_cache.patch +++ /dev/null @@ -1,213 +0,0 @@ -From 2f05a0b1def194001d1f6e0f9a07725c10b48301 Mon Sep 17 00:00:00 2001 -From: Greg Eisenhauer -Date: Fri, 13 Dec 2019 10:00:15 -0500 -Subject: [PATCH] Merge branch 'upstream-dill' into DillUpstream - -* upstream-dill: - dill 2019-12-12 (dac6dfcc) ---- - thirdparty/dill/dill/CMakeLists.txt | 5 ++++- - thirdparty/dill/dill/LICENSE | 24 ++++++++++++++++++++++++ - thirdparty/dill/dill/arm6.c | 19 +++---------------- - thirdparty/dill/dill/arm6_rt.c | 19 +++---------------- - thirdparty/dill/dill/arm8.c | 19 +++---------------- - thirdparty/dill/dill/arm8_rt.c | 19 +++---------------- - thirdparty/dill/dill/config.h.cmake | 7 +++++-- - 7 files changed, 45 insertions(+), 67 deletions(-) - create mode 100644 thirdparty/dill/dill/LICENSE - -diff --git a/thirdparty/dill/dill/CMakeLists.txt b/thirdparty/dill/dill/CMakeLists.txt -index 0461556a..695db8c6 100644 ---- a/thirdparty/dill/dill/CMakeLists.txt -+++ b/thirdparty/dill/dill/CMakeLists.txt -@@ -1,6 +1,6 @@ - cmake_minimum_required(VERSION 3.0) - --project(DILL VERSION 2.4.0 LANGUAGES C CXX) -+project(DILL VERSION 2.4.1 LANGUAGES C CXX) - - # Some boilerplate to setup nice output directories - include(GNUInstallDirs) -@@ -265,6 +265,9 @@ check_include_files(unistd.h HAVE_UNISTD_H) - check_include_files(stdarg.h STDC_HEADERS) - check_include_files(malloc.h HAVE_MALLOC_H) - check_include_files(memory.h HAVE_MEMORY_H) -+include(CheckSymbolExists) -+check_symbol_exists(__clear_cache "" CLEAR_CACHE_DEFINED) -+message(STATUS "Clear cache defined is ${CLEAR_CACHE_DEFINED}") - - set(NO_DISASSEMBLER TRUE) - if(DILL_ENABLE_DISASSEMBLY) -diff --git a/thirdparty/dill/dill/LICENSE b/thirdparty/dill/dill/LICENSE -new file mode 100644 -index 00000000..81b08341 ---- /dev/null -+++ b/thirdparty/dill/dill/LICENSE -@@ -0,0 +1,24 @@ -+Copyright (c) 2010, Georgia Tech Research Corporation -+All rights reserved. -+ -+Redistribution and use in source and binary forms, with or without -+modification, are permitted provided that the following conditions are met: -+ * Redistributions of source code must retain the above copyright -+ notice, this list of conditions and the following disclaimer. -+ * Redistributions in binary form must reproduce the above copyright -+ notice, this list of conditions and the following disclaimer in the -+ documentation and/or other materials provided with the distribution. -+ * Neither the name of the Georgia Tech Research Corporation nor the -+ names of its contributors may be used to endorse or promote products -+ derived from this software without specific prior written permission. -+ -+THIS SOFTWARE IS PROVIDED BY GEORGIA TECH RESEARCH CORPORATION ''AS IS'' AND -+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -+DISCLAIMED. IN NO EVENT SHALL GEORGIA TECH BE LIABLE FOR ANY DIRECT, INDIRECT, -+INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, -+OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -+LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE -+OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -+ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -diff --git a/thirdparty/dill/dill/arm6.c b/thirdparty/dill/dill/arm6.c -index f2be1725..da90507c 100644 ---- a/thirdparty/dill/dill/arm6.c -+++ b/thirdparty/dill/dill/arm6.c -@@ -1526,22 +1526,9 @@ arm6_call_link(dill_stream s) - } - - --/* Clear the instruction cache from `beg' to `end'. This makes an -- inline system call to SYS_cacheflush. */ --#define CLEAR_INSN_CACHE(BEG, END) \ --{ \ -- register unsigned long _beg __asm ("a1") = (unsigned long) (BEG); \ -- register unsigned long _end __asm ("a2") = (unsigned long) (END); \ -- register unsigned long _flg __asm ("a3") = 0; \ -- __asm __volatile ("swi 0x9f0002 @ sys_cacheflush" \ -- : "=r" (_beg) \ -- : "0" (_beg), "r" (_end), "r" (_flg)); \ --} --/* -- * Cache flush code grabbed from a Dec 1999 posting on libc-hacker -- * mailing list -- */ --extern void __clear_cache(char*, char *); -+#ifndef CLEAR_CACHE_DEFINED -+extern void __clear_cache(void *, void *); -+#endif - - static void - arm6_flush(void *base, void *limit) -diff --git a/thirdparty/dill/dill/arm6_rt.c b/thirdparty/dill/dill/arm6_rt.c -index 1f64b477..6b7e908e 100644 ---- a/thirdparty/dill/dill/arm6_rt.c -+++ b/thirdparty/dill/dill/arm6_rt.c -@@ -109,22 +109,9 @@ arm6_rt_call_link(char *code, call_t *t) - } - } - --/* Clear the instruction cache from `beg' to `end'. This makes an -- inline system call to SYS_cacheflush. */ --#define CLEAR_INSN_CACHE(BEG, END) \ --{ \ -- register unsigned long _beg __asm ("a1") = (unsigned long) (BEG); \ -- register unsigned long _end __asm ("a2") = (unsigned long) (END); \ -- register unsigned long _flg __asm ("a3") = 0; \ -- __asm __volatile ("swi 0x9f0002 @ sys_cacheflush" \ -- : "=r" (_beg) \ -- : "0" (_beg), "r" (_end), "r" (_flg)); \ --} --/* -- * Cache flush code grabbed from a Dec 1999 posting on libc-hacker -- * mailing list -- */ --extern void __clear_cache(char*, char *); -+#ifndef CLEAR_CACHE_DEFINED -+extern void __clear_cache(void *, void *); -+#endif - - static void - arm6_flush(void *base, void *limit) -diff --git a/thirdparty/dill/dill/arm8.c b/thirdparty/dill/dill/arm8.c -index fd5ed79f..d1894635 100644 ---- a/thirdparty/dill/dill/arm8.c -+++ b/thirdparty/dill/dill/arm8.c -@@ -1524,22 +1524,9 @@ arm8_call_link(dill_stream s) - } - - --/* Clear the instruction cache from `beg' to `end'. This makes an -- inline system call to SYS_cacheflush. */ --#define CLEAR_INSN_CACHE(BEG, END) \ --{ \ -- register unsigned long _beg __asm ("a1") = (unsigned long) (BEG); \ -- register unsigned long _end __asm ("a2") = (unsigned long) (END); \ -- register unsigned long _flg __asm ("a3") = 0; \ -- __asm __volatile ("swi 0x9f0002 @ sys_cacheflush" \ -- : "=r" (_beg) \ -- : "0" (_beg), "r" (_end), "r" (_flg)); \ --} --/* -- * Cache flush code grabbed from a Dec 1999 posting on libc-hacker -- * mailing list -- */ --extern void __clear_cache(char*, char *); -+#ifndef CLEAR_CACHE_DEFINED -+extern void __clear_cache(void *, void *); -+#endif - - static void - arm8_flush(void *base, void *limit) -diff --git a/thirdparty/dill/dill/arm8_rt.c b/thirdparty/dill/dill/arm8_rt.c -index bd0209cd..5cb107ed 100644 ---- a/thirdparty/dill/dill/arm8_rt.c -+++ b/thirdparty/dill/dill/arm8_rt.c -@@ -109,22 +109,9 @@ arm8_rt_call_link(char *code, call_t *t) - } - } - --/* Clear the instruction cache from `beg' to `end'. This makes an -- inline system call to SYS_cacheflush. */ --#define CLEAR_INSN_CACHE(BEG, END) \ --{ \ -- register unsigned long _beg __asm ("a1") = (unsigned long) (BEG); \ -- register unsigned long _end __asm ("a2") = (unsigned long) (END); \ -- register unsigned long _flg __asm ("a3") = 0; \ -- __asm __volatile ("swi 0x9f0002 @ sys_cacheflush" \ -- : "=r" (_beg) \ -- : "0" (_beg), "r" (_end), "r" (_flg)); \ --} --/* -- * Cache flush code grabbed from a Dec 1999 posting on libc-hacker -- * mailing list -- */ --extern void __clear_cache(char*, char *); -+#ifndef CLEAR_CACHE_DEFINED -+extern void __clear_cache(void *, void *); -+#endif - - static void - arm8_flush(void *base, void *limit) -diff --git a/thirdparty/dill/dill/config.h.cmake b/thirdparty/dill/dill/config.h.cmake -index a8519064..a9622f56 100644 ---- a/thirdparty/dill/dill/config.h.cmake -+++ b/thirdparty/dill/dill/config.h.cmake -@@ -16,10 +16,13 @@ - #cmakedefine HAVE_DIS_ASM_H - - /* Define to 1 if you have the header file. */ --#undef HAVE_DLFCN_H -+#cmakedefine HAVE_DLFCN_H - - /* Define to 1 if you have the header file. */ --#undef HAVE_INTTYPES_H -+#cmakedefine HAVE_INTTYPES_H -+ -+/* Define to 1 if you have __clear_cache is defined */ -+#cmakedefine CLEAR_CACHE_DEFINED - - /* Define to 1 if you have the header file. */ - #cmakedefine HAVE_MALLOC_H --- -2.18.1 - diff --git a/repo/packages/adios2/2.6-fix-gcc10-symbols.patch b/repo/packages/adios2/2.6-fix-gcc10-symbols.patch deleted file mode 100644 index 70f2afb1..00000000 --- a/repo/packages/adios2/2.6-fix-gcc10-symbols.patch +++ /dev/null @@ -1,32 +0,0 @@ -From 0ed2c03e407e6e6b501b00e7ce0b18f6a731ca6d Mon Sep 17 00:00:00 2001 -From: Kai Germaschewski -Date: Mon, 24 May 2021 15:00:38 -0400 -Subject: [PATCH] fix unresolved symbol errors when compiling with gcc10 - ---- - .../toolkit/format/dataman/DataManSerializer.cpp | 10 ++++++++++ - 1 file changed, 10 insertions(+) - -diff --git a/source/adios2/toolkit/format/dataman/DataManSerializer.cpp b/source/adios2/toolkit/format/dataman/DataManSerializer.cpp -index 697d080ae..0ecca6b23 100644 ---- a/source/adios2/toolkit/format/dataman/DataManSerializer.cpp -+++ b/source/adios2/toolkit/format/dataman/DataManSerializer.cpp -@@ -1143,5 +1143,15 @@ void DataManSerializer::Log(const int level, const std::string &message, - } - } - -+#define declare_template_instantiation(T) \ -+ template int DataManSerializer::GetData( \ -+ T * outputData, const std::string &varName, const Dims &varStart, \ -+ const Dims &varCount, const size_t step, const Dims &varMemStart, \ -+ const Dims &varMemCount); -+ -+ADIOS2_FOREACH_PRIMITIVE_STDTYPE_1ARG(declare_template_instantiation) -+declare_template_instantiation(std::string) -+#undef declare_template_instantiation -+ - } // namespace format - } // namespace adios2 --- -2.32.0.rc3 - diff --git a/repo/packages/adios2/2.7-fix-python-test-deps.patch b/repo/packages/adios2/2.7-fix-python-test-deps.patch deleted file mode 100644 index 38e689dc..00000000 --- a/repo/packages/adios2/2.7-fix-python-test-deps.patch +++ /dev/null @@ -1,175 +0,0 @@ -From 2454aafa08be8a275b2bdba56df1c38460d165ef Mon Sep 17 00:00:00 2001 -From: Chuck Atkins -Date: Fri, 22 Jan 2021 00:03:15 -0500 -Subject: [PATCH] Fix test dependency options to ignore python when testing is - disabled - ---- - CMakeLists.txt | 15 +++------------ - bindings/Matlab/README.txt | 2 +- - cmake/DetectOptions.cmake | 2 +- - scripts/conda/adios2/superbuild/CMakeLists.txt | 2 +- - scripts/docker/images/centos7/Dockerfile | 2 +- - scripts/docker/images/centos8/Dockerfile | 2 +- - scripts/docker/images/ubuntu/Dockerfile | 2 +- - scripts/runconf/runconf.sh | 2 +- - scripts/runconf/runconf_olcf.sh | 6 +++--- - 9 files changed, 13 insertions(+), 22 deletions(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 76e0e8fba..8823bbf87 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -114,6 +114,8 @@ if((NOT BUILD_SHARED_LIBS) AND (NOT DEFINED CMAKE_POSITION_INDEPENDENT_CODE)) - set(CMAKE_POSITION_INDEPENDENT_CODE ON) - endif() - -+include(CTest) -+ - adios_option(Blosc "Enable support for Blosc transforms" AUTO) - adios_option(BZip2 "Enable support for BZip2 transforms" AUTO) - adios_option(ZFP "Enable support for ZFP transforms" AUTO) -@@ -222,22 +224,11 @@ endif() - #------------------------------------------------------------------------------# - # Testing - #------------------------------------------------------------------------------# --if(DEFINED BUILD_TESTING) -- set(ADIOS2_BUILD_TESTING_DEFAULT ${BUILD_TESTING}) --else() -- set(ADIOS2_BUILD_TESTING_DEFAULT ON) --endif() --unset(BUILD_TESTING) --option(ADIOS2_BUILD_TESTING "Build the ADIOS2 testing tree" -- ${ADIOS2_BUILD_TESTING_DEFAULT}) -- - cmake_dependent_option(ADIOS2_RUN_MPI_MPMD_TESTS - "Enable the parallel MPMD tests" ON -- "ADIOS2_BUILD_TESTING;ADIOS2_HAVE_MPI" OFF) -+ "BUILD_TESTING;ADIOS2_HAVE_MPI" OFF) - mark_as_advanced(ADIOS2_RUN_MPI_MPMD_TESTS) - --include(CTest) --set(BUILD_TESTING ${ADIOS2_BUILD_TESTING}) - if(BUILD_TESTING) - find_program(DIFF_EXECUTABLE diff) - if(DIFF_EXECUTABLE) -diff --git a/bindings/Matlab/README.txt b/bindings/Matlab/README.txt -index 4b90fac77..f49b057bc 100644 ---- a/bindings/Matlab/README.txt -+++ b/bindings/Matlab/README.txt -@@ -43,5 +43,5 @@ $ cd - $ git pull - $ mkdir build.lean - $ cd build.lean --$ cmake -DCMAKE_INSTALL_PREFIX=/opt/adios/lean -DADIOS2_USE_MPI=OFF -DADIOS2_USE_Fortran=OFF -DADIOS2_USE_Python=OFF -DADIOS2_BUILD_EXAMPLES_EXPERIMENTAL=OFF -DCMAKE_BUILD_TYPE=RelWithDebInfo -DADIOS2_ENABLE_PIC=ON -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DADIOS2_BUILD_TESTING=OFF -DADIOS2_USE_SST=OFF -DADIOS2_USE_BZip2=OFF -DADIOS2_USE_DataMan=OFF .. -+$ cmake -DCMAKE_INSTALL_PREFIX=/opt/adios/lean -DADIOS2_USE_MPI=OFF -DADIOS2_USE_Fortran=OFF -DADIOS2_USE_Python=OFF -DADIOS2_BUILD_EXAMPLES_EXPERIMENTAL=OFF -DCMAKE_BUILD_TYPE=RelWithDebInfo -DADIOS2_ENABLE_PIC=ON -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DBUILD_TESTING=OFF -DADIOS2_USE_SST=OFF -DADIOS2_USE_BZip2=OFF -DADIOS2_USE_DataMan=OFF .. - -diff --git a/cmake/DetectOptions.cmake b/cmake/DetectOptions.cmake -index ca449feee..3b8652d2d 100644 ---- a/cmake/DetectOptions.cmake -+++ b/cmake/DetectOptions.cmake -@@ -293,7 +293,7 @@ if(Python_FOUND) - endif() - - # Even if no python support, we still want the interpreter for tests --if(NOT Python_Interpreter_FOUND) -+if(BUILD_TESTING AND NOT Python_Interpreter_FOUND) - find_package(Python REQUIRED COMPONENTS Interpreter) - endif() - -diff --git a/scripts/conda/adios2/superbuild/CMakeLists.txt b/scripts/conda/adios2/superbuild/CMakeLists.txt -index 75e2ad984..ef0eec25b 100644 ---- a/scripts/conda/adios2/superbuild/CMakeLists.txt -+++ b/scripts/conda/adios2/superbuild/CMakeLists.txt -@@ -12,7 +12,7 @@ ExternalProject_Add(adios2 - -DCMAKE_BUILD_TYPE=Release - -DBUILD_SHARED_LIBS=ON - -DADIOS2_BUILD_EXAMPLES=OFF -- -DADIOS2_BUILD_TESTING=OFF -+ -DBUILD_TESTING=OFF - -DADIOS2_USE_Python=ON - -DPYTHON_EXECUTABLE=$ENV{PYTHON} - -DADIOS2_USE_MPI=ON -diff --git a/scripts/docker/images/centos7/Dockerfile b/scripts/docker/images/centos7/Dockerfile -index 96cb30acb..974bd90eb 100644 ---- a/scripts/docker/images/centos7/Dockerfile -+++ b/scripts/docker/images/centos7/Dockerfile -@@ -116,7 +116,7 @@ RUN git clone https://github.com/ornladios/adios2.git source && \ - module load mpi && \ - cmake -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Release \ - -DCMAKE_INSTALL_PREFIX=/opt/adios/${adios_ver_dir} \ -- -DADIOS2_BUILD_TESTING=OFF \ -+ -DBUILD_TESTING=OFF \ - -DADIOS2_BUILD_EXAMPLES=OFF \ - ../source && \ - make -j$(grep -c '^processor' /proc/cpuinfo) install && \ -diff --git a/scripts/docker/images/centos8/Dockerfile b/scripts/docker/images/centos8/Dockerfile -index 01e3af8cb..21a78c913 100644 ---- a/scripts/docker/images/centos8/Dockerfile -+++ b/scripts/docker/images/centos8/Dockerfile -@@ -116,7 +116,7 @@ RUN git clone https://github.com/ornladios/adios2.git source && \ - module load mpi && \ - cmake -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Release \ - -DCMAKE_INSTALL_PREFIX=/opt/adios/${adios_ver_dir} \ -- -DADIOS2_BUILD_TESTING=OFF \ -+ -DBUILD_TESTING=OFF \ - -DADIOS2_BUILD_EXAMPLES=OFF \ - ../source && \ - make -j$(grep -c '^processor' /proc/cpuinfo) install && \ -diff --git a/scripts/docker/images/ubuntu/Dockerfile b/scripts/docker/images/ubuntu/Dockerfile -index 1979b81a0..e0f654efb 100644 ---- a/scripts/docker/images/ubuntu/Dockerfile -+++ b/scripts/docker/images/ubuntu/Dockerfile -@@ -118,7 +118,7 @@ RUN git clone https://github.com/ornladios/adios2.git source && \ - . /etc/profile && \ - cmake -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Release \ - -DCMAKE_INSTALL_PREFIX=/opt/adios/${adios_ver_dir} \ -- -DADIOS2_BUILD_TESTING=OFF \ -+ -DBUILD_TESTING=OFF \ - -DADIOS2_BUILD_EXAMPLES=OFF \ - ../source && \ - make -j$(grep -c '^processor' /proc/cpuinfo) install && \ -diff --git a/scripts/runconf/runconf.sh b/scripts/runconf/runconf.sh -index 82c3ea21e..ec12ba7ef 100644 ---- a/scripts/runconf/runconf.sh -+++ b/scripts/runconf/runconf.sh -@@ -46,7 +46,7 @@ cmake -DCMAKE_INSTALL_PREFIX=${PWD}/install \ - -DBUILD_SHARED_LIBS=ON \ - -DCMAKE_POSITION_INDEPENDENT_CODE=ON \ - -DCMAKE_BUILD_TYPE=Release \ -- -DADIOS2_BUILD_TESTING=${VALUE} \ -+ -DBUILD_TESTING=${VALUE} \ - -DADIOS2_BUILD_EXAMPLES=${VALUE} \ - -DADIOS2_USE_Endian_Reverse=OFF \ - ${ADIOS2_SOURCE} -diff --git a/scripts/runconf/runconf_olcf.sh b/scripts/runconf/runconf_olcf.sh -index 562f9b3dd..3d1ea83bc 100644 ---- a/scripts/runconf/runconf_olcf.sh -+++ b/scripts/runconf/runconf_olcf.sh -@@ -68,7 +68,7 @@ if [ `hostname | cut -c 1-5` == "titan" ]; then - -DADIOS2_USE_Python=OFF \ - -DADIOS2_BUILD_EXAMPLES_EXPERIMENTAL=OFF \ - -DCMAKE_BUILD_TYPE=RelWithDebInfo \ -- -DADIOS2_BUILD_TESTING=OFF \ -+ -DBUILD_TESTING=OFF \ - ${EXTERNAL_OPTS} \ - ${SRCDIR} - -@@ -118,7 +118,7 @@ elif [ `hostname -f | cut -c 1-9` == "summitdev" ]; then - -DADIOS2_USE_Python=OFF \ - -DADIOS2_BUILD_EXAMPLES_EXPERIMENTAL=OFF \ - -DCMAKE_BUILD_TYPE=Debug \ -- -DADIOS2_BUILD_TESTING=ON \ -+ -DBUILD_TESTING=ON \ - -DADIOS2_USE_DataMan=OFF \ - ${EXTERNAL_OPTS} \ - ${SRCDIR} -@@ -156,7 +156,7 @@ elif [ `hostname -f | cut -c 1-4` == "rhea" ]; then - -DADIOS2_USE_SST=OFF \ - -DADIOS2_BUILD_EXAMPLES_EXPERIMENTAL=OFF \ - -DCMAKE_BUILD_TYPE=Debug \ -- -DADIOS2_BUILD_TESTING=ON \ -+ -DBUILD_TESTING=ON \ - -DADIOS2_USE_DataMan=OFF \ - ${EXTERNAL_OPTS} \ - ${SRCDIR} diff --git a/repo/packages/adios2/cmake-update-findmpi.patch b/repo/packages/adios2/cmake-update-findmpi.patch deleted file mode 100644 index 1e00ca0b..00000000 --- a/repo/packages/adios2/cmake-update-findmpi.patch +++ /dev/null @@ -1,837 +0,0 @@ -diff --git a/cmake/FindMPI.cmake b/cmake/FindMPI.cmake -index b1bcb97..2244878 100644 ---- a/cmake/FindMPI.cmake -+++ b/cmake/FindMPI.cmake -@@ -4,7 +4,7 @@ - #------------------------------------------------------------------------------# - - # This module is already included in new versions of CMake --if(CMAKE_VERSION VERSION_LESS 4.0) -+if(CMAKE_VERSION VERSION_LESS 3.15.1) - include(${CMAKE_CURRENT_LIST_DIR}/upstream/FindMPI.cmake) - else() - include(${CMAKE_ROOT}/Modules/FindMPI.cmake) -diff --git a/cmake/upstream/FindMPI.cmake b/cmake/upstream/FindMPI.cmake -index 6a874b3..8551821 100644 ---- a/cmake/upstream/FindMPI.cmake -+++ b/cmake/upstream/FindMPI.cmake -@@ -1,252 +1,263 @@ - # Distributed under the OSI-approved BSD 3-Clause License. See accompanying - # file Copyright.txt or https://cmake.org/licensing for details. - --#.rst: --# FindMPI --# ------- --# --# Find a Message Passing Interface (MPI) implementation. --# --# The Message Passing Interface (MPI) is a library used to write --# high-performance distributed-memory parallel applications, and is --# typically deployed on a cluster. MPI is a standard interface (defined --# by the MPI forum) for which many implementations are available. --# --# Variables for using MPI --# ^^^^^^^^^^^^^^^^^^^^^^^ --# --# The module exposes the components ``C``, ``CXX``, ``MPICXX`` and ``Fortran``. --# Each of these controls the various MPI languages to search for. --# The difference between ``CXX`` and ``MPICXX`` is that ``CXX`` refers to the --# MPI C API being usable from C++, whereas ``MPICXX`` refers to the MPI-2 C++ API --# that was removed again in MPI-3. --# --# Depending on the enabled components the following variables will be set: --# --# ``MPI_FOUND`` --# Variable indicating that MPI settings for all requested languages have been found. --# If no components are specified, this is true if MPI settings for all enabled languages --# were detected. Note that the ``MPICXX`` component does not affect this variable. --# ``MPI_VERSION`` --# Minimal version of MPI detected among the requested languages, or all enabled languages --# if no components were specified. --# --# This module will set the following variables per language in your --# project, where ```` is one of C, CXX, or Fortran: --# --# ``MPI__FOUND`` --# Variable indicating the MPI settings for ```` were found and that --# simple MPI test programs compile with the provided settings. --# ``MPI__COMPILER`` --# MPI compiler for ```` if such a program exists. --# ``MPI__COMPILE_OPTIONS`` --# Compilation options for MPI programs in ````, given as a :ref:`;-list `. --# ``MPI__COMPILE_DEFINITIONS`` --# Compilation definitions for MPI programs in ````, given as a :ref:`;-list `. --# ``MPI__INCLUDE_DIRS`` --# Include path(s) for MPI header. --# ``MPI__LINK_FLAGS`` --# Linker flags for MPI programs. --# ``MPI__LIBRARIES`` --# All libraries to link MPI programs against. --# --# Additionally, the following :prop_tgt:`IMPORTED` targets are defined: --# --# ``MPI::MPI_`` --# Target for using MPI from ````. --# --# The following variables indicating which bindings are present will be defined: --# --# ``MPI_MPICXX_FOUND`` --# Variable indicating whether the MPI-2 C++ bindings are present (introduced in MPI-2, removed with MPI-3). --# ``MPI_Fortran_HAVE_F77_HEADER`` --# True if the Fortran 77 header ``mpif.h`` is available. --# ``MPI_Fortran_HAVE_F90_MODULE`` --# True if the Fortran 90 module ``mpi`` can be used for accessing MPI (MPI-2 and higher only). --# ``MPI_Fortran_HAVE_F08_MODULE`` --# True if the Fortran 2008 ``mpi_f08`` is available to MPI programs (MPI-3 and higher only). --# --# If possible, the MPI version will be determined by this module. The facilities to detect the MPI version --# were introduced with MPI-1.2, and therefore cannot be found for older MPI versions. --# --# ``MPI__VERSION_MAJOR`` --# Major version of MPI implemented for ```` by the MPI distribution. --# ``MPI__VERSION_MINOR`` --# Minor version of MPI implemented for ```` by the MPI distribution. --# ``MPI__VERSION`` --# MPI version implemented for ```` by the MPI distribution. --# --# Note that there's no variable for the C bindings being accessible through ``mpi.h``, since the MPI standards --# always have required this binding to work in both C and C++ code. --# --# For running MPI programs, the module sets the following variables --# --# ``MPIEXEC_EXECUTABLE`` --# Executable for running MPI programs, if such exists. --# ``MPIEXEC_NUMPROC_FLAG`` --# Flag to pass to ``mpiexec`` before giving it the number of processors to run on. --# ``MPIEXEC_MAX_NUMPROCS`` --# Number of MPI processors to utilize. Defaults to the number --# of processors detected on the host system. --# ``MPIEXEC_PREFLAGS`` --# Flags to pass to ``mpiexec`` directly before the executable to run. --# ``MPIEXEC_POSTFLAGS`` --# Flags to pass to ``mpiexec`` after other flags. --# --# Variables for locating MPI --# ^^^^^^^^^^^^^^^^^^^^^^^^^^ --# --# This module performs a three step search for an MPI implementation: --# --# 1. Check if the compiler has MPI support built-in. This is the case if the user passed a --# compiler wrapper as ``CMAKE__COMPILER`` or if they're on a Cray system. --# 2. Attempt to find an MPI compiler wrapper and determine the compiler information from it. --# 3. Try to find an MPI implementation that does not ship such a wrapper by guessing settings. --# Currently, only Microsoft MPI and MPICH2 on Windows are supported. --# --# For controlling the second step, the following variables may be set: --# --# ``MPI__COMPILER`` --# Search for the specified compiler wrapper and use it. --# ``MPI__COMPILER_FLAGS`` --# Flags to pass to the MPI compiler wrapper during interrogation. Some compiler wrappers --# support linking debug or tracing libraries if a specific flag is passed and this variable --# may be used to obtain them. --# ``MPI_COMPILER_FLAGS`` --# Used to initialize ``MPI__COMPILER_FLAGS`` if no language specific flag has been given. --# Empty by default. --# ``MPI_EXECUTABLE_SUFFIX`` --# A suffix which is appended to all names that are being looked for. For instance you may set this --# to ``.mpich`` or ``.openmpi`` to prefer the one or the other on Debian and its derivatives. --# --# In order to control the guessing step, the following variable may be set: --# --# ``MPI_GUESS_LIBRARY_NAME`` --# Valid values are ``MSMPI`` and ``MPICH2``. If set, only the given library will be searched for. --# By default, ``MSMPI`` will be preferred over ``MPICH2`` if both are available. --# This also sets ``MPI_SKIP_COMPILER_WRAPPER`` to ``true``, which may be overridden. --# --# Each of the search steps may be skipped with the following control variables: --# --# ``MPI_ASSUME_NO_BUILTIN_MPI`` --# If true, the module assumes that the compiler itself does not provide an MPI implementation and --# skips to step 2. --# ``MPI_SKIP_COMPILER_WRAPPER`` --# If true, no compiler wrapper will be searched for. --# ``MPI_SKIP_GUESSING`` --# If true, the guessing step will be skipped. --# --# Additionally, the following control variable is available to change search behavior: --# --# ``MPI_CXX_SKIP_MPICXX`` --# Add some definitions that will disable the MPI-2 C++ bindings. --# Currently supported are MPICH, Open MPI, Platform MPI and derivatives thereof, --# for example MVAPICH or Intel MPI. --# --# If the find procedure fails for a variable ``MPI__WORKS``, then the settings detected by or passed to --# the module did not work and even a simple MPI test program failed to compile. --# --# If all of these parameters were not sufficient to find the right MPI implementation, a user may --# disable the entire autodetection process by specifying both a list of libraries in ``MPI__LIBRARIES`` --# and a list of include directories in ``MPI__ADDITIONAL_INCLUDE_DIRS``. --# Any other variable may be set in addition to these two. The module will then validate the MPI settings and store the --# settings in the cache. --# --# Cache variables for MPI --# ^^^^^^^^^^^^^^^^^^^^^^^ --# --# The variable ``MPI__INCLUDE_DIRS`` will be assembled from the following variables. --# For C and CXX: --# --# ``MPI__HEADER_DIR`` --# Location of the ``mpi.h`` header on disk. --# --# For Fortran: --# --# ``MPI_Fortran_F77_HEADER_DIR`` --# Location of the Fortran 77 header ``mpif.h``, if it exists. --# ``MPI_Fortran_MODULE_DIR`` --# Location of the ``mpi`` or ``mpi_f08`` modules, if available. --# --# For all languages the following variables are additionally considered: --# --# ``MPI__ADDITIONAL_INCLUDE_DIRS`` --# A :ref:`;-list ` of paths needed in addition to the normal include directories. --# ``MPI__INCLUDE_DIR`` --# Path variables for include folders referred to by ````. --# ``MPI__ADDITIONAL_INCLUDE_VARS`` --# A :ref:`;-list ` of ```` that will be added to the include locations of ````. --# --# The variable ``MPI__LIBRARIES`` will be assembled from the following variables: --# --# ``MPI__LIBRARY`` --# The location of a library called ```` for use with MPI. --# ``MPI__LIB_NAMES`` --# A :ref:`;-list ` of ```` that will be added to the include locations of ````. --# --# Usage of mpiexec --# ^^^^^^^^^^^^^^^^ --# --# When using ``MPIEXEC_EXECUTABLE`` to execute MPI applications, you should typically --# use all of the ``MPIEXEC_EXECUTABLE`` flags as follows: --# --# :: --# --# ${MPIEXEC_EXECUTABLE} ${MPIEXEC_NUMPROC_FLAG} ${MPIEXEC_MAX_NUMPROCS} --# ${MPIEXEC_PREFLAGS} EXECUTABLE ${MPIEXEC_POSTFLAGS} ARGS --# --# where ``EXECUTABLE`` is the MPI program, and ``ARGS`` are the arguments to --# pass to the MPI program. --# --# Advanced variables for using MPI --# ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ --# --# The module can perform some advanced feature detections upon explicit request. --# --# **Important notice:** The following checks cannot be performed without *executing* an MPI test program. --# Consider the special considerations for the behavior of :command:`try_run` during cross compilation. --# Moreover, running an MPI program can cause additional issues, like a firewall notification on some systems. --# You should only enable these detections if you absolutely need the information. --# --# If the following variables are set to true, the respective search will be performed: --# --# ``MPI_DETERMINE_Fortran_CAPABILITIES`` --# Determine for all available Fortran bindings what the values of ``MPI_SUBARRAYS_SUPPORTED`` and --# ``MPI_ASYNC_PROTECTS_NONBLOCKING`` are and make their values available as ``MPI_Fortran__SUBARRAYS`` --# and ``MPI_Fortran__ASYNCPROT``, where ```` is one of ``F77_HEADER``, ``F90_MODULE`` and --# ``F08_MODULE``. --# ``MPI_DETERMINE_LIBRARY_VERSION`` --# For each language, find the output of ``MPI_Get_library_version`` and make it available as ``MPI__LIBRARY_VERSION``. --# This information is usually tied to the runtime component of an MPI implementation and might differ depending on ````. --# Note that the return value is entirely implementation defined. This information might be used to identify --# the MPI vendor and for example pick the correct one of multiple third party binaries that matches the MPI vendor. --# --# Backward Compatibility --# ^^^^^^^^^^^^^^^^^^^^^^ --# --# For backward compatibility with older versions of FindMPI, these --# variables are set, but deprecated: --# --# :: --# --# MPI_COMPILER MPI_LIBRARY MPI_EXTRA_LIBRARY --# MPI_COMPILE_FLAGS MPI_INCLUDE_PATH MPI_LINK_FLAGS --# MPI_LIBRARIES --# --# In new projects, please use the ``MPI__XXX`` equivalents. --# Additionally, the following variables are deprecated: --# --# ``MPI__COMPILE_FLAGS`` --# Use ``MPI__COMPILE_OPTIONS`` and ``MPI__COMPILE_DEFINITIONS`` instead. --# ``MPI__INCLUDE_PATH`` --# For consumption use ``MPI__INCLUDE_DIRS`` and for specifying folders use ``MPI__ADDITIONAL_INCLUDE_DIRS`` instead. --# ``MPIEXEC`` --# Use ``MPIEXEC_EXECUTABLE`` instead. -+#[=======================================================================[.rst: -+FindMPI -+------- -+ -+Find a Message Passing Interface (MPI) implementation. -+ -+The Message Passing Interface (MPI) is a library used to write -+high-performance distributed-memory parallel applications, and is -+typically deployed on a cluster. MPI is a standard interface (defined -+by the MPI forum) for which many implementations are available. -+ -+Variables for using MPI -+^^^^^^^^^^^^^^^^^^^^^^^ -+ -+The module exposes the components ``C``, ``CXX``, ``MPICXX`` and ``Fortran``. -+Each of these controls the various MPI languages to search for. -+The difference between ``CXX`` and ``MPICXX`` is that ``CXX`` refers to the -+MPI C API being usable from C++, whereas ``MPICXX`` refers to the MPI-2 C++ API -+that was removed again in MPI-3. -+ -+Depending on the enabled components the following variables will be set: -+ -+``MPI_FOUND`` -+ Variable indicating that MPI settings for all requested languages have been found. -+ If no components are specified, this is true if MPI settings for all enabled languages -+ were detected. Note that the ``MPICXX`` component does not affect this variable. -+``MPI_VERSION`` -+ Minimal version of MPI detected among the requested languages, or all enabled languages -+ if no components were specified. -+ -+This module will set the following variables per language in your -+project, where ```` is one of C, CXX, or Fortran: -+ -+``MPI__FOUND`` -+ Variable indicating the MPI settings for ```` were found and that -+ simple MPI test programs compile with the provided settings. -+``MPI__COMPILER`` -+ MPI compiler for ```` if such a program exists. -+``MPI__COMPILE_OPTIONS`` -+ Compilation options for MPI programs in ````, given as a :ref:`;-list `. -+``MPI__COMPILE_DEFINITIONS`` -+ Compilation definitions for MPI programs in ````, given as a :ref:`;-list `. -+``MPI__INCLUDE_DIRS`` -+ Include path(s) for MPI header. -+``MPI__LINK_FLAGS`` -+ Linker flags for MPI programs. -+``MPI__LIBRARIES`` -+ All libraries to link MPI programs against. -+ -+Additionally, the following :prop_tgt:`IMPORTED` targets are defined: -+ -+``MPI::MPI_`` -+ Target for using MPI from ````. -+ -+The following variables indicating which bindings are present will be defined: -+ -+``MPI_MPICXX_FOUND`` -+ Variable indicating whether the MPI-2 C++ bindings are present (introduced in MPI-2, removed with MPI-3). -+``MPI_Fortran_HAVE_F77_HEADER`` -+ True if the Fortran 77 header ``mpif.h`` is available. -+``MPI_Fortran_HAVE_F90_MODULE`` -+ True if the Fortran 90 module ``mpi`` can be used for accessing MPI (MPI-2 and higher only). -+``MPI_Fortran_HAVE_F08_MODULE`` -+ True if the Fortran 2008 ``mpi_f08`` is available to MPI programs (MPI-3 and higher only). -+ -+If possible, the MPI version will be determined by this module. The facilities to detect the MPI version -+were introduced with MPI-1.2, and therefore cannot be found for older MPI versions. -+ -+``MPI__VERSION_MAJOR`` -+ Major version of MPI implemented for ```` by the MPI distribution. -+``MPI__VERSION_MINOR`` -+ Minor version of MPI implemented for ```` by the MPI distribution. -+``MPI__VERSION`` -+ MPI version implemented for ```` by the MPI distribution. -+ -+Note that there's no variable for the C bindings being accessible through ``mpi.h``, since the MPI standards -+always have required this binding to work in both C and C++ code. -+ -+For running MPI programs, the module sets the following variables -+ -+``MPIEXEC_EXECUTABLE`` -+ Executable for running MPI programs, if such exists. -+``MPIEXEC_NUMPROC_FLAG`` -+ Flag to pass to ``mpiexec`` before giving it the number of processors to run on. -+``MPIEXEC_MAX_NUMPROCS`` -+ Number of MPI processors to utilize. Defaults to the number -+ of processors detected on the host system. -+``MPIEXEC_PREFLAGS`` -+ Flags to pass to ``mpiexec`` directly before the executable to run. -+``MPIEXEC_POSTFLAGS`` -+ Flags to pass to ``mpiexec`` after other flags. -+ -+Variables for locating MPI -+^^^^^^^^^^^^^^^^^^^^^^^^^^ -+ -+This module performs a three step search for an MPI implementation: -+ -+1. Check if the compiler has MPI support built-in. This is the case if the user passed a -+ compiler wrapper as ``CMAKE__COMPILER`` or if they're on a Cray system. -+2. Attempt to find an MPI compiler wrapper and determine the compiler information from it. -+3. Try to find an MPI implementation that does not ship such a wrapper by guessing settings. -+ Currently, only Microsoft MPI and MPICH2 on Windows are supported. -+ -+For controlling the second step, the following variables may be set: -+ -+``MPI__COMPILER`` -+ Search for the specified compiler wrapper and use it. -+``MPI__COMPILER_FLAGS`` -+ Flags to pass to the MPI compiler wrapper during interrogation. Some compiler wrappers -+ support linking debug or tracing libraries if a specific flag is passed and this variable -+ may be used to obtain them. -+``MPI_COMPILER_FLAGS`` -+ Used to initialize ``MPI__COMPILER_FLAGS`` if no language specific flag has been given. -+ Empty by default. -+``MPI_EXECUTABLE_SUFFIX`` -+ A suffix which is appended to all names that are being looked for. For instance you may set this -+ to ``.mpich`` or ``.openmpi`` to prefer the one or the other on Debian and its derivatives. -+ -+In order to control the guessing step, the following variable may be set: -+ -+``MPI_GUESS_LIBRARY_NAME`` -+ Valid values are ``MSMPI`` and ``MPICH2``. If set, only the given library will be searched for. -+ By default, ``MSMPI`` will be preferred over ``MPICH2`` if both are available. -+ This also sets ``MPI_SKIP_COMPILER_WRAPPER`` to ``true``, which may be overridden. -+ -+Each of the search steps may be skipped with the following control variables: -+ -+``MPI_ASSUME_NO_BUILTIN_MPI`` -+ If true, the module assumes that the compiler itself does not provide an MPI implementation and -+ skips to step 2. -+``MPI_SKIP_COMPILER_WRAPPER`` -+ If true, no compiler wrapper will be searched for. -+``MPI_SKIP_GUESSING`` -+ If true, the guessing step will be skipped. -+ -+Additionally, the following control variable is available to change search behavior: -+ -+``MPI_CXX_SKIP_MPICXX`` -+ Add some definitions that will disable the MPI-2 C++ bindings. -+ Currently supported are MPICH, Open MPI, Platform MPI and derivatives thereof, -+ for example MVAPICH or Intel MPI. -+ -+If the find procedure fails for a variable ``MPI__WORKS``, then the settings detected by or passed to -+the module did not work and even a simple MPI test program failed to compile. -+ -+If all of these parameters were not sufficient to find the right MPI implementation, a user may -+disable the entire autodetection process by specifying both a list of libraries in ``MPI__LIBRARIES`` -+and a list of include directories in ``MPI__ADDITIONAL_INCLUDE_DIRS``. -+Any other variable may be set in addition to these two. The module will then validate the MPI settings and store the -+settings in the cache. -+ -+Cache variables for MPI -+^^^^^^^^^^^^^^^^^^^^^^^ -+ -+The variable ``MPI__INCLUDE_DIRS`` will be assembled from the following variables. -+For C and CXX: -+ -+``MPI__HEADER_DIR`` -+ Location of the ``mpi.h`` header on disk. -+ -+For Fortran: -+ -+``MPI_Fortran_F77_HEADER_DIR`` -+ Location of the Fortran 77 header ``mpif.h``, if it exists. -+``MPI_Fortran_MODULE_DIR`` -+ Location of the ``mpi`` or ``mpi_f08`` modules, if available. -+ -+For all languages the following variables are additionally considered: -+ -+``MPI__ADDITIONAL_INCLUDE_DIRS`` -+ A :ref:`;-list ` of paths needed in addition to the normal include directories. -+``MPI__INCLUDE_DIR`` -+ Path variables for include folders referred to by ````. -+``MPI__ADDITIONAL_INCLUDE_VARS`` -+ A :ref:`;-list ` of ```` that will be added to the include locations of ````. -+ -+The variable ``MPI__LIBRARIES`` will be assembled from the following variables: -+ -+``MPI__LIBRARY`` -+ The location of a library called ```` for use with MPI. -+``MPI__LIB_NAMES`` -+ A :ref:`;-list ` of ```` that will be added to the include locations of ````. -+ -+Usage of mpiexec -+^^^^^^^^^^^^^^^^ -+ -+When using ``MPIEXEC_EXECUTABLE`` to execute MPI applications, you should typically -+use all of the ``MPIEXEC_EXECUTABLE`` flags as follows: -+ -+:: -+ -+ ${MPIEXEC_EXECUTABLE} ${MPIEXEC_NUMPROC_FLAG} ${MPIEXEC_MAX_NUMPROCS} -+ ${MPIEXEC_PREFLAGS} EXECUTABLE ${MPIEXEC_POSTFLAGS} ARGS -+ -+where ``EXECUTABLE`` is the MPI program, and ``ARGS`` are the arguments to -+pass to the MPI program. -+ -+Advanced variables for using MPI -+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -+ -+The module can perform some advanced feature detections upon explicit request. -+ -+**Important notice:** The following checks cannot be performed without *executing* an MPI test program. -+Consider the special considerations for the behavior of :command:`try_run` during cross compilation. -+Moreover, running an MPI program can cause additional issues, like a firewall notification on some systems. -+You should only enable these detections if you absolutely need the information. -+ -+If the following variables are set to true, the respective search will be performed: -+ -+``MPI_DETERMINE_Fortran_CAPABILITIES`` -+ Determine for all available Fortran bindings what the values of ``MPI_SUBARRAYS_SUPPORTED`` and -+ ``MPI_ASYNC_PROTECTS_NONBLOCKING`` are and make their values available as ``MPI_Fortran__SUBARRAYS`` -+ and ``MPI_Fortran__ASYNCPROT``, where ```` is one of ``F77_HEADER``, ``F90_MODULE`` and -+ ``F08_MODULE``. -+``MPI_DETERMINE_LIBRARY_VERSION`` -+ For each language, find the output of ``MPI_Get_library_version`` and make it available as ``MPI__LIBRARY_VERSION_STRING``. -+ This information is usually tied to the runtime component of an MPI implementation and might differ depending on ````. -+ Note that the return value is entirely implementation defined. This information might be used to identify -+ the MPI vendor and for example pick the correct one of multiple third party binaries that matches the MPI vendor. -+ -+Backward Compatibility -+^^^^^^^^^^^^^^^^^^^^^^ -+ -+For backward compatibility with older versions of FindMPI, these -+variables are set, but deprecated: -+ -+:: -+ -+ MPI_COMPILER MPI_LIBRARY MPI_EXTRA_LIBRARY -+ MPI_COMPILE_FLAGS MPI_INCLUDE_PATH MPI_LINK_FLAGS -+ MPI_LIBRARIES -+ -+In new projects, please use the ``MPI__XXX`` equivalents. -+Additionally, the following variables are deprecated: -+ -+``MPI__COMPILE_FLAGS`` -+ Use ``MPI__COMPILE_OPTIONS`` and ``MPI__COMPILE_DEFINITIONS`` instead. -+``MPI__INCLUDE_PATH`` -+ For consumption use ``MPI__INCLUDE_DIRS`` and for specifying folders use ``MPI__ADDITIONAL_INCLUDE_DIRS`` instead. -+``MPIEXEC`` -+ Use ``MPIEXEC_EXECUTABLE`` instead. -+#]=======================================================================] - - cmake_policy(PUSH) - cmake_policy(SET CMP0057 NEW) # if IN_LIST - --include(FindPackageHandleStandardArgs) -+include(${CMAKE_ROOT}/Modules/FindPackageHandleStandardArgs.cmake) -+ -+if(CMAKE_VERISON VERSION_LESS 3.9) -+ if(WIN32) -+ set(_sep_args_type WINDOWS_COMMAND) -+ else() -+ set(_sep_args_type UNIX_COMMAND) -+ endif() -+else() -+ set(_sep_args_type NATIVE_COMMAND) -+endif() - - # Generic compiler names - set(_MPI_C_GENERIC_COMPILER_NAMES mpicc mpcc mpicc_r mpcc_r) -@@ -331,16 +342,10 @@ endforeach() - unset(_MPIEXEC_NAMES_BASE) - - function (_MPI_check_compiler LANG QUERY_FLAG OUTPUT_VARIABLE RESULT_VARIABLE) -- # Helper variable for command seperation -- if(WIN32) -- set(_MPI_COMMAND_TYPE WINDOWS_COMMAND) -- else() -- set(_MPI_COMMAND_TYPE UNIX_COMMAND) -- endif() - if(DEFINED MPI_${LANG}_COMPILER_FLAGS) -- separate_arguments(_MPI_COMPILER_WRAPPER_OPTIONS ${_MPI_COMMAND_TYPE} "${MPI_${LANG}_COMPILER_FLAGS}") -+ separate_arguments(_MPI_COMPILER_WRAPPER_OPTIONS ${_sep_args_type} "${MPI_${LANG}_COMPILER_FLAGS}") - else() -- separate_arguments(_MPI_COMPILER_WRAPPER_OPTIONS ${_MPI_COMMAND_TYPE} "${MPI_COMPILER_FLAGS}") -+ separate_arguments(_MPI_COMPILER_WRAPPER_OPTIONS ${_sep_args_type} "${MPI_COMPILER_FLAGS}") - endif() - execute_process( - COMMAND ${MPI_${LANG}_COMPILER} ${_MPI_COMPILER_WRAPPER_OPTIONS} ${QUERY_FLAG} -@@ -628,7 +633,7 @@ function (_MPI_interrogate_compiler LANG) - if (NOT MPI_ALL_INCLUDE_PATHS) - _MPI_check_compiler(${LANG} "-showme:incdirs" MPI_INCDIRS_CMDLINE MPI_INCDIRS_COMPILER_RETURN) - if(MPI_INCDIRS_COMPILER_RETURN) -- separate_arguments(MPI_ALL_INCLUDE_PATHS NATIVE_COMMAND "${MPI_INCDIRS_CMDLINE}") -+ separate_arguments(MPI_ALL_INCLUDE_PATHS ${_sep_args_type} "${MPI_INCDIRS_CMDLINE}") - endif() - endif() - -@@ -696,7 +701,7 @@ function (_MPI_interrogate_compiler LANG) - if (NOT MPI_ALL_LINK_PATHS) - _MPI_check_compiler(${LANG} "-showme:libdirs" MPI_LIBDIRS_CMDLINE MPI_LIBDIRS_COMPILER_RETURN) - if(MPI_LIBDIRS_COMPILER_RETURN) -- separate_arguments(MPI_ALL_LINK_PATHS NATIVE_COMMAND "${MPI_LIBDIRS_CMDLINE}") -+ separate_arguments(MPI_ALL_LINK_PATHS ${_sep_args_type} "${MPI_LIBDIRS_CMDLINE}") - endif() - endif() - -@@ -775,18 +780,20 @@ function (_MPI_interrogate_compiler LANG) - endforeach() - - # Add the link directories given explicitly that we haven't used back as linker directories. -- foreach(_MPI_LINK_DIRECTORY IN LISTS MPI_LINK_DIRECTORIES_LEFTOVER) -- file(TO_NATIVE_PATH "${_MPI_LINK_DIRECTORY}" _MPI_LINK_DIRECTORY_ACTUAL) -- string(FIND "${_MPI_LINK_DIRECTORY_ACTUAL}" " " _MPI_LINK_DIRECTORY_CONTAINS_SPACE) -- if(NOT _MPI_LINK_DIRECTORY_CONTAINS_SPACE EQUAL -1) -- set(_MPI_LINK_DIRECTORY_ACTUAL "\"${_MPI_LINK_DIRECTORY_ACTUAL}\"") -- endif() -- if(MPI_LINK_FLAGS_WORK) -- string(APPEND MPI_LINK_FLAGS_WORK " ${CMAKE_LIBRARY_PATH_FLAG}${_MPI_LINK_DIRECTORY_ACTUAL}") -- else() -- set(MPI_LINK_FLAGS_WORK "${CMAKE_LIBRARY_PATH_FLAG}${_MPI_LINK_DIRECTORY_ACTUAL}") -- endif() -- endforeach() -+ if(NOT WIN32) -+ foreach(_MPI_LINK_DIRECTORY IN LISTS MPI_LINK_DIRECTORIES_LEFTOVER) -+ file(TO_NATIVE_PATH "${_MPI_LINK_DIRECTORY}" _MPI_LINK_DIRECTORY_ACTUAL) -+ string(FIND "${_MPI_LINK_DIRECTORY_ACTUAL}" " " _MPI_LINK_DIRECTORY_CONTAINS_SPACE) -+ if(NOT _MPI_LINK_DIRECTORY_CONTAINS_SPACE EQUAL -1) -+ set(_MPI_LINK_DIRECTORY_ACTUAL "\"${_MPI_LINK_DIRECTORY_ACTUAL}\"") -+ endif() -+ if(MPI_LINK_FLAGS_WORK) -+ string(APPEND MPI_LINK_FLAGS_WORK " ${CMAKE_LIBRARY_PATH_FLAG}${_MPI_LINK_DIRECTORY_ACTUAL}") -+ else() -+ set(MPI_LINK_FLAGS_WORK "${CMAKE_LIBRARY_PATH_FLAG}${_MPI_LINK_DIRECTORY_ACTUAL}") -+ endif() -+ endforeach() -+ endif() - - # Deal with the libraries given with full path next - unset(MPI_DIRECT_LIB_NAMES_WORK) -@@ -1137,23 +1144,29 @@ macro(_MPI_create_imported_target LANG) - add_library(MPI::MPI_${LANG} INTERFACE IMPORTED) - endif() - -- set_property(TARGET MPI::MPI_${LANG} PROPERTY INTERFACE_COMPILE_OPTIONS "${MPI_${LANG}_COMPILE_OPTIONS}") -+ if(NOT CMAKE_VERSION VERSION_LESS 3.12) -+ # When this is consumed for compiling CUDA, use '-Xcompiler' to wrap '-pthread'. -+ string(REPLACE "-pthread" "$<$:SHELL:-Xcompiler >-pthread" -+ _MPI_${LANG}_COMPILE_OPTIONS "${MPI_${LANG}_COMPILE_OPTIONS}") -+ endif() -+ set_property(TARGET MPI::MPI_${LANG} PROPERTY INTERFACE_COMPILE_OPTIONS "${_MPI_${LANG}_COMPILE_OPTIONS}") -+ unset(_MPI_${LANG}_COMPILE_OPTIONS) -+ - set_property(TARGET MPI::MPI_${LANG} PROPERTY INTERFACE_COMPILE_DEFINITIONS "${MPI_${LANG}_COMPILE_DEFINITIONS}") - -- set_property(TARGET MPI::MPI_${LANG} PROPERTY INTERFACE_LINK_LIBRARIES "") - if(MPI_${LANG}_LINK_FLAGS) -- set_property(TARGET MPI::MPI_${LANG} APPEND PROPERTY INTERFACE_LINK_LIBRARIES "${MPI_${LANG}_LINK_FLAGS}") -+ set_property(TARGET MPI::MPI_${LANG} PROPERTY INTERFACE_LINK_OPTIONS "SHELL:${MPI_${LANG}_LINK_FLAGS}") - endif() - # If the compiler links MPI implicitly, no libraries will be found as they're contained within - # CMAKE__IMPLICIT_LINK_LIBRARIES already. - if(MPI_${LANG}_LIBRARIES) -- set_property(TARGET MPI::MPI_${LANG} APPEND PROPERTY INTERFACE_LINK_LIBRARIES "${MPI_${LANG}_LIBRARIES}") -+ set_property(TARGET MPI::MPI_${LANG} PROPERTY INTERFACE_LINK_LIBRARIES "${MPI_${LANG}_LIBRARIES}") - endif() - # Given the new design of FindMPI, INCLUDE_DIRS will always be located, even under implicit linking. - set_property(TARGET MPI::MPI_${LANG} PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${MPI_${LANG}_INCLUDE_DIRS}") - endmacro() - --function(_MPI_try_staged_settings LANG MPI_TEST_FILE_NAME MODE RUN_BINARY) -+function(_MPI_try_staged_settings LANG MPI_TEST_FILE_NAME MODE RUN_BINARY SUPPRESS_ERRORS) - set(WORK_DIR "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/FindMPI") - set(SRC_DIR "${CMAKE_CURRENT_LIST_DIR}/FindMPI") - set(BIN_FILE "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/FindMPI/${MPI_TEST_FILE_NAME}_${LANG}.bin") -@@ -1182,18 +1195,29 @@ function(_MPI_try_staged_settings LANG MPI_TEST_FILE_NAME MODE RUN_BINARY) - "${CMAKE_BINARY_DIR}" SOURCES "${MPI_TEST_SOURCE_FILE}" - COMPILE_DEFINITIONS ${MPI_TEST_COMPILE_DEFINITIONS} - LINK_LIBRARIES MPI::MPI_${LANG} -- RUN_OUTPUT_VARIABLE MPI_RUN_OUTPUT_${LANG}_${MPI_TEST_FILE_NAME}_${MODE}) -+ RUN_OUTPUT_VARIABLE MPI_RUN_OUTPUT_${LANG}_${MPI_TEST_FILE_NAME}_${MODE} -+ COMPILE_OUTPUT_VARIABLE _MPI_TRY_${MPI_TEST_FILE_NAME}_${MODE}_OUTPUT) - set(MPI_RUN_OUTPUT_${LANG}_${MPI_TEST_FILE_NAME}_${MODE} "${MPI_RUN_OUTPUT_${LANG}_${MPI_TEST_FILE_NAME}_${MODE}}" PARENT_SCOPE) - else() - try_compile(MPI_RESULT_${LANG}_${MPI_TEST_FILE_NAME}_${MODE} - "${CMAKE_BINARY_DIR}" SOURCES "${MPI_TEST_SOURCE_FILE}" - COMPILE_DEFINITIONS ${MPI_TEST_COMPILE_DEFINITIONS} - LINK_LIBRARIES MPI::MPI_${LANG} -- COPY_FILE "${BIN_FILE}") -+ COPY_FILE "${BIN_FILE}" -+ OUTPUT_VARIABLE _MPI_TRY_${MPI_TEST_FILE_NAME}_${MODE}_OUTPUT) -+ endif() -+ if(NOT SUPPRESS_ERRORS) -+ if(NOT MPI_RESULT_${LANG}_${MPI_TEST_FILE_NAME}_${MODE}) -+ file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log -+ "The MPI test ${MPI_TEST_FILE_NAME} for ${LANG} in mode ${MODE} failed to compile with the following output:\n${_MPI_TRY_${MPI_TEST_FILE_NAME}_${MODE}_OUTPUT}\n\n") -+ elseif(DEFINED MPI_RUN_RESULT_${LANG}_${MPI_TEST_FILE_NAME}_${MODE} AND MPI_RUN_RESULT_${LANG}_${MPI_TEST_FILE_NAME}_${MODE}) -+ file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log -+ "The MPI test ${MPI_TEST_FILE_NAME} for ${LANG} in mode ${MODE} failed to run with the following output:\n${MPI_RUN_OUTPUT_${LANG}_${MPI_TEST_FILE_NAME}_${MODE}}\n\n") -+ endif() - endif() - endfunction() - --macro(_MPI_check_lang_works LANG) -+macro(_MPI_check_lang_works LANG SUPPRESS_ERRORS) - # For Fortran we may have by the MPI-3 standard an implementation that provides: - # - the mpi_f08 module - # - *both*, the mpi module and 'mpif.h' -@@ -1201,9 +1225,9 @@ macro(_MPI_check_lang_works LANG) - if( NOT MPI_${LANG}_WORKS ) - if("${LANG}" STREQUAL "Fortran") - set(MPI_Fortran_INTEGER_LINE "(kind=MPI_INTEGER_KIND)") -- _MPI_try_staged_settings(${LANG} test_mpi F77_HEADER FALSE) -- _MPI_try_staged_settings(${LANG} test_mpi F90_MODULE FALSE) -- _MPI_try_staged_settings(${LANG} test_mpi F08_MODULE FALSE) -+ _MPI_try_staged_settings(${LANG} test_mpi F77_HEADER FALSE ${SUPPRESS_ERRORS}) -+ _MPI_try_staged_settings(${LANG} test_mpi F90_MODULE FALSE ${SUPPRESS_ERRORS}) -+ _MPI_try_staged_settings(${LANG} test_mpi F08_MODULE FALSE ${SUPPRESS_ERRORS}) - - set(MPI_${LANG}_WORKS FALSE) - -@@ -1219,14 +1243,14 @@ macro(_MPI_check_lang_works LANG) - # However, MPI-1 also did not define the Fortran 90 and 08 modules, so we only try the F77 header. - unset(MPI_Fortran_INTEGER_LINE) - if(NOT MPI_${LANG}_WORKS) -- _MPI_try_staged_settings(${LANG} test_mpi F77_HEADER_NOKIND FALSE) -+ _MPI_try_staged_settings(${LANG} test_mpi F77_HEADER_NOKIND FALSE ${SUPPRESS_ERRORS}) - if(MPI_RESULT_${LANG}_test_mpi_F77_HEADER_NOKIND) - set(MPI_${LANG}_WORKS TRUE) - set(MPI_${LANG}_HAVE_F77_HEADER TRUE) - endif() - endif() - else() -- _MPI_try_staged_settings(${LANG} test_mpi normal FALSE) -+ _MPI_try_staged_settings(${LANG} test_mpi normal FALSE ${SUPPRESS_ERRORS}) - # If 'test_mpi' built correctly, we've found valid MPI settings. There might not be MPI-2 C++ support, but there can't - # be MPI-2 C++ support without the C bindings being present, so checking for them is sufficient. - set(MPI_${LANG}_WORKS "${MPI_RESULT_${LANG}_test_mpi_normal}") -@@ -1388,7 +1412,7 @@ foreach(LANG IN ITEMS C CXX Fortran) - # Should the imported targets be empty, we effectively try whether the compiler supports MPI on its own, which is the case on e.g. - # Cray PrgEnv. - _MPI_create_imported_target(${LANG}) -- _MPI_check_lang_works(${LANG}) -+ _MPI_check_lang_works(${LANG} TRUE) - - # If the compiler can build MPI code on its own, it functions as an MPI compiler and we'll set the variable to point to it. - if(MPI_${LANG}_WORKS) -@@ -1440,7 +1464,7 @@ foreach(LANG IN ITEMS C CXX Fortran) - # If we haven't made the implicit compiler test yet, perform it now. - if(NOT MPI_${LANG}_TRIED_IMPLICIT) - _MPI_create_imported_target(${LANG}) -- _MPI_check_lang_works(${LANG}) -+ _MPI_check_lang_works(${LANG} TRUE) - endif() - - # Should the MPI compiler not work implicitly for MPI, still interrogate it. -@@ -1486,7 +1510,7 @@ foreach(LANG IN ITEMS C CXX Fortran) - _MPI_create_imported_target(${LANG}) - - if(NOT MPI_${LANG}_WORKS) -- _MPI_check_lang_works(${LANG}) -+ _MPI_check_lang_works(${LANG} FALSE) - endif() - - # Next, we'll initialize the MPI variables that have not been previously set. -@@ -1505,7 +1529,7 @@ foreach(LANG IN ITEMS C CXX Fortran) - if(MPI_${LANG}_WORKS) - if("${LANG}" STREQUAL "CXX" AND NOT DEFINED MPI_MPICXX_FOUND) - if(NOT MPI_CXX_SKIP_MPICXX AND NOT MPI_CXX_VALIDATE_SKIP_MPICXX) -- _MPI_try_staged_settings(${LANG} test_mpi MPICXX FALSE) -+ _MPI_try_staged_settings(${LANG} test_mpi MPICXX FALSE FALSE) - if(MPI_RESULT_${LANG}_test_mpi_MPICXX) - set(MPI_MPICXX_FOUND TRUE) - else() -@@ -1540,7 +1564,7 @@ foreach(LANG IN ITEMS C CXX Fortran) - # and MPI_SUBVERSION are provided. These defines did not exist in MPI 1.0 and 1.1 and therefore might not - # exist. For C/C++, test_mpi.c will handle the MPI_VERSION extraction, but for Fortran, we need mpiver.f90. - if(NOT DEFINED MPI_${LANG}_VERSION) -- _MPI_try_staged_settings(${LANG} mpiver ${MPI_${LANG}_HIGHEST_METHOD} FALSE) -+ _MPI_try_staged_settings(${LANG} mpiver ${MPI_${LANG}_HIGHEST_METHOD} FALSE FALSE) - if(MPI_RESULT_${LANG}_mpiver_${MPI_${LANG}_HIGHEST_METHOD}) - file(STRINGS ${MPI_BIN_FOLDER}/mpiver_${LANG}.bin _MPI_VERSION_STRING LIMIT_COUNT 1 REGEX "INFO:MPI-VER") - if("${_MPI_VERSION_STRING}" MATCHES ".*INFO:MPI-VER\\[([0-9]+)\\.([0-9]+)\\].*") -@@ -1559,7 +1583,7 @@ foreach(LANG IN ITEMS C CXX Fortran) - if(MPI_${LANG}_HAVE_${mpimethod}) - set(MPI_${LANG}_${mpimethod}_SUBARRAYS FALSE) - set(MPI_${LANG}_${mpimethod}_ASYNCPROT FALSE) -- _MPI_try_staged_settings(${LANG} fortranparam_mpi ${mpimethod} TRUE) -+ _MPI_try_staged_settings(${LANG} fortranparam_mpi ${mpimethod} TRUE FALSE) - if(MPI_RESULT_${LANG}_fortranparam_mpi_${mpimethod} AND - NOT "${MPI_RUN_RESULT_${LANG}_fortranparam_mpi_${mpimethod}}" STREQUAL "FAILED_TO_RUN") - if("${MPI_RUN_OUTPUT_${LANG}_fortranparam_mpi_${mpimethod}}" MATCHES -@@ -1600,7 +1624,7 @@ foreach(LANG IN ITEMS C CXX Fortran) - # It's also worth noting that the installed version string can depend on the language, or on the system the binary - # runs on if MPI is not statically linked. - if(MPI_DETERMINE_LIBRARY_VERSION AND NOT MPI_${LANG}_LIBRARY_VERSION_STRING) -- _MPI_try_staged_settings(${LANG} libver_mpi ${MPI_${LANG}_HIGHEST_METHOD} TRUE) -+ _MPI_try_staged_settings(${LANG} libver_mpi ${MPI_${LANG}_HIGHEST_METHOD} TRUE FALSE) - if(MPI_RESULT_${LANG}_libver_mpi_${MPI_${LANG}_HIGHEST_METHOD} AND - "${MPI_RUN_RESULT_${LANG}_libver_mpi_${MPI_${LANG}_HIGHEST_METHOD}}" EQUAL "0") - string(STRIP "${MPI_RUN_OUTPUT_${LANG}_libver_mpi_${MPI_${LANG}_HIGHEST_METHOD}}" -@@ -1686,7 +1710,10 @@ foreach(LANG IN ITEMS C CXX Fortran) - set(MPI_${LANG}_INCLUDE_PATH "${MPI_${LANG}_INCLUDE_DIRS}") - unset(MPI_${LANG}_COMPILE_FLAGS) - if(MPI_${LANG}_COMPILE_OPTIONS) -- set(MPI_${LANG}_COMPILE_FLAGS "${MPI_${LANG}_COMPILE_OPTIONS}") -+ set(MPI_${LANG}_COMPILE_OPTIONS) -+ foreach(flag IN LISTS MPI_${LANG}_COMPILE_FLAGS) -+ string(APPEND MPI_${LANG}_COMPILE_OPTIONS " ${flag}") -+ endforeach() - endif() - if(MPI_${LANG}_COMPILE_DEFINITIONS) - foreach(_MPI_DEF IN LISTS MPI_${LANG}_COMPILE_DEFINITIONS) -diff --git a/cmake/upstream/FindMPI/libver_mpi.c b/cmake/upstream/FindMPI/libver_mpi.c -index be9d19d..d89328a 100644 ---- a/cmake/upstream/FindMPI/libver_mpi.c -+++ b/cmake/upstream/FindMPI/libver_mpi.c -@@ -1,9 +1,9 @@ - #include - - #ifdef __cplusplus --#include -+# include - #else --#include -+# include - #endif - - int main(int argc, char* argv[]) -@@ -16,4 +16,5 @@ int main(int argc, char* argv[]) - #else - puts(mpilibver_str); - #endif -+ return 0; - } -diff --git a/cmake/upstream/FindMPI/test_mpi.c b/cmake/upstream/FindMPI/test_mpi.c -index b8a308a..7c96d54 100644 ---- a/cmake/upstream/FindMPI/test_mpi.c -+++ b/cmake/upstream/FindMPI/test_mpi.c -@@ -1,9 +1,9 @@ - #include - - #ifdef __cplusplus --#include -+# include - #else --#include -+# include - #endif - - #if defined(MPI_VERSION) && defined(MPI_SUBVERSION) -@@ -21,11 +21,11 @@ const char mpiver_str[] = { 'I', 'N', - int main(int argc, char* argv[]) - { - #if defined(MPI_VERSION) && defined(MPI_SUBVERSION) --#ifdef __cplusplus -+# ifdef __cplusplus - std::puts(mpiver_str); --#else -+# else - puts(mpiver_str); --#endif -+# endif - #endif - #ifdef TEST_MPI_MPICXX - MPI::MPI_Init(&argc, &argv); -@@ -34,4 +34,5 @@ int main(int argc, char* argv[]) - MPI_Init(&argc, &argv); - MPI_Finalize(); - #endif -+ return 0; - } -diff --git a/testing/adios2/engine/staging-common/TestCommonReadShared.cpp b/testing/adios2/engine/staging-common/TestCommonReadShared.cpp -index 72199b5..e2a73f3 100644 ---- a/testing/adios2/engine/staging-common/TestCommonReadShared.cpp -+++ b/testing/adios2/engine/staging-common/TestCommonReadShared.cpp -@@ -79,7 +79,6 @@ TEST_F(CommonReadTest, ADIOS2CommonRead1D8) - { - size_t writerSize; - -- - auto var1 = io1.InquireVariable(varname1); - auto var2 = io2.InquireVariable(varname2); - diff --git a/repo/packages/adios2/package.py b/repo/packages/adios2/package.py deleted file mode 100644 index 902dc961..00000000 --- a/repo/packages/adios2/package.py +++ /dev/null @@ -1,255 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# ======================================================================= -# PAWSEY ADDITIONS -# ======================================================================= -# adds the 2.9.0 version -import os - -from spack.package import * - - -class Adios2(CMakePackage, CudaPackage): - """The Adaptable Input Output System version 2, - developed in the Exascale Computing Program""" - - homepage = "https://csmd.ornl.gov/software/adios2" - url = "https://github.com/ornladios/ADIOS2/archive/v2.8.0.tar.gz" - git = "https://github.com/ornladios/ADIOS2.git" - - maintainers = ["ax3l", "chuckatkins", "vicentebolea", "williamfgc"] - - tags = ["e4s"] - - version("master", branch="master") - version("2.9.0", sha256="69f98ef58c818bb5410133e1891ac192653b0ec96eb9468590140f2552b6e5d1") - version("2.8.3", sha256="4906ab1899721c41dd918dddb039ba2848a1fb0cf84f3a563a1179b9d6ee0d9f") - version("2.8.2", sha256="9909f6409dc44b2c28c1fda0042dab4b711f25ec3277ef0cb6ffc40f5483910d") - version("2.8.1", sha256="3f515b442bbd52e3189866b121613fe3b59edb8845692ea86fad83d1eba35d93") - version("2.8.0", sha256="5af3d950e616989133955c2430bd09bcf6bad3a04cf62317b401eaf6e7c2d479") - version("2.7.1", sha256="c8e237fd51f49d8a62a0660db12b72ea5067512aa7970f3fcf80b70e3f87ca3e") - version("2.7.0", sha256="4b5df1a1f92d7ff380416dec7511cfcfe3dc44da27e486ed63c3e6cffb173924") - version("2.6.0", sha256="45b41889065f8b840725928db092848b8a8b8d1bfae1b92e72f8868d1c76216c") - version("2.5.0", sha256="7c8ff3bf5441dd662806df9650c56a669359cb0185ea232ecb3578de7b065329") - version("2.4.0", sha256="50ecea04b1e41c88835b4b3fd4e7bf0a0a2a3129855c9cc4ba6cf6a1575106e2") - version("2.3.1", sha256="3bf81ccc20a7f2715935349336a76ba4c8402355e1dc3848fcd6f4c3c5931893") - - # General build options - variant( - "build_type", - default="Release", - description="CMake build type", - values=("Debug", "Release", "RelWithDebInfo", "MinSizeRel"), - ) - - # There's not really any consistency about how static and shared libs are - # implemented across spack. What we're trying to support is specifically three - # library build types: - # shared (which is implicitly w/ pic) - # Implemented by +shared +pic - # static w/o pic - # Implemented by ~shared ~pic - # static w/ pic - # Implemented by ~shared +pic - # shared w/o pic is not a valid configuration because shared libraries are Position - # Independent # Code by design. We're not inherently tied to this approach and can - # change how we're supporting differnt library types in the package at anytime if - # spack decides on a standardized way of doing it across packages - variant("shared", default=True, when="+pic", description="Build shared libraries") - variant("pic", default=True, description="Build pic-enabled static libraries") - - # Features - variant("mpi", default=True, description="Enable MPI") - - # Compression libraries - variant( - "libpressio", default=False, when="@2.8:", description="Enable LibPressio for compression" - ) - variant("blosc", default=True, when="@2.4:", description="Enable Blosc compression") - variant("bzip2", default=True, when="@2.4:", description="Enable BZip2 compression") - variant("zfp", default=True, description="Enable ZFP compression") - variant("png", default=True, when="@2.4:", description="Enable PNG compression") - variant("sz", default=True, description="Enable SZ compression") - - # Rransport engines - variant("sst", default=True, description="Enable the SST staging engine") - variant( - "dataman", - default=False, - when="+shared", - description="Enable the DataMan engine for WAN transports", - ) - variant("dataspaces", default=False, when="@2.5:", description="Enable support for DATASPACES") - variant("ssc", default=True, description="Enable the SSC staging engine") - variant("hdf5", default=False, description="Enable the HDF5 engine") - - # Optional language bindings, C++11 and C always provided - variant("cuda", default=False, when="@2.8:", description="Enable CUDA support") - variant("python", default=False, description="Enable the Python bindings") - variant("fortran", default=True, description="Enable the Fortran bindings") - - # Requires mature C++11 implementations - conflicts("%gcc@:4.7") - conflicts("%intel@:15") - conflicts("%pgi@:14") - - depends_on("cmake@3.12.0:", type="build") - depends_on("pkgconfig", type="build") - - depends_on("libffi", when="+sst") # optional in DILL - depends_on("libfabric@1.6.0:", when="+sst") # optional in EVPath and SST - # depends_on('bison', when='+sst') # optional in FFS, broken package - # depends_on('flex', when='+sst') # optional in FFS, depends on BISON - - depends_on("mpi", when="+mpi") - depends_on("libzmq", when="+dataman") - depends_on("dataspaces@1.8.0:", when="+dataspaces") - - depends_on("hdf5~mpi", when="+hdf5~mpi") - depends_on("hdf5+mpi", when="+hdf5+mpi") - - depends_on("libpressio", when="+libpressio") - depends_on("c-blosc", when="+blosc") - depends_on("bzip2", when="+bzip2") - depends_on("libpng@1.6:", when="+png") - depends_on("zfp@0.5.1:0.5", when="+zfp") - depends_on("sz@2.0.2.0:", when="+sz") - - extends("python", when="+python") - depends_on("python@2.7:2.8,3.5:", when="@:2.4.0 +python", type=("build", "run")) - depends_on("python@2.7:2.8,3.5:", when="@:2.4.0", type="test") - depends_on("python@3.5:", when="@2.5.0: +python", type=("build", "run")) - depends_on("python@3.5:", when="@2.5.0:", type="test") - depends_on("py-numpy@1.6.1:", when="+python", type=("build", "run")) - depends_on("py-mpi4py@2.0.0:", when="+mpi +python", type=("build", "run")) - - # Fix findmpi when called by dependees - # See https://github.com/ornladios/ADIOS2/pull/1632 - patch("cmake-update-findmpi.patch", when="@2.4.0") - - # Fix the signature of the builtin clear_cache function in the - # third-party dill library. - # See https://github.com/ornladios/ADIOS2/pull/1899 - patch("2.5-fix-clear_cache.patch", when="@2.5.0") - - # Fix an unnecessary python dependency when testing is disabled - # See https://github.com/ornladios/ADIOS2/pull/2596 - patch("2.7-fix-python-test-deps.patch", when="@2.5.0:2.7.0") - - # Fix unresolved symbols when built with gcc10. - # See https://github.com/ornladios/ADIOS2/pull/2714 - patch("2.6-fix-gcc10-symbols.patch", when="@2.6.0") - - # Add missing include - # https://github.com/ornladios/adios2/pull/2710 - patch( - "https://github.com/ornladios/adios2/pull/2710.patch?full_index=1", - when="@:2.7.1", - sha256="8221073d1b2f8944395a88a5d60a15c7370646b62f5fc6309867bbb6a8c2096c", - ) - - @when("%fj") - def patch(self): - """add fujitsu mpi commands #16864""" - f = join_path("cmake", "upstream", "FindMPI.cmake") - filter_file("mpcc_r)", "mpcc_r mpifcc)", f, string=True) - filter_file("mpc++_r)", "mpcc_r mpiFCC)", f, string=True) - filter_file("mpf77_r", "mpf77_r mpifrt", f, string=True) - - def setup_build_environment(self, env): - # https://github.com/ornladios/ADIOS2/issues/2228 - if self.spec.satisfies("%gcc@10: +fortran"): - env.set("FFLAGS", "-fallow-argument-mismatch") - elif self.spec.satisfies("%fj +fortran"): - env.set("FFLAGS", "-Ccpp") - - def cmake_args(self): - spec = self.spec - from_variant = self.define_from_variant - - args = [ - from_variant("CMAKE_POSITION_INDEPENDENT_CODE", "pic"), - from_variant("BUILD_SHARED_LIBS", "shared"), - from_variant("ADIOS2_USE_Blosc", "blosc"), - from_variant("ADIOS2_USE_BZip2", "bzip2"), - from_variant("ADIOS2_USE_DataMan", "dataman"), - from_variant("ADIOS2_USE_DataSpaces", "dataspaces"), - from_variant("ADIOS2_USE_Fortran", "fortran"), - from_variant("ADIOS2_USE_HDF5", "hdf5"), - from_variant("ADIOS2_USE_MPI", "mpi"), - from_variant("ADIOS2_USE_PNG", "png"), - from_variant("ADIOS2_USE_Python", "python"), - from_variant("ADIOS2_USE_SSC", "ssc"), - from_variant("ADIOS2_USE_SST", "sst"), - from_variant("ADIOS2_USE_SZ", "sz"), - from_variant("ADIOS2_USE_ZFP", "zfp"), - from_variant("ADIOS2_USE_CUDA", "cuda"), - from_variant("ADIOS2_USE_LIBPRESSIO", "libpressio"), - self.define("BUILD_TESTING", self.run_tests), - self.define("ADIOS2_BUILD_EXAMPLES", False), - self.define("ADIOS2_USE_Endian_Reverse", True), - self.define("ADIOS2_USE_IME", False), - self.define("ADIOS2_USE_MGARD", False), - ] - - if "+sst" in spec: - args.extend( - [ - # Broken dependency package - "-DCMAKE_DISABLE_FIND_PACKAGE_BISON=TRUE", - # Depends on ^ - "-DCMAKE_DISABLE_FIND_PACKAGE_FLEX=TRUE", - # Not yet packaged - "-DCMAKE_DISABLE_FIND_PACKAGE_CrayDRC=TRUE", - "-DCMAKE_DISABLE_FIND_PACKAGE_NVSTREAM=TRUE", - ] - ) - - if "%fj" in spec: - args.extend(["-DCMAKE_Fortran_SUBMODULE_EXT=.smod", "-DCMAKE_Fortran_SUBMODULE_SEP=."]) - - if "+python" in spec or self.run_tests: - args.append("-DPYTHON_EXECUTABLE:FILEPATH=%s" % spec["python"].command.path) - - return args - - @property - def libs(self): - spec = self.spec - libs_to_seek = set() - - if "@2.6:" in spec: - libs_to_seek.add("libadios2_core") - libs_to_seek.add("libadios2_c") - libs_to_seek.add("libadios2_cxx11") - if "+fortran" in spec: - libs_to_seek.add("libadios2_fortran") - - if "+mpi" in spec: - libs_to_seek.add("libadios2_core_mpi") - libs_to_seek.add("libadios2_c_mpi") - libs_to_seek.add("libadios2_cxx11_mpi") - if "+fortran" in spec: - libs_to_seek.add("libadios2_fortran_mpi") - - if "@2.7: +shared+hdf5" in spec and "@1.12:" in spec["hdf5"]: - libs_to_seek.add("libadios2_h5vol") - - else: - libs_to_seek.add("libadios2") - if "+fortran" in spec: - libs_to_seek.add("libadios2_fortran") - - return find_libraries( - list(libs_to_seek), root=self.spec.prefix, shared=("+shared" in spec), recursive=True - ) - - def setup_run_environment(self, env): - try: - all_libs = self.libs - idx = all_libs.basenames.index("libadios2_h5vol.so") - env.prepend_path("HDF5_PLUGIN_PATH", os.path.dirname(all_libs[idx])) - except ValueError: - pass diff --git a/repo/packages/awscli/package.py b/repo/packages/awscli/package.py deleted file mode 100644 index 908651b2..00000000 --- a/repo/packages/awscli/package.py +++ /dev/null @@ -1,38 +0,0 @@ -#updated versions of py-botocore, py-docutils and py-pyyaml: -#- depends_on("py-botocore@1.13.44", when="@1.16.308", type=("build", "run")) -#+ depends_on("py-botocore@1.21.12", when="@1.16.308", type=("build", "run")) -#- depends_on("py-docutils@0.10:0.15", type=("build", "run")) -#+ depends_on("py-docutils@0.10:0.19", type=("build", "run")) -#- depends_on("py-pyyaml@3.10:5.2", when="^python@3.4:", type=("build", "run")) -#+ depends_on("py-pyyaml@3.10:6.0", when="^python@3.4:", type=("build", "run")) -############################################################################## -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# There is a newer recipe in spack 0.20, remove this when upgrading. -from spack.package import * - - -class Awscli(PythonPackage): - """This package provides a unified command line interface to - Amazon Web Services""" - - pypi = "awscli/awscli-1.16.308.tar.gz" - - version("1.16.308", sha256="3632fb1db2538128509a7b5e89f2a2c4ea3426bec139944247bddc4d79bf7603") - version("1.16.179", sha256="6a87114d1325358d000abe22b2103baae7b91f053ff245b9fde33cb0affb5e4f") - - depends_on("py-setuptools", type="build") - depends_on("py-botocore@1.21.12", when="@1.16.308", type=("build", "run")) - depends_on("py-botocore@1.12.169", when="@1.16.179", type=("build", "run")) - depends_on("py-docutils@0.10:0.19", type=("build", "run")) - depends_on("py-rsa@3.1.2:3.5.0", type=("build", "run")) - depends_on("py-s3transfer@0.2.0:0.2", type=("build", "run")) - depends_on("py-argparse@1.1:", when="^python@:2.6,3.0:3.1", type=("build", "run")) - depends_on("py-pyyaml@3.10:3.13", when="^python@:2.6,3.0:3.3", type=("build", "run")) - depends_on("py-pyyaml@3.10:6.0", when="^python@3.4:", type=("build", "run")) - depends_on("py-colorama@0.2.5:0.3.9", when="^python@:2.6,3.0:3.3", type=("build", "run")) - depends_on("py-colorama@0.2.5:0.4.1", when="^python@3.4:", type=("build", "run")) - depends_on("py-nose", type="test") - depends_on("py-mock@1.3.0:", type="test") From a4aaf334f48183b2567ed9841948c48c7f962038 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 09:50:51 +0800 Subject: [PATCH 02/21] Contributed beast2 to Spack. --- repo/packages/beast2/package.py | 54 --------------------------------- 1 file changed, 54 deletions(-) delete mode 100644 repo/packages/beast2/package.py diff --git a/repo/packages/beast2/package.py b/repo/packages/beast2/package.py deleted file mode 100644 index 6aa8762e..00000000 --- a/repo/packages/beast2/package.py +++ /dev/null @@ -1,54 +0,0 @@ -# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# ======================================================================= -# PAWSEY ADDITIONS -# ======================================================================= -# Differences for the 'beast2' package -# 6c6 -# < from spack.package import * -# --- -# > from spack import * -# 20d19 -# < version('2.6.7', sha256='05dcc619c2e10163f2c1089ec66149f6e53ec5a0583cd2cb8ffdccbbdb1d8183') -# 26,27d24 -# < variant('beagle', default=True, description='Build with libbeagle support') -# < -# 29d25 -# < depends_on('libbeagle', type=('build', 'link', 'run'), when="+beagle") -# CONTRIBUTE - beagle dependency -from spack.package import * - - -class Beast2(Package): - """BEAST is a cross-platform program for Bayesian inference using MCMC - of molecular sequences. It is entirely orientated towards rooted, - time-measured phylogenies inferred using strict or relaxed molecular - clock models. It can be used as a method of reconstructing phylogenies - but is also a framework for testing evolutionary hypotheses without - conditioning on a single tree topology.""" - - homepage = "http://beast2.org/" - url = "https://github.com/CompEvol/beast2/releases/download/v2.6.4/BEAST.v2.6.4.Linux.tgz" - - version('2.6.7', sha256='05dcc619c2e10163f2c1089ec66149f6e53ec5a0583cd2cb8ffdccbbdb1d8183') - version('2.6.4', sha256='4f80e2920eb9d87f3e9f64433119774dc67aca390fbd13dd480f852e3f8701a4') - version('2.6.3', sha256='8899277b0d7124ab04dc512444d45f0f1a13505f3ce641e1f117098be3e2e20d') - version('2.5.2', sha256='2feb2281b4f7cf8f7de1a62de50f52a8678ed0767fc72f2322e77dde9b8cd45f') - version('2.4.6', sha256='84029c5680cc22f95bef644824130090f5f12d3d7f48d45cb4efc8e1d6b75e93') - - variant('beagle', default=True, description='Build with libbeagle support') - - depends_on('java') - depends_on('libbeagle', type=('build', 'link', 'run'), when="+beagle") - - def setup_run_environment(self, env): - env.set('BEAST', self.prefix) - - def install(self, spec, prefix): - install_tree('bin', prefix.bin) - install_tree('examples', join_path(self.prefix, 'examples')) - install_tree('images', join_path(self.prefix, 'images')) - install_tree('lib', prefix.lib) - install_tree('templates', join_path(self.prefix, 'templates')) From 7809bee6812312bced248d012b7461ea4e914bea Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 10:23:04 +0800 Subject: [PATCH 03/21] Contributed caliper and casacore. --- repo/packages/caliper/for_aarch64.patch | 11 -- repo/packages/caliper/package.py | 192 ------------------------ repo/packages/casacore/package.py | 108 ------------- 3 files changed, 311 deletions(-) delete mode 100644 repo/packages/caliper/for_aarch64.patch delete mode 100644 repo/packages/caliper/package.py delete mode 100644 repo/packages/casacore/package.py diff --git a/repo/packages/caliper/for_aarch64.patch b/repo/packages/caliper/for_aarch64.patch deleted file mode 100644 index d3fed9a0..00000000 --- a/repo/packages/caliper/for_aarch64.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- spack-src/src/services/callpath/Callpath.cpp.bak 2020-10-28 14:38:19.668122844 +0900 -+++ spack-src/src/services/callpath/Callpath.cpp 2020-10-28 15:03:12.258061188 +0900 -@@ -63,7 +63,7 @@ - unw_context_t unw_ctx; - unw_cursor_t unw_cursor; - -- unw_getcontext(&unw_ctx); -+ unw_getcontext(unw_ctx); - - if (unw_init_local(&unw_cursor, &unw_ctx) < 0) { - Log(0).stream() << "callpath: unable to init libunwind cursor" << endl; diff --git a/repo/packages/caliper/package.py b/repo/packages/caliper/package.py deleted file mode 100644 index 7c63be31..00000000 --- a/repo/packages/caliper/package.py +++ /dev/null @@ -1,192 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# Pull ROCm and contribute KOKKOS -import os -import sys - -from llnl.util import tty - -from spack.package import * - - -class Caliper(CMakePackage, CudaPackage): - """Caliper is a program instrumentation and performance measurement - framework. It is designed as a performance analysis toolbox in a - library, allowing one to bake performance analysis capabilities - directly into applications and activate them at runtime. - """ - - homepage = "https://github.com/LLNL/Caliper" - git = "https://github.com/LLNL/Caliper.git" - url = "https://github.com/LLNL/Caliper/archive/v2.7.0.tar.gz" - tags = ['e4s', 'radiuss'] - - maintainers = ["daboehme"] - - test_requires_compiler = True - - version('master', branch='master') - version('2.7.0', sha256='b3bf290ec2692284c6b4f54cc0c507b5700c536571d3e1a66e56626618024b2b') - version('2.6.0', sha256='6efcd3e4845cc9a6169e0d934840766b12182c6d09aa3ceca4ae776e23b6360f') - version('2.5.0', sha256='d553e60697d61c53de369b9ca464eb30710bda90fba9671201543b64eeac943c') - version('2.4.0', tag='v2.4.0') - version('2.3.0', tag='v2.3.0') - version('2.2.0', tag='v2.2.0') - version('2.1.1', tag='v2.1.1') - version('2.0.1', tag='v2.0.1') - version('1.9.1', tag='v1.9.1') - version('1.9.0', tag='v1.9.0') - version('1.8.0', tag='v1.8.0') - version('1.7.0', tag='v1.7.0') - - is_linux = sys.platform.startswith('linux') - variant('shared', default=True, - description='Build shared libraries') - variant('adiak', default=True, - description='Enable Adiak support') - variant('mpi', default=True, - description='Enable MPI wrappers') - # libunwind has some issues on Mac - variant('libunwind', default=sys.platform != 'darwin', - description='Enable stack unwind support') - variant('libdw', default=is_linux, - description='Enable DWARF symbol lookup') - # pthread_self() signature is incompatible with PAPI_thread_init() on Mac - variant('papi', default=sys.platform != 'darwin', - description='Enable PAPI service') - variant('libpfm', default=False, - description='Enable libpfm (perf_events) service') - # Gotcha is Linux-only - variant('gotcha', default=is_linux, - description='Enable GOTCHA support') - variant('sampler', default=is_linux, - description='Enable sampling support on Linux') - variant('sosflow', default=False, - description='Enable SOSflow support') - variant('fortran', default=False, - description='Enable Fortran support') - variant('kokkos', default=True, - description='Enable Kokkos profiling support') - - depends_on('adiak@0.1:0', when='@2.2: +adiak') - - depends_on('papi@5.3:5', when='@:2.2 +papi') - depends_on('papi@5.3:6', when='@2.3: +papi') - - depends_on('libpfm4@4.8:4', when='+libpfm') - - depends_on('mpi', when='+mpi') - depends_on('unwind@1.2:1', when='+libunwind') - depends_on('elfutils', when='+libdw') - - depends_on('sosflow@spack', when='@1.0:1+sosflow') - - depends_on('cmake', type='build') - depends_on('python', type='build') - - # sosflow support not yet in 2.0 - conflicts('+sosflow', '@2.0.0:2.5') - conflicts('+adiak', '@:2.1') - conflicts('+libdw', '@:2.4') - - patch('for_aarch64.patch', when='target=aarch64:') - - def cmake_args(self): - spec = self.spec - - args = [ - ('-DPYTHON_EXECUTABLE=%s' % - spec['python'].command.path), - '-DBUILD_TESTING=Off', - '-DBUILD_DOCS=Off', - '-DBUILD_SHARED_LIBS=%s' % ('On' if '+shared' in spec else 'Off'), - '-DWITH_ADIAK=%s' % ('On' if '+adiak' in spec else 'Off'), - '-DWITH_GOTCHA=%s' % ('On' if '+gotcha' in spec else 'Off'), - '-DWITH_PAPI=%s' % ('On' if '+papi' in spec else 'Off'), - '-DWITH_LIBDW=%s' % ('On' if '+libdw' in spec else 'Off'), - '-DWITH_LIBPFM=%s' % ('On' if '+libpfm' in spec else 'Off'), - '-DWITH_SOSFLOW=%s' % ('On' if '+sosflow' in spec else 'Off'), - '-DWITH_SAMPLER=%s' % ('On' if '+sampler' in spec else 'Off'), - '-DWITH_MPI=%s' % ('On' if '+mpi' in spec else 'Off'), - '-DWITH_FORTRAN=%s' % ('On' if '+fortran' in spec else 'Off'), - '-DWITH_KOKKOS=%s' % ('On' if '+kokkos' in spec else 'Off') - ] - - if '+papi' in spec: - args.append('-DPAPI_PREFIX=%s' % spec['papi'].prefix) - if '+libdw' in spec: - args.append('-DLIBDW_PREFIX=%s' % spec['elfutils'].prefix) - if '+libpfm' in spec: - args.append('-DLIBPFM_INSTALL=%s' % spec['libpfm4'].prefix) - if '+sosflow' in spec: - args.append('-DSOS_PREFIX=%s' % spec['sosflow'].prefix) - - # -DWITH_CALLPATH was renamed -DWITH_LIBUNWIND in 2.5 - callpath_flag = 'LIBUNWIND' if spec.satisfies('@2.5:') else 'CALLPATH' - if '+libunwind' in spec: - args.append('-DLIBUNWIND_PREFIX=%s' % spec['unwind'].prefix) - args.append('-DWITH_%s=On' % callpath_flag) - else: - args.append('-DWITH_%s=Off' % callpath_flag) - - if '+mpi' in spec: - args.append('-DMPI_C_COMPILER=%s' % spec['mpi'].mpicc) - args.append('-DMPI_CXX_COMPILER=%s' % spec['mpi'].mpicxx) - - if '+cuda' in spec: - args.append('-DCUDA_TOOLKIT_ROOT_DIR=%s' % spec['cuda'].prefix) - # technically only works with cuda 10.2+, otherwise cupti is in - # ${CUDA_TOOLKIT_ROOT_DIR}/extras/CUPTI - args.append('-DCUPTI_PREFIX=%s' % spec['cuda'].prefix) - args.append('-DWITH_NVTX=On') - args.append('-DWITH_CUPTI=On') - else: - args.append('-DWITH_NVTX=Off') - args.append('-DWITH_CUPTI=Off') - - return args - - @run_after('install') - def cache_test_sources(self): - """Copy the example source files after the package is installed to an - install test subdirectory for use during `spack test run`.""" - self.cache_extra_test_sources([join_path('examples', 'apps')]) - - def run_cxx_example_test(self): - """Run stand alone test: cxx_example""" - - test_dir = self.test_suite.current_test_cache_dir.examples.apps - exe = 'cxx-example' - source_file = 'cxx-example.cpp' - - if not os.path.isfile(join_path(test_dir, source_file)): - tty.warn('Skipping caliper test:' - '{0} does not exist'.format(source_file)) - return - - if os.path.exists(self.prefix.lib): - lib_dir = self.prefix.lib - else: - lib_dir = self.prefix.lib64 - - options = ['-L{0}'.format(lib_dir), - '-I{0}'.format(self.prefix.include), - '{0}'.format(join_path(test_dir, source_file)), - '-o', exe, '-std=c++11', '-lcaliper', '-lstdc++'] - - if not self.run_test(exe=os.environ['CXX'], - options=options, - purpose='test: compile {0} example'.format(exe), - work_dir=test_dir): - tty.warn('Skipping caliper test: failed to compile example') - return - - if not self.run_test(exe, - purpose='test: run {0} example'.format(exe), - work_dir=test_dir): - tty.warn('Skipping caliper test: failed to run example') - - def test(self): - self.run_cxx_example_test() diff --git a/repo/packages/casacore/package.py b/repo/packages/casacore/package.py deleted file mode 100644 index e5ed488e..00000000 --- a/repo/packages/casacore/package.py +++ /dev/null @@ -1,108 +0,0 @@ -# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# Contribute -# - Fix fftw dependency to set the fftw-api -# - Dependency on gsl when @3.5.0: -import os - -from spack.package import * - - -class Casacore(CMakePackage): - """A suite of c++ libraries for radio astronomy data processing.""" - - homepage = "https://github.com/casacore/casacore" - url = "https://github.com/casacore/casacore/archive/v2.4.1.tar.gz" - - maintainers = ['mpokorny'] - - version('3.5.0', sha256='63f1c8eff932b0fcbd38c598a5811e6e5397b72835b637d6f426105a183b3f91') - version('3.4.0', sha256='31f02ad2e26f29bab4a47a2a69e049d7bc511084a0b8263360e6157356f92ae1') - version('3.3.0', sha256='3a714644b908ef6e81489b792cc9b80f6d8267a275e15d38a42a6a5137d39d3d') - version('3.2.1', sha256='f87ce81d2b42ec5401cff8317baeeb9a3b408b716bb791ef252ad97af6e235ad') - version('3.2.0', sha256='ae5d3786cb6dfdd7ebc5eecc0c724ff02bbf6929720bc23be43a027978e79a5f') - version('3.1.2', sha256='ac94f4246412eb45d503f1019cabe2bb04e3861e1f3254b832d9b1164ea5f281') - version('3.1.1', sha256='85d2b17d856592fb206b17e0a344a29330650a4269c80b87f8abb3eaf3dadad4') - version('3.1.0', sha256='a6adf2d77ad0d6f32995b1e297fd88d31ded9c3e0bb8f28966d7b35a969f7897') - version('3.0.0', sha256='6f0e68fd77b5c96299f7583a03a53a90980ec347bff9dfb4c0abb0e2933e6bcb') - version('2.4.1', sha256='58eccc875053b2c6fe44fe53b6463030ef169597ec29926936f18d27b5087d63') - - depends_on('cmake@3.7.1:', type='build') - - variant('openmp', default=False, description='Build OpenMP support') - variant('shared', default=True, description='Build shared libraries') - variant('readline', default=True, description='Build readline support') - # see note below about the reason for disabling the "sofa" variant - # variant('sofa', default=False, description='Build SOFA support') - variant('adios2', default=False, description='Build ADIOS2 support') - variant('fftpack', default=False, description='Build FFTPack') - variant('hdf5', default=False, description='Build HDF5 support') - variant('python', default=False, description='Build python support') - - # Force dependency on readline in v3.2 and earlier. Although the - # presence of readline is tested in CMakeLists.txt, and casacore - # can be built without it, there's no way to control that - # dependency at build time; since many systems come with readline, - # it's better to explicitly depend on it here always. - depends_on('readline', when='@:3.2.0') - depends_on('readline', when='+readline') - depends_on('flex', type='build') - depends_on('bison', type='build') - depends_on('blas') - depends_on('lapack') - depends_on('cfitsio') - depends_on('wcslib@4.20:+cfitsio') - depends_on('fftw-api@3 precision=float,double', when='@3.4.0:') - depends_on('fftw-api@3 precision=float,double', when='~fftpack') - # SOFA dependency suffers the same problem in CMakeLists.txt as readline; - # force a dependency when building unit tests - depends_on('sofa-c', type='test') - depends_on('hdf5', when='+hdf5') - depends_on('adios2+mpi', when='+adios2') - depends_on('mpi', when='+adios2') - depends_on('python@2.6:', when='+python') - depends_on('boost+python', when='+python') - depends_on('py-numpy', when='+python') - depends_on('gsl', when='@3.5.0:') - - def cmake_args(self): - args = [] - spec = self.spec - - args.append(self.define_from_variant('ENABLE_SHARED', 'shared')) - args.append(self.define_from_variant('USE_OPENMP', 'openmp')) - args.append(self.define_from_variant('USE_READLINE', 'readline')) - args.append(self.define_from_variant('USE_HDF5', 'hdf5')) - args.append(self.define_from_variant('USE_ADIOS2', 'adios2')) - args.append(self.define_from_variant('USE_MPI', 'adios2')) - if spec.satisfies('+adios2'): - args.append(self.define('ENABLE_TABLELOCKING', False)) - - # fftw3 is required by casacore starting with v3.4.0, but the - # old fftpack is still available. For v3.4.0 and later, we - # always require FFTW3 dependency with the optional addition - # of FFTPack. In older casacore versions, only one of FFTW3 or - # FFTPack can be selected. - if spec.satisfies('@3.4.0:'): - if spec.satisfies('+fftpack'): - args.append('-DBUILD_FFTPACK_DEPRECATED=YES') - args.append(self.define('USE_FFTW3', True)) - else: - args.append(self.define('USE_FFTW3', spec.satisfies('~fftpack'))) - - # Python2 and Python3 binding - if spec.satisfies('~python'): - args.extend(['-DBUILD_PYTHON=NO', '-DBUILD_PYTHON3=NO']) - elif spec.satisfies('^python@3.0.0:'): - args.extend(['-DBUILD_PYTHON=NO', '-DBUILD_PYTHON3=YES']) - else: - args.extend(['-DBUILD_PYTHON=YES', '-DBUILD_PYTHON3=NO']) - - args.append('-DBUILD_TESTING=OFF') - return args - - def patch(self): - # Rely on CMake ability to find hdf5, available since CMake 3.7.X - os.remove('cmake/FindHDF5.cmake') From b79c87347964061183fdbfb1a551d86653fb295b Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 10:46:46 +0800 Subject: [PATCH 04/21] Contributes charmpp and chgcentre. --- repo/packages/charmpp/charm_6.7.1_aocc.patch | 188 ---- repo/packages/charmpp/charm_6.8.2_aocc.patch | 165 ---- repo/packages/charmpp/deserpenticate.patch | 36 - repo/packages/charmpp/fj.patch | 61 -- repo/packages/charmpp/mpi.patch | 19 - repo/packages/charmpp/nvhpc.patch | 77 -- repo/packages/charmpp/package.py | 371 -------- repo/packages/charmpp/shasta.patch.1 | 932 ------------------- repo/packages/charmpp/strictpass.patch | 16 - repo/packages/chgcentre/main.patch | 11 - repo/packages/chgcentre/package.py | 22 - 11 files changed, 1898 deletions(-) delete mode 100644 repo/packages/charmpp/charm_6.7.1_aocc.patch delete mode 100644 repo/packages/charmpp/charm_6.8.2_aocc.patch delete mode 100644 repo/packages/charmpp/deserpenticate.patch delete mode 100755 repo/packages/charmpp/fj.patch delete mode 100644 repo/packages/charmpp/mpi.patch delete mode 100644 repo/packages/charmpp/nvhpc.patch delete mode 100644 repo/packages/charmpp/package.py delete mode 100644 repo/packages/charmpp/shasta.patch.1 delete mode 100644 repo/packages/charmpp/strictpass.patch delete mode 100644 repo/packages/chgcentre/main.patch delete mode 100644 repo/packages/chgcentre/package.py diff --git a/repo/packages/charmpp/charm_6.7.1_aocc.patch b/repo/packages/charmpp/charm_6.7.1_aocc.patch deleted file mode 100644 index 3967e5fc..00000000 --- a/repo/packages/charmpp/charm_6.7.1_aocc.patch +++ /dev/null @@ -1,188 +0,0 @@ -diff -bur charm-6.7.1/src/arch/mpi-linux-x86_64/cc-mpicxx.sh updated-charm-6.7.1/src/arch/mpi-linux-x86_64/cc-mpicxx.sh ---- charm-6.7.1/src/arch/mpi-linux-x86_64/cc-mpicxx.sh 2016-11-07 20:14:26.000000000 +0530 -+++ updated-charm-6.7.1/src/arch/mpi-linux-x86_64/cc-mpicxx.sh 2019-08-26 16:55:40.868903291 +0530 -@@ -14,7 +14,7 @@ - - CMK_REAL_COMPILER=`$MPICXX -show 2>/dev/null | cut -d' ' -f1 ` - case "$CMK_REAL_COMPILER" in --g++) CMK_AMD64="-m64 -fPIC" ;; -+clang++) CMK_AMD64="-m64 -fPIC" ;; - icpc) CMK_AMD64="-m64";; - pgCC) CMK_AMD64="-DCMK_FIND_FIRST_OF_PREDICATE=1 --no_using_std " ;; - FCC) CMK_AMD64="-Kfast -DCMK_FIND_FIRST_OF_PREDICATE=1 --variadic_macros";; -diff -bur charm-6.7.1/src/arch/mpi-linux-x86_64/conv-mach-scyld.sh updated-charm-6.7.1/src/arch/mpi-linux-x86_64/conv-mach-scyld.sh ---- charm-6.7.1/src/arch/mpi-linux-x86_64/conv-mach-scyld.sh 2016-11-07 20:14:26.000000000 +0530 -+++ updated-charm-6.7.1/src/arch/mpi-linux-x86_64/conv-mach-scyld.sh 2019-08-26 16:55:40.868903291 +0530 -@@ -1,14 +1,14 @@ - - case "$CMK_CC" in - mpicc*) -- CMK_CPP_C="gcc -E " -- CMK_CC="gcc -fPIC" -- CMK_CC_RELIABLE="gcc -fPIC" -- CMK_CC_FASTEST="gcc -fPIC" -- CMK_CXX="g++ -fPIC" -- CMK_CXXPP="gcc -E " -- CMK_LD="gcc" -- CMK_LDXX="g++" -+ CMK_CPP_C="clang -E " -+ CMK_CC="clang -fPIC" -+ CMK_CC_RELIABLE="clang -fPIC" -+ CMK_CC_FASTEST="clang -fPIC" -+ CMK_CXX="clang++ -fPIC" -+ CMK_CXXPP="clang -E " -+ CMK_LD="clang" -+ CMK_LDXX="clang++" - - # native compiler for compiling charmxi, etc - CMK_NATIVE_CC="$CMK_CC" -Only in updated-charm-6.7.1/src/arch/mpi-linux-x86_64: conv-mach-scyld.sh.orig -Only in updated-charm-6.7.1/src/arch/mpi-linux-x86_64: conv-mach-scyld.sh.rej -diff -bur charm-6.7.1/src/arch/mpi-linux-x86_64/conv-mach.sh updated-charm-6.7.1/src/arch/mpi-linux-x86_64/conv-mach.sh ---- charm-6.7.1/src/arch/mpi-linux-x86_64/conv-mach.sh 2016-11-07 20:14:26.000000000 +0530 -+++ updated-charm-6.7.1/src/arch/mpi-linux-x86_64/conv-mach.sh 2019-08-26 16:55:40.868903291 +0530 -@@ -23,7 +23,7 @@ - - CMK_REAL_COMPILER=`$MPICXX -show 2>/dev/null | cut -d' ' -f1 ` - case "$CMK_REAL_COMPILER" in --g++) CMK_AMD64_CC="$CMK_GCC64"; CMK_AMD64_CXX="$CMK_GCC64" ;; -+clang++) CMK_AMD64_CC="$CMK_GCC64"; CMK_AMD64_CXX="$CMK_GCC64" ;; - pgCC) CMK_AMD64_CC="-fPIC"; CMK_AMD64_CXX="-fPIC -DCMK_FIND_FIRST_OF_PREDICATE=1 --no_using_std " ;; - charmc) echo "Error> charmc can not call AMPI's mpicxx/mpiCC wrapper! Please fix your PATH."; exit 1 ;; - esac -@@ -38,10 +38,10 @@ - CMK_LIBS="-lckqt $CMK_SYSLIBS " - CMK_LD_LIBRARY_PATH="-Wl,-rpath,$CHARMLIBSO/" - --CMK_NATIVE_CC="gcc $CMK_GCC64 " --CMK_NATIVE_LD="gcc $CMK_GCC64 " --CMK_NATIVE_CXX="g++ $CMK_GCC64 " --CMK_NATIVE_LDXX="g++ $CMK_GCC64 " -+CMK_NATIVE_CC="clang $CMK_GCC64 " -+CMK_NATIVE_LD="clang $CMK_GCC64 " -+CMK_NATIVE_CXX="clang++ $CMK_GCC64 " -+CMK_NATIVE_LDXX="clang++ $CMK_GCC64 " - CMK_NATIVE_LIBS="" - - # fortran compiler -@@ -51,7 +51,7 @@ - # CMK_FPP="/lib/cpp -P -CC" - # CMK_CF90="$CMK_CF90 -fpic -fautomatic -fdollar-ok " - # CMK_CF90_FIXED="$CMK_CF90 -ffixed-form " --# CMK_F90LIBS="-lgfortran " -+# CMK_F90LIBS=" " - # CMK_F90_USE_MODDIR=1 - # CMK_F90_MODINC="-I" - # CMK_MOD_NAME_ALLCAPS= -diff -bur charm-6.7.1/src/libs/ck-libs/ckloop/Makefile updated-charm-6.7.1/src/libs/ck-libs/ckloop/Makefile ---- charm-6.7.1/src/libs/ck-libs/ckloop/Makefile 2016-11-07 20:14:28.000000000 +0530 -+++ updated-charm-6.7.1/src/libs/ck-libs/ckloop/Makefile 2019-08-26 16:55:40.852903122 +0530 -@@ -38,7 +38,7 @@ - for i in $(LIBOBJ) ; do \ - SRCFILE=`basename $$i .o`.C ; \ - echo "checking dependencies for $$i : $$SRCFILE" ; \ -- g++ -MM -Wno-deprecated -I$(CDIR)/tmp $$SRCFILE >> $(DEPENDFILE); \ -+ clang++ -MM -Wno-deprecated -I$(CDIR)/tmp $$SRCFILE >> $(DEPENDFILE); \ - echo ' $$(CHARMC) -I$(CDIR)/tmp -o '$$i $$SRCFILE >> $(DEPENDFILE) ; \ - done; - -Only in updated-charm-6.7.1/src/libs/ck-libs/ckloop: Makefile.orig -Only in updated-charm-6.7.1/src/libs/ck-libs/ckloop: Makefile.rej -diff -bur charm-6.7.1/src/libs/ck-libs/completion/Makefile updated-charm-6.7.1/src/libs/ck-libs/completion/Makefile ---- charm-6.7.1/src/libs/ck-libs/completion/Makefile 2016-11-07 20:14:28.000000000 +0530 -+++ updated-charm-6.7.1/src/libs/ck-libs/completion/Makefile 2019-08-26 16:55:40.852903122 +0530 -@@ -45,7 +45,7 @@ - for i in $(LIBOBJ) ; do \ - SRCFILE=`basename $$i .o`.C ; \ - echo "checking dependencies for $$i : $$SRCFILE" ; \ -- g++ -MM -Wno-deprecated -I$(CDIR)/tmp $$SRCFILE >> $(DEPENDFILE); \ -+ clang++ -MM -Wno-deprecated -I$(CDIR)/tmp $$SRCFILE >> $(DEPENDFILE); \ - echo ' $$(CHARMC) -I$(CDIR)/tmp -o '$$i $$SRCFILE >> $(DEPENDFILE) ; \ - done; - -Only in updated-charm-6.7.1/src/libs/ck-libs/completion: Makefile.orig -Only in updated-charm-6.7.1/src/libs/ck-libs/completion: Makefile.rej -diff -bur charm-6.7.1/src/libs/ck-libs/multicast/Makefile updated-charm-6.7.1/src/libs/ck-libs/multicast/Makefile ---- charm-6.7.1/src/libs/ck-libs/multicast/Makefile 2016-11-07 20:14:29.000000000 +0530 -+++ updated-charm-6.7.1/src/libs/ck-libs/multicast/Makefile 2019-08-26 16:55:40.852903122 +0530 -@@ -53,7 +53,7 @@ - for i in $(LIBOBJ) ; do \ - SRCFILE=`basename $$i .o`.C ; \ - echo "checking dependencies for $$i : $$SRCFILE" ; \ -- g++ -MM -Wno-deprecated -I$(CDIR)/tmp $$SRCFILE >> $(DEPENDFILE); \ -+ clang++ -MM -Wno-deprecated -I$(CDIR)/tmp $$SRCFILE >> $(DEPENDFILE); \ - echo ' $$(CHARMC) -I$(CDIR)/tmp -o '$$i $$SRCFILE >> $(DEPENDFILE) ; \ - done; - -Only in updated-charm-6.7.1/src/libs/ck-libs/multicast: Makefile.orig -Only in updated-charm-6.7.1/src/libs/ck-libs/multicast: Makefile.rej -diff -bur charm-6.7.1/src/libs/ck-libs/NDMeshStreamer/Makefile updated-charm-6.7.1/src/libs/ck-libs/NDMeshStreamer/Makefile ---- charm-6.7.1/src/libs/ck-libs/NDMeshStreamer/Makefile 2016-11-07 20:14:27.000000000 +0530 -+++ updated-charm-6.7.1/src/libs/ck-libs/NDMeshStreamer/Makefile 2019-08-26 16:55:40.852903122 +0530 -@@ -52,7 +52,7 @@ - for i in $(LIBOBJ) ; do \ - SRCFILE=`basename $$i .o`.C ; \ - echo "checking dependencies for $$i : $$SRCFILE" ; \ -- g++ -MM -Wno-deprecated -I$(CDIR)/tmp -I../completion $$SRCFILE >> $(DEPENDFILE); \ -+ clang++ -MM -Wno-deprecated -I$(CDIR)/tmp -I../completion $$SRCFILE >> $(DEPENDFILE); \ - echo ' $$(CHARMC) -I$(CDIR)/tmp -o '$$i $$SRCFILE >> $(DEPENDFILE) ; \ - done; - -Only in updated-charm-6.7.1/src/libs/ck-libs/NDMeshStreamer: Makefile.orig -Only in updated-charm-6.7.1/src/libs/ck-libs/NDMeshStreamer: Makefile.rej -diff -bur charm-6.7.1/src/QuickThreads/Makefile updated-charm-6.7.1/src/QuickThreads/Makefile ---- charm-6.7.1/src/QuickThreads/Makefile 2016-11-07 20:14:25.000000000 +0530 -+++ updated-charm-6.7.1/src/QuickThreads/Makefile 2019-08-26 16:55:40.856903165 +0530 -@@ -1,5 +1,5 @@ - --CC=gcc -I. -O2 -+CC=clang -I. -O2 - - all: qt stp testpgm - -diff -bur charm-6.7.1/src/scripts/Makefile updated-charm-6.7.1/src/scripts/Makefile ---- charm-6.7.1/src/scripts/Makefile 2016-11-07 20:14:29.000000000 +0530 -+++ updated-charm-6.7.1/src/scripts/Makefile 2019-08-26 16:55:40.840902996 +0530 -@@ -942,7 +942,7 @@ - SRCFILE=`basename $$i .o`.C ; \ - [ ! -f $$SRCFILE ] && SRCFILE=`basename $$i .o`.c ; \ - echo "checking dependencies for $$SRCFILE" ; \ -- if g++ -MM -Wno-deprecated -I. -I$(INC) $$SRCFILE >> $(DEPENDFILE); then true ; else echo '' ; echo "Compilation of '$$SRCFILE' failed, please fix it first!!!!" ; exit; fi; \ -+ if clang++ -MM -Wno-deprecated -I. -I$(INC) $$SRCFILE >> $(DEPENDFILE); then true ; else echo '' ; echo "Compilation of '$$SRCFILE' failed, please fix it first!!!!" ; exit; fi; \ - echo '' >> $(DEPENDFILE) ; \ - done; \ - -@@ -968,7 +968,7 @@ - found=`/usr/bin/find $$SRCDIR -depth 1 -name $$SRCFILE`; \ - [ ! $$found ] && SRCFILE=`basename $$i .o`.c ; \ - echo "checking dependencies for $$SRCFILE" ; \ -- if g++ -MM -Wno-deprecated -I. -I$(INC) $$SRCFILE >> $(DEPENDFILE); then true ; else echo '' ; echo "Compilation of '$$SRCFILE' failed, please fix it first!!!!" ; exit; fi; \ -+ if clang++ -MM -Wno-deprecated -I. -I$(INC) $$SRCFILE >> $(DEPENDFILE); then true ; else echo '' ; echo "Compilation of '$$SRCFILE' failed, please fix it first!!!!" ; exit; fi; \ - echo '' >> $(DEPENDFILE) ; \ - done; \ - -diff -bur charm-6.7.1/tests/charm++/megatest/Makefile updated-charm-6.7.1/tests/charm++/megatest/Makefile ---- charm-6.7.1/tests/charm++/megatest/Makefile 2016-11-07 20:14:30.000000000 +0530 -+++ updated-charm-6.7.1/tests/charm++/megatest/Makefile 2019-08-26 16:55:40.820902785 +0530 -@@ -118,7 +118,7 @@ - for i in $(OBJS) ; do \ - SRCFILE=`basename $$i .o`.C ; \ - echo "checking dependencies for $$SRCFILE" ; \ -- g++ -MM -I$(CHARMINC) $$SRCFILE | \ -+ clang++ -MM -I$(CHARMINC) $$SRCFILE | \ - perl $(CHARMBIN)/dep.pl $(CHARMINC) /usr/include /usr/local >> $(DEPENDFILE); \ - echo ' $$(CHARMC) -o '$$i $$SRCFILE >> $(DEPENDFILE) ; \ - done; ---- charm-6.7.1/src/scripts/configure 2016-11-07 20:14:31.000000000 +0530 -+++ updated-charm/charm-6.7.1/src/scripts/configure 2020-10-21 12:54:06.476958828 +0530 -@@ -2141,8 +2141,8 @@ - $as_echo_n "checking \"$1\"... " >&6; } - echo "### $1" >> $charmout - cat $t >> $charmout -- echo $CMK_CXX -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CXX $OPTS_LD -c $t -o test.o $4 >> $charmout -- $CMK_CXX -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CXX $OPTS_LD -c $t -o test.o $4 > out 2>&1 -+ echo $CMK_CXX -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CXX $OPTS_LD -Qunused-arguments -c $t -o test.o $4 >> $charmout -+ $CMK_CXX -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CXX $OPTS_LD -Qunused-arguments -c $t -o test.o $4 > out 2>&1 - test_result $? "$1" "$2" "$3" - strictpass=$pass - strictfail=$fail diff --git a/repo/packages/charmpp/charm_6.8.2_aocc.patch b/repo/packages/charmpp/charm_6.8.2_aocc.patch deleted file mode 100644 index b1a736c2..00000000 --- a/repo/packages/charmpp/charm_6.8.2_aocc.patch +++ /dev/null @@ -1,165 +0,0 @@ -diff -ruN 00/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/cc-mpicxx.sh 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/cc-mpicxx.sh ---- 00/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/cc-mpicxx.sh 2018-01-11 19:06:19.000000000 -0600 -+++ 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/cc-mpicxx.sh 2019-11-12 06:02:23.005454343 -0600 -@@ -15,6 +15,7 @@ - CMK_REAL_COMPILER=`$MPICXX -show 2>/dev/null | cut -d' ' -f1 ` - case "$CMK_REAL_COMPILER" in - g++) CMK_AMD64="-m64 -fPIC" ;; -+clang++) CMK_AMD64="-m64 -fPIC" ;; - icpc) CMK_AMD64="-m64";; - pgCC) CMK_AMD64="-DCMK_FIND_FIRST_OF_PREDICATE=1 --no_using_std " ;; - FCC) CMK_AMD64="-Kfast -DCMK_FIND_FIRST_OF_PREDICATE=1 --variadic_macros";; -diff -ruN 00/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/conv-mach-scyld.sh 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/conv-mach-scyld.sh ---- 00/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/conv-mach-scyld.sh 2018-01-11 19:06:19.000000000 -0600 -+++ 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/conv-mach-scyld.sh 2019-11-12 06:05:22.666969636 -0600 -@@ -1,13 +1,14 @@ - - case "$CMK_CC" in - mpicc*) -- CMK_CPP_C="gcc -E " -- CMK_CC="gcc -fPIC" -- CMK_CC_RELIABLE="gcc -fPIC" -- CMK_CC_FASTEST="gcc -fPIC" -- CMK_CXX="g++ -fPIC" -- CMK_LD="gcc" -- CMK_LDXX="g++" -+ CMK_CPP_C="clang -E " -+ CMK_CC="clang -fPIC" -+ CMK_CC_RELIABLE="clang -fPIC" -+ CMK_CC_FASTEST="clang -fPIC" -+ CMK_CXXPP="clang -E " -+ CMK_CXX="clang++ -fPIC" -+ CMK_LD="clang" -+ CMK_LDXX="clang++" - - # native compiler for compiling charmxi, etc - CMK_NATIVE_CC="$CMK_CC" -diff -ruN 00/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/conv-mach.sh 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/conv-mach.sh ---- 00/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/conv-mach.sh 2018-01-11 19:06:19.000000000 -0600 -+++ 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/arch/mpi-linux-x86_64/conv-mach.sh 2019-11-12 06:07:41.361999246 -0600 -@@ -23,6 +23,7 @@ - - CMK_REAL_COMPILER=`$MPICXX -show 2>/dev/null | cut -d' ' -f1 ` - case "$CMK_REAL_COMPILER" in -+clang++) CMK_AMD64_CC="$CMK_GCC64"; CMK_AMD64_CXX="$CMK_GCC64" ;; - g++) CMK_AMD64_CC="$CMK_GCC64"; CMK_AMD64_CXX="$CMK_GCC64" ;; - pgCC) CMK_AMD64_CC='-fPIC'; CMK_AMD64_CXX='-fPIC -DCMK_FIND_FIRST_OF_PREDICATE=1 --no_using_std ' ;; - charmc) echo "Error> charmc can not call AMPI's mpicxx/mpiCC wrapper! Please fix your PATH."; exit 1 ;; -@@ -37,10 +38,10 @@ - CMK_LIBS="-lckqt $CMK_SYSLIBS " - CMK_LD_LIBRARY_PATH="-Wl,-rpath,$CHARMLIBSO/" - --CMK_NATIVE_CC="gcc $CMK_GCC64 " --CMK_NATIVE_LD="gcc $CMK_GCC64 " --CMK_NATIVE_CXX="g++ $CMK_GCC64 " --CMK_NATIVE_LDXX="g++ $CMK_GCC64 " -+CMK_NATIVE_CC="clang $CMK_GCC64 " -+CMK_NATIVE_LD="clang $CMK_GCC64 " -+CMK_NATIVE_CXX="clang++ $CMK_GCC64 " -+CMK_NATIVE_LDXX="clang++ $CMK_GCC64 " - CMK_NATIVE_LIBS='' - - # fortran compiler -diff -ruN 00/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/ckloop/Makefile 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/ckloop/Makefile ---- 00/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/ckloop/Makefile 2018-01-11 19:06:15.000000000 -0600 -+++ 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/ckloop/Makefile 2019-11-12 06:09:16.200438412 -0600 -@@ -38,7 +38,7 @@ - for i in $(LIBOBJ) ; do \ - SRCFILE=`basename $$i .o`.C ; \ - echo "checking dependencies for $$i : $$SRCFILE" ; \ -- g++ -MM -Wno-deprecated -I$(CDIR)/tmp $$SRCFILE >> $(DEPENDFILE); \ -+ clang++ -MM -Wno-deprecated -I$(CDIR)/tmp $$SRCFILE >> $(DEPENDFILE); \ - echo ' $$(CHARMC) -I$(CDIR)/tmp -o '$$i $$SRCFILE >> $(DEPENDFILE) ; \ - done; - -diff -ruN 00/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/completion/Makefile 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/completion/Makefile ---- 00/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/completion/Makefile 2018-01-11 19:06:16.000000000 -0600 -+++ 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/completion/Makefile 2019-11-12 06:09:41.247346697 -0600 -@@ -45,7 +45,7 @@ - for i in $(LIBOBJ) ; do \ - SRCFILE=`basename $$i .o`.C ; \ - echo "checking dependencies for $$i : $$SRCFILE" ; \ -- g++ -MM -Wno-deprecated -I$(CDIR)/tmp $$SRCFILE >> $(DEPENDFILE); \ -+ clang++ -MM -Wno-deprecated -I$(CDIR)/tmp $$SRCFILE >> $(DEPENDFILE); \ - echo ' $$(CHARMC) -I$(CDIR)/tmp -o '$$i $$SRCFILE >> $(DEPENDFILE) ; \ - done; - -diff -ruN 00/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/NDMeshStreamer/Makefile 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/NDMeshStreamer/Makefile ---- 00/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/NDMeshStreamer/Makefile 2018-01-11 19:06:15.000000000 -0600 -+++ 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/libs/ck-libs/NDMeshStreamer/Makefile 2019-11-12 06:09:59.079993368 -0600 -@@ -52,7 +52,7 @@ - for i in $(LIBOBJ) ; do \ - SRCFILE=`basename $$i .o`.C ; \ - echo "checking dependencies for $$i : $$SRCFILE" ; \ -- g++ -MM -Wno-deprecated -I$(CDIR)/tmp -I../completion $$SRCFILE >> $(DEPENDFILE); \ -+ clang++ -MM -Wno-deprecated -I$(CDIR)/tmp -I../completion $$SRCFILE >> $(DEPENDFILE); \ - echo ' $$(CHARMC) -I$(CDIR)/tmp -o '$$i $$SRCFILE >> $(DEPENDFILE) ; \ - done; - -diff -ruN 00/NAMD_2.13_Source/charm-6.8.2/src/QuickThreads/Makefile 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/QuickThreads/Makefile ---- 00/NAMD_2.13_Source/charm-6.8.2/src/QuickThreads/Makefile 2018-01-11 19:06:13.000000000 -0600 -+++ 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/QuickThreads/Makefile 2019-11-12 06:10:37.744395459 -0600 -@@ -1,5 +1,5 @@ - --CC=gcc -I. -O2 -+CC=clang -I. -O2 - - all: qt stp testpgm - -diff -ruN 00/NAMD_2.13_Source/charm-6.8.2/src/scripts/Makefile 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/scripts/Makefile ---- 00/NAMD_2.13_Source/charm-6.8.2/src/scripts/Makefile 2018-01-11 19:06:20.000000000 -0600 -+++ 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/scripts/Makefile 2019-11-12 06:10:59.888198461 -0600 -@@ -962,7 +962,7 @@ - SRCFILE=`basename $$i .o`.C ; \ - [ ! -f $$SRCFILE ] && SRCFILE=`basename $$i .o`.c ; \ - echo "checking dependencies for $$SRCFILE" ; \ -- if g++ -std=c++0x -MM -Wno-deprecated -I. -I$(INC) $$SRCFILE >> $(DEPENDFILE); then true ; else echo '' ; echo "Compilation of '$$SRCFILE' failed, please fix it first!!!!" ; exit; fi; \ -+ if clang++ -std=c++0x -MM -Wno-deprecated -I. -I$(INC) $$SRCFILE >> $(DEPENDFILE); then true ; else echo '' ; echo "Compilation of '$$SRCFILE' failed, please fix it first!!!!" ; exit; fi; \ - echo '' >> $(DEPENDFILE) ; \ - done; \ - -@@ -988,7 +988,7 @@ - found=`/usr/bin/find $$SRCDIR -depth 1 -name $$SRCFILE`; \ - [ ! $$found ] && SRCFILE=`basename $$i .o`.c ; \ - echo "checking dependencies for $$SRCFILE" ; \ -- if g++ -std=c++0x -MM -Wno-deprecated -I. -I$(INC) $$SRCFILE >> $(DEPENDFILE); then true ; else echo '' ; echo "Compilation of '$$SRCFILE' failed, please fix it first!!!!" ; exit; fi; \ -+ if clang++ -std=c++0x -MM -Wno-deprecated -I. -I$(INC) $$SRCFILE >> $(DEPENDFILE); then true ; else echo '' ; echo "Compilation of '$$SRCFILE' failed, please fix it first!!!!" ; exit; fi; \ - echo '' >> $(DEPENDFILE) ; \ - done; \ - -diff -ruN 00/NAMD_2.13_Source/charm-6.8.2/tests/charm++/megatest/Makefile 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/tests/charm++/megatest/Makefile ---- 00/NAMD_2.13_Source/charm-6.8.2/tests/charm++/megatest/Makefile 2018-01-11 19:06:18.000000000 -0600 -+++ 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/tests/charm++/megatest/Makefile 2019-11-12 06:11:38.193587531 -0600 -@@ -116,7 +116,7 @@ - for i in $(OBJS) ; do \ - SRCFILE=`basename $$i .o`.C ; \ - echo "checking dependencies for $$SRCFILE" ; \ -- g++ -std=c++0x -MM -I$(CHARMINC) $$SRCFILE | \ -+ clang++ -std=c++0x -MM -I$(CHARMINC) $$SRCFILE | \ - perl $(CHARMBIN)/dep.pl $(CHARMINC) /usr/include /usr/local >> $(DEPENDFILE); \ - echo ' $$(CHARMC) -o '$$i $$SRCFILE >> $(DEPENDFILE) ; \ - done; ---- 00/NAMD_2.13_Source/charm-6.8.2/src/scripts/configure 2018-01-12 06:36:21.000000000 +0530 -+++ 00_aocc-patch/NAMD_2.13_Source/charm-6.8.2/src/scripts/configure 2020-10-21 15:01:20.240748316 +0530 -@@ -2183,8 +2183,8 @@ - $as_echo_n "checking \"$1\"... " >&6; } - echo "### $1" >> $charmout - cat $tc >> $charmout -- echo $CMK_CC -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CC $OPTS_LD -c $tc -o test.o $4 >> $charmout -- $CMK_CC -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CC $OPTS_LD -c $tc -o test.o $4 > out 2>&1 -+ echo $CMK_CC -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CC $OPTS_LD -Qunused-arguments -c $tc -o test.o $4 >> $charmout -+ $CMK_CC -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CC $OPTS_LD -Qunused-arguments -c $tc -o test.o $4 > out 2>&1 - test_result $? "$1" "$2" "$3" - strictpass=$pass - strictfail=$fail -@@ -2208,8 +2208,8 @@ - $as_echo_n "checking \"$1\"... " >&6; } - echo "### $1" >> $charmout - cat $t >> $charmout -- echo $CMK_CXX -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CXX $OPTS_LD -c $t -o test.o $4 >> $charmout -- $CMK_CXX -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CXX $OPTS_LD -c $t -o test.o $4 > out 2>&1 -+ echo $CMK_CXX -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CXX $OPTS_LD -Qunused-arguments -c $t -o test.o $4 >> $charmout -+ $CMK_CXX -I../include -I. $CMK_LIBDIR $CMK_INCDIR $CMK_SYSINC $OPTS_CXX $OPTS_LD -Qunused-arguments -c $t -o test.o $4 > out 2>&1 - test_result $? "$1" "$2" "$3" - strictpass=$pass - strictfail=$fail diff --git a/repo/packages/charmpp/deserpenticate.patch b/repo/packages/charmpp/deserpenticate.patch deleted file mode 100644 index 3ac40df1..00000000 --- a/repo/packages/charmpp/deserpenticate.patch +++ /dev/null @@ -1,36 +0,0 @@ -diff -ur a/src/scripts/configure.ac b/src/scripts/configure.ac ---- a/src/scripts/configure.ac 2020-08-05 13:13:21.000000000 +0800 -+++ b/src/scripts/configure.ac 2022-11-09 17:00:27.000000000 +0800 -@@ -2542,29 +2542,9 @@ - fi - fi - --#### test if Python headers are installed #### --PYTHON_VERSION=`python -V 2>&1 | awk {'print $2'} | awk -F. {'print $1"."$2'}` --cat > $t </dev/null` -+if test -n "$f90bindir" -+then -+ f90libdir="$f90bindir/../lib" -+fi -+CMK_F90LIBS="-L$f90libdir " -+CMK_F90_USE_MODDIR="" ---- /dev/null 2020-08-25 10:23:08.110000124 -0700 -+++ b/src/arch/common/conv-mach-nvfortran.sh 2020-09-03 08:25:09.042243776 -0700 -@@ -0,0 +1,13 @@ -+COMMENT="Use nvfortran fortran compiler" -+NVFORTRAN=`which nvfortran` -+if test x$NVFORTRAN = x -+then -+ echo charmc> Fatal error: nvfortran not found! -+ exit 1 -+fi -+CMK_CF77="$NVFORTRAN " -+CMK_CF90="$NVFORTRAN " -+CMK_CF90_FIXED="$CMK_CF90 -Mfixed " -+CMK_F90LIBS="-lm " -+CMK_F90_MODINC="-module " -+CMK_F90_USE_MODDIR="" ---- /dev/null 2020-08-25 10:23:08.110000124 -0700 -+++ b/src/arch/common/conv-mach-nvfortran.h 2020-09-03 08:25:09.042243776 -0700 -@@ -0,0 +1,1 @@ -+/* empty file */ diff --git a/repo/packages/charmpp/package.py b/repo/packages/charmpp/package.py deleted file mode 100644 index db757eb2..00000000 --- a/repo/packages/charmpp/package.py +++ /dev/null @@ -1,371 +0,0 @@ -# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# Contribute back cray shasta support - -import os -import platform -import shutil -import sys - -from spack.package import * - - -class Charmpp(Package): - """Charm++ is a parallel programming framework in C++ supported by - an adaptive runtime system, which enhances user productivity and - allows programs to run portably from small multicore computers - (your laptop) to the largest supercomputers.""" - - homepage = "https://charmplusplus.org" - url = "https://charm.cs.illinois.edu/distrib/charm-6.8.2.tar.gz" - git = "https://github.com/UIUC-PPL/charm.git" - - maintainers = ["matthiasdiener"] - - version("main", branch="main") - - version('7.0.0', sha256='9c247b421bb157bdf9bc0ced3e25738c7a1dc1f7ec57b7943a7faf97f7e4fb2e') - version('6.10.2', sha256='7abb4cace8aebdfbb8006eac03eb766897c009cfb919da0d0a33f74c3b4e6deb') - version('6.10.1', sha256='ab96198105daabbb8c8bdf370f87b0523521ce502c656cb6cd5b89f69a2c70a8') - version('6.10.0', sha256='7c526a78aa0c202b7f0418b345138e7dc40496f0bb7b9e301e0381980450b25c') - version("6.9.0", sha256="85ed660e46eeb7a6fc6b32deab08226f647c244241948f6b592ebcd2b6050cbd") - version("6.8.2", sha256="08e6001b0e9cd00ebde179f76098767149bf7e454f29028fb9a8bfb55778698e") - version("6.8.1", sha256="bf39666bb9f8bad1cd17dafa3cdf35c7ef64dfaeda835cf66ae530b7baab7583") - version("6.8.0", sha256="deca68622932ea0c677aa764d6d24cd169a2fd99c06e7d7b6947c0f18ec2f8f3") - version("6.7.1", sha256="744a093874fbac03b6ae8be3ce434eff46b2ee778561e860802ed578e0810fdf") - version("6.7.0", sha256="6b0d8215a180c90cf6ee33ff39f66726934df34aaeeed59650dd3a0cc54d0c87") - version("6.6.1", sha256="2aa16fd3015dce0a0932ab5253578a72ddbcb889bc0d23584c42b28446915467") - version("6.6.0", sha256="c916010f2d4cc2c6bd30ea19764839d0298fb56d1696d8ff08d9fa9a61dfb1c9") - version("6.5.1", sha256="68aa43e2a6e476e116a7e80e385c25c6ac6497807348025505ba8bfa256ed34a") - - # Support OpenMPI; see - # - # Patch is no longer needed in versions 6.8.0+ - patch("mpi.patch", when="@:6.7.1") - - # Patch for AOCC - patch('charm_6.7.1_aocc.patch', when="@6.7.1 %aocc", level=1) - patch('charm_6.8.2_aocc.patch', when="@6.8.2 %aocc", level=3) - - # support Fujitsu compiler - patch("fj.patch", when="%fj") - - # support NVIDIA compilers - patch("nvhpc.patch", when="%nvhpc") - - # Ignore compiler warnings while configuring - patch("strictpass.patch", when="@:6.8.2") - - # Update v6.10.2 with shasta targets (backport from 7.0.0). - patch("shasta.patch.1", when="@:6.10.2") - - # Remove PythonCCS (relies on Python 2 API) - patch("deserpenticate.patch") - - # Build targets - # "target" is reserved, so we have to use something else. - variant( - "build-target", - default="LIBS", - # AMPI also builds charm++, LIBS also builds AMPI and charm++ - values=("charm++", "AMPI", "LIBS", "ChaNGa"), - description="Specify the target to build" - ) - - # Communication mechanisms (choose exactly one) - variant( - "backend", - default="netlrts", - values=("mpi", "multicore", "netlrts", "verbs", "gni", - "ucx", "ofi", "pami", "pamilrts"), - description="Set the backend to use" - ) - - # Process management interface - variant( - "pmi", - default="none", - values=("none", "simplepmi", "slurmpmi", "slurmpmi2", "pmix"), - description="The ucx/ofi/gni backends need PMI to run!" - ) - - # Other options - variant("papi", default=False, description="Enable PAPI integration") - variant("syncft", default=False, description="Compile with Charm++ fault tolerance support") - variant("smp", default=True, - description=( - "Enable SMP parallelism (does not work with +multicore)")) - variant("tcp", default=False, - description="Use TCP as transport mechanism (requires +net)") - variant("omp", default=False, description="Support for the integrated LLVM OpenMP runtime") - variant("pthreads", default=False, description="Compile with pthreads Converse threads") - variant("cuda", default=False, description="Enable CUDA toolkit") - - variant("shared", default=True, description="Enable shared link support") - variant("production", default=True, description="Build charm++ with all optimizations") - variant("tracing", default=False, description="Enable tracing modules") - - depends_on("cmake@3.4.0:", when="@7.0.0:", type='build' ) - depends_on("autoconf", when="@:6.99.99", type='build' ) # Anything pre-7.0. - depends_on("automake", when="@:6.99.99", type='build' ) - - depends_on("mpi", when="backend=mpi") - depends_on("papi", when="+papi") - depends_on("cuda", when="+cuda") - - depends_on("ucx", when="backend=ucx") - depends_on("slurm@:17-11-9-2", when="pmi=slurmpmi") - depends_on("slurm@17-11-9-2:", when="pmi=slurmpmi2") - - depends_on("libfabric", when="backend=ofi") - - # FIXME : As of now spack's OpenMPI recipe does not have a PMIx variant - # But if users have external installs of OpenMPI with PMIx support, this - # will allow them to build charm++ with it. - depends_on("openmpi", when="pmi=pmix") - - depends_on("mpi", when="pmi=simplepmi") - depends_on("mpi", when="pmi=slurmpmi") - depends_on("mpi", when="pmi=slurmpmi2") - # If pmi is not specified, simplepmi will be used for ofi. - depends_on("mpi", when="backend=ofi") - - conflicts("~tracing", "+papi") - - conflicts("backend=multicore", "+smp") - conflicts("backend=ucx", when="@:6.9") - - @property - def charmarch(self): - plat = sys.platform - platplat = platform.platform() - specplat = self.spec.platform - - if "shasta" in platplat and self.spec.satisfies('@6.8.2:'): - plat = "shasta" - elif specplat.startswith("cray"): - plat = "cnl" - elif plat.startswith("linux"): - plat = "linux" - elif plat.startswith("win"): - plat = "win" - elif plat.startswith("cnl"): - plat = "cnl" - elif plat.startswith("cnk"): - plat = "cnk" - - mach = platform.machine() - - if mach.startswith("ppc"): - mach = "ppc" - elif mach.startswith("arm"): - mach = "arm" - - comm = self.spec.variants['backend'].value - - # Define Charm++ version names for various (plat, mach, comm) - # combinations. Note that not all combinations are supported. - versions = { - ("darwin", "x86_64", "mpi"): "mpi-darwin-x86_64", - ("darwin", "x86_64", "multicore"): "multicore-darwin-x86_64", - ("darwin", "x86_64", "netlrts"): "netlrts-darwin-x86_64", - ("linux", "x86_64", "mpi"): "mpi-linux-x86_64", - ("linux", "x86_64", "multicore"): "multicore-linux-x86_64", - ("linux", "x86_64", "netlrts"): "netlrts-linux-x86_64", - ("linux", "x86_64", "verbs"): "verbs-linux-x86_64", - ("linux", "x86_64", "ofi"): "ofi-linux-x86_64", - ("linux", "x86_64", "ucx"): "ucx-linux-x86_64", - ("linux", "ppc", "mpi"): "mpi-linux-ppc", - ("linux", "ppc", "multicore"): "multicore-linux-ppc", - ("linux", "ppc", "netlrts"): "netlrts-linux-ppc", - ("linux", "ppc", "pami"): "pami-linux-ppc64le", - ("linux", "ppc", "verbs"): "verbs-linux-ppc64le", - ("linux", "arm", "netlrts"): "netlrts-linux-arm7", - ("linux", "arm", "multicore"): "multicore-arm7", - ("linux", "aarch64", "netlrts"): "netlrts-linux-arm8", - ("linux", "aarch64", "multicore"): "multicore-arm8", - ("win", "x86_64", "mpi"): "mpi-win-x86_64", - ("win", "x86_64", "multicore"): "multicore-win-x86_64", - ("win", "x86_64", "netlrts"): "netlrts-win-x86_64", - ("cnl", "x86_64", "gni"): "gni-crayxc", - ("cnl", "x86_64", "mpi"): "mpi-crayxc", - ("shasta", "x86_64", "ofi"): "ofi-crayshasta", - ("shasta", "x86_64", "mpi"): "mpi-crayshasta", - } - - # Some versions were renamed/removed in 6.11 - if self.spec.version < Version("6.11.0"): - versions.update({("linux", "i386", "mpi"): "mpi-linux"}) - versions.update({("linux", "i386", "multicore"): - "multicore-linux"}) - versions.update({("linux", "i386", "netlrts"): "netlrts-linux"}) - versions.update({("linux", "i386", "uth"): "uth-linux"}) - else: - versions.update({("linux", "i386", "mpi"): "mpi-linux-i386"}) - versions.update({("linux", "i386", "multicore"): - "multicore-linux-i386"}) - versions.update({("linux", "i386", "netlrts"): - "netlrts-linux-i386"}) - - if (plat, mach, comm) not in versions: - raise InstallError( - "The communication mechanism %s is not supported " - "on a %s platform with a %s CPU" % - (comm, plat, mach)) - - return versions[(plat, mach, comm)] - - def setup_build_environment(self, env): - if ("backend=ofi") in self.spec: - env.set('LIBFABRIC', self.spec['libfabric'].prefix) - - # FIXME: backend=mpi also provides mpi, but spack does not support - # depends_on("mpi") and provides("mpi") in the same package currently. - # for b in ['multicore', 'netlrts', 'verbs', 'gni', 'ofi', 'pami', - # 'pamilrts']: - # provides('mpi@2', when='@6.7.1: - # build-target=AMPI backend={0}'.format(b)) - # provides('mpi@2', when='@6.7.1: - # build-target=LIBS backend={0}'.format(b)) - - def install(self, spec, prefix): - - if not("backend=mpi" in self.spec) or \ - not("backend=netlrts" in self.spec): - if ("+pthreads" in self.spec): - raise InstallError("The pthreads option is only\ - available on the Netlrts and MPI \ - network layers.") - - if ("pmi=simplepmi" in self.spec) or \ - ("pmi=slurmpmi" in self.spec) or \ - ("pmi=slurmpmi2" in self.spec): - if ("^openmpi" in self.spec): - raise InstallError("To use any process management \ - interface other than PMIx, \ - a non OpenMPI based MPI must be \ - present on the system") - - target = spec.variants["build-target"].value - builddir = prefix - - # We assume that Spack's compiler wrappers make this work. If - # not, then we need to query the compiler vendor from Spack - # here. - if spec.satisfies('@6.8.2:') and "shasta" in platform.platform(): - options = [ ] - else: - options = [ - os.path.basename(self.compiler.cc) - ] - if '@:6.8.2 %aocc' not in spec: - options.append(os.path.basename(self.compiler.fc)) - - options.append("-j%d" % make_jobs) - options.append("--destination=%s" % builddir) - - if "pmi=slurmpmi" in spec: - options.append("slurmpmi") - if "pmi=slurmpmi2" in spec: - options.append("slurmpmi2") - if "pmi=pmix" in spec: - options.append("ompipmix") - options.extend(["--basedir=%s" % spec["openmpi"].prefix]) - - if 'backend=mpi' in spec: - # in intelmpi /include and /lib fails so --basedir - # cannot be used - options.extend([ - '--incdir={0}'.format(incdir) - for incdir in spec["mpi"].headers.directories - ]) - options.extend([ - '--libdir={0}'.format(libdir) - for libdir in spec["mpi"].libs.directories - ]) - - if "backend=ucx" in spec: - options.extend(["--basedir=%s" % spec["ucx"].prefix]) - if "+papi" in spec: - options.extend(["papi", "--basedir=%s" % spec["papi"].prefix]) - if "+smp" in spec: - options.append("smp") - if "+tcp" in spec: - if 'backend=netlrts' not in spec: - # This is a Charm++ limitation; it would lead to a - # build error - raise InstallError( - "The +tcp variant requires " - "the backend=netlrts communication mechanism") - options.append("tcp") - if "+omp" in spec: - options.append("omp") - if "+pthreads" in spec: - options.append("pthreads") - if "+cuda" in spec: - options.append("cuda") - - if "+shared" in spec: - options.append("--build-shared") - if "+production" in spec: - options.append("--with-production") - if "+tracing" in spec: - options.append("--enable-tracing") - - # Call "make" via the build script - # Note: This builds Charm++ in the "tmp" subdirectory of the - # install directory. Maybe we could set up a symbolic link - # back to the build tree to prevent this? Alternatively, we - # could dissect the build script; the build instructions say - # this wouldn't be difficult. - build = Executable(join_path(".", "build")) - build(target, self.charmarch, *options) - - # Charm++'s install script does not copy files, it only creates - # symbolic links. Fix this. - for dirpath, dirnames, filenames in os.walk(builddir): - for filename in filenames: - filepath = join_path(dirpath, filename) - if os.path.islink(filepath): - tmppath = filepath + ".tmp" - # Skip dangling symbolic links - try: - copy(filepath, tmppath) - os.remove(filepath) - os.rename(tmppath, filepath) - except (IOError, OSError): - pass - - tmp_path = join_path(builddir, "tmp") - if not os.path.islink(tmp_path): - shutil.rmtree(tmp_path) - - if self.spec.satisfies('@6.9.99'): - # A broken 'doc' link in the prefix can break the build. - # Remove it and replace it if it is broken. - try: - os.stat(prefix.doc) - except OSError: - os.remove(prefix.doc) - mkdirp(prefix.doc) - - @run_after('install') - @on_package_attributes(run_tests=True) - def check_build(self): - make('-C', join_path(self.stage.source_path, 'tests'), - 'test', 'TESTOPTS=++local', parallel=False) - - def setup_dependent_build_environment(self, env, dependent_spec): - env.set('MPICC', self.prefix.bin.ampicc) - env.set('MPICXX', self.prefix.bin.ampicxx) - env.set('MPIF77', self.prefix.bin.ampif77) - env.set('MPIF90', self.prefix.bin.ampif90) - - def setup_dependent_package(self, module, dependent_spec): - self.spec.mpicc = self.prefix.bin.ampicc - self.spec.mpicxx = self.prefix.bin.ampicxx - self.spec.mpifc = self.prefix.bin.ampif90 - self.spec.mpif77 = self.prefix.bin.ampif77 - self.spec.charmarch = self.charmarch diff --git a/repo/packages/charmpp/shasta.patch.1 b/repo/packages/charmpp/shasta.patch.1 deleted file mode 100644 index 8694a1d9..00000000 --- a/repo/packages/charmpp/shasta.patch.1 +++ /dev/null @@ -1,932 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index efd18d2ba..afecf8e51 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -111,6 +111,8 @@ option(BUILD_SHARED "Build Charm++ dynamic libraries" OFF) - # Other options - option(EVERYLB "Compile EveryLB suite of load balancing strategies" OFF) - option(F90CHARM "Build f90charm" OFF) -+# LRTS PMI options -+set(LRTS_PMI "" CACHE STRING "PMI type for UCX and OFI layers, can be one of simplepmi, slurmpmi, slurmpmi2, or ompipmix") - - set(EXTRA_OPTS "" CACHE STRING "Extra flags to pass to compilers.") - add_compile_options(${EXTRA_OPTS}) -@@ -227,6 +229,14 @@ endif() - - set(CHARM_PLATFORM "${NETWORK}-${CHARM_OS}-${CHARM_CPU}") - -+set(CMK_BUILD_CRAY 0) -+if(${NETWORK} MATCHES "gni-" OR ${NETWORK} MATCHES "ofi-cray") -+ set(CHARM_PLATFORM "${NETWORK}") -+ set(CMK_BUILD_CRAY 1) -+elseif(${NETWORK} MATCHES "mpi-cray") -+ set(CHARM_PLATFORM "${NETWORK}") -+endif() -+ - set(CMK_BUILD_MPI 0) - set(CMK_BUILD_ON_MPI 0) - if(${NETWORK} STREQUAL "mpi") -@@ -346,6 +356,12 @@ set(CMK_F_OPENMP ${OpenMP_Fortran_FLAGS}) - - if(EXISTS ${CMAKE_SOURCE_DIR}/src/arch/${NETWORK}/gdir_link) - file(STRINGS src/arch/${NETWORK}/gdir_link GDIR) -+elseif(${NETWORK} MATCHES "gni-") -+ set(GDIR "gni") -+elseif(${NETWORK} MATCHES "mpi-cray") -+ set(GDIR "mpi") -+elseif(${NETWORK} MATCHES "ofi-cray") -+ set(GDIR "ofi") - else() - set(GDIR ${NETWORK}) - endif() -@@ -407,6 +423,11 @@ if(EXISTS ${CMAKE_SOURCE_DIR}/src/arch/${GDIR}/conv-mach-local.sh) - configure_file(src/arch/${GDIR}/conv-mach-local.h include/ COPYONLY) - endif() - -+if(LRTS_PMI) -+ configure_file(${CMAKE_SOURCE_DIR}/src/arch/${GDIR}/conv-mach-${LRTS_PMI}.sh include/ COPYONLY) -+ configure_file(${CMAKE_SOURCE_DIR}/src/arch/${GDIR}/conv-mach-${LRTS_PMI}.h include/ COPYONLY) -+endif() -+ - # Header files - configure_file(src/arch/${GDIR}/conv-common.h include/ COPYONLY) - configure_file(src/arch/${VDIR}/conv-mach.h include/ COPYONLY) -@@ -448,34 +469,35 @@ endforeach() - - - # proc_management --# file(MAKE_DIRECTORY include/proc_management/simple_pmi) -- --set(proc_management-sources --src/arch/util/proc_management/runtime-pmi.C --src/arch/util/proc_management/runtime-pmix.C --src/arch/util/proc_management/runtime-codec.h --src/arch/util/proc_management/runtime-pmi2.C --src/arch/util/proc_management/runtime.h --) -- --set(proc_management-simple_pmi-sources --src/arch/util/proc_management/simple_pmi/pmi.h --src/arch/util/proc_management/simple_pmi/mpl.h --src/arch/util/proc_management/simple_pmi/simple_pmi.C --src/arch/util/proc_management/simple_pmi/simple_pmiutil.C --src/arch/util/proc_management/simple_pmi/simple_pmiutil.h --) -- --# FIXME: these should be in include/proc_management --foreach(filename ${proc_management-sources}) -- configure_file(${filename} include/ COPYONLY) --endforeach() -- --# FIXME: these should be in include/proc_management/simple_pmi --foreach(filename ${proc_management-simple_pmi-sources}) -- configure_file(${filename} include/ COPYONLY) --endforeach() -- -+if(${NETWORK} MATCHES "ucx" OR ${NETWORK} MATCHES "ofi") -+ # file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/include/proc_management/simple_pmi) -+ -+ set(proc_management-sources -+ src/arch/util/proc_management/runtime-pmi.C -+ src/arch/util/proc_management/runtime-pmix.C -+ src/arch/util/proc_management/runtime-codec.h -+ src/arch/util/proc_management/runtime-pmi2.C -+ src/arch/util/proc_management/runtime.h -+ ) -+ -+ set(proc_management-simple_pmi-sources -+ src/arch/util/proc_management/simple_pmi/pmi.h -+ src/arch/util/proc_management/simple_pmi/mpl.h -+ src/arch/util/proc_management/simple_pmi/simple_pmi.C -+ src/arch/util/proc_management/simple_pmi/simple_pmiutil.C -+ src/arch/util/proc_management/simple_pmi/simple_pmiutil.h -+ ) -+ -+ # FIXME: this should be in include/proc_management/ -+ foreach(filename ${proc_management-sources}) -+ configure_file(${filename} include/ COPYONLY) -+ endforeach() -+ -+ # FIXME: this should be in include/proc_management/simple_pmi -+ foreach(filename ${proc_management-simple_pmi-sources}) -+ configure_file(${filename} include/ COPYONLY) -+ endforeach() -+endif() - - # Charmxi - add_subdirectory(src/xlat-i) -@@ -647,7 +669,10 @@ set(optfile_sh ${CMAKE_BINARY_DIR}/include/conv-mach-opt.sh) - file(WRITE ${optfile_sh} "# Build-time options header, automatically generated by cmake\n") - file(APPEND ${optfile_sh} "[ -z \"$CHARMINC\" ] && CHARMINC=\".\"\n") - --if(NOT ${NETWORK} STREQUAL "mpi") -+# This needs to appear before sourcing the cc-$compiler.sh file -+file(APPEND ${optfile_sh} "CMK_COMPILER_SUFFIX=${CMK_COMPILER_SUFFIX}\n") -+ -+if(NOT ${NETWORK} STREQUAL "mpi" AND NOT ${NETWORK} MATCHES "gni-" AND NOT ${NETWORK} MATCHES "-cray") - file(APPEND ${optfile_sh} ". ${CMAKE_BINARY_DIR}/include/cc-${CMK_COMPILER}.sh\n") - endif() - -@@ -673,6 +698,9 @@ endif() - file(APPEND ${optfile_sh} "CMK_HWLOC_LIBS=\"-lhwloc_embedded -lm\"\n" ) - file(APPEND ${optfile_sh} "CMK_LIBS=\"$CMK_LIBS -lz ${DL_LIB}\"\n") - -+if(LRTS_PMI) -+ file(APPEND ${optfile_sh} ". ${CMAKE_BINARY_DIR}/include/conv-mach-${LRTS_PMI}.sh\n") -+endif() - - # Create conv-mach-opt.h - set(optfile_h ${CMAKE_BINARY_DIR}/include/conv-mach-opt.h) -@@ -680,10 +708,14 @@ set(optfile_h ${CMAKE_BINARY_DIR}/include/conv-mach-opt.h) - file(WRITE ${optfile_h} "/* Build-time options header, automatically generated by cmake */\n") - file(APPEND ${optfile_h} "#define CMK_OPTIMIZE ${CMK_OPTIMIZE}\n") - --if(NOT ${NETWORK} STREQUAL "mpi") -+if(NOT ${NETWORK} STREQUAL "mpi" AND NOT ${NETWORK} MATCHES "gni-" AND NOT ${NETWORK} MATCHES "-cray") - file(APPEND ${optfile_h} "#include \"cc-${CMK_COMPILER}.h\"\n") - endif() - -+if(LRTS_PMI) -+ file(APPEND ${optfile_h} "#include \"conv-mach-${LRTS_PMI}.h\"\n") -+endif() -+ - # Create conv-mach-opt.mak - set(optfile_mak ${CMAKE_BINARY_DIR}/include/conv-mach-opt.mak) - -diff --git a/buildcmake b/buildcmake -index e38b7eb12..abc820486 100755 ---- a/buildcmake -+++ b/buildcmake -@@ -58,6 +58,7 @@ opt_lbtime_type="double" - opt_lbuserdata=0 - opt_libdir="" - opt_lockless=0 -+opt_lrts_pmi="" - opt_mempool_cutoff=26 - opt_network=0 - opt_numa=0 -@@ -102,6 +103,9 @@ while [[ $# -gt 0 ]]; do - pthreads) - opt_pthreads=1 - ;; -+ simplepmi|slurmpmi|slurmpmi2|ompipmix) -+ opt_lrts_pmi=$arg -+ ;; - # Compilers - gcc) - opt_CC=gcc -@@ -261,10 +265,38 @@ done - - ############ End option parsing - --opt_network=$(echo $triplet | cut -d '-' -f1) -+<<<<<<< HEAD -+# Build option setup - --[[ $opt_production -eq 0 ]] && opt_production='Debug' || opt_production='Release' -+# Special handling for gni-crayxc, gni-crayxe, mpi-crayxc, mpi-crayxe, mpi-crayshasta, ofi-crayshasta -+if [[ $actual_triplet == gni-* || $actual_triplet == *-cray* ]]; then -+ opt_network=$actual_triplet -+ # Need to use Cray's compiler frontends on Cray systems -+ opt_CC=cc -+ opt_CXX=CC -+ opt_FC=ftn -+else -+ opt_network=$(echo "$actual_triplet" | cut -d '-' -f1) -+fi -+ -+my_os=$(echo "$actual_triplet" | cut -d '-' -f2) -+ -+if [[ $opt_network == "mpi" && $my_os == "win" ]]; then -+ echo "Warning: CMake build is not supported with MPI on Windows, running ./buildold instead." -+ sleep 2 -+ "$my_srcdir/buildold" "${full_args[@]}" -+ exit $? -+fi -+ -+# Special handling for Windows compiler -+if [[ $my_os == "win" && ( -z $opt_CC || $opt_CC == "msvc" ) ]]; then -+ # Need to use unix2nt_cc on Windows/Cygwin -+ opt_CC="$(realpath "$my_srcdir")/src/arch/win/unix2nt_cc" -+ opt_CXX="$opt_CC" -+ opt_FC= -+fi - -+[[ $opt_production -eq 0 ]] && opt_production='Debug' || opt_production='Release' - - echo "Build options for $triplet:" - -@@ -275,11 +307,9 @@ done - - builddir=$triplet$opt_suffix - --rm -rf $builddir -- --mkdir $builddir -- --cd $builddir -+rm -rf "$builddir" -+mkdir -p "$builddir" -+cd "$builddir" - - if [[ -n $opt_libdir ]]; then - mkdir -p include -@@ -308,6 +338,7 @@ CC=$opt_CC CXX=$opt_CXX FC=$opt_FC cmake .. \ - -DLBTIME_TYPE="$opt_lbtime_type" \ - -DLBUSERDATA="$opt_lbuserdata" \ - -DLOCKLESS_QUEUE="$opt_lockless" \ -+ -DLRTS_PMI="$opt_lrts_pmi" \ - -DCMK_MEMPOOL_CUTOFFNUM="$opt_mempool_cutoff" \ - -DNETWORK="$opt_network" \ - -DNUMA="$opt_numa" \ -diff --git a/doc/charm++/manual.rst b/doc/charm++/manual.rst -index d1ecb491b..b0cb2dbbd 100644 ---- a/doc/charm++/manual.rst -+++ b/doc/charm++/manual.rst -@@ -10739,6 +10739,7 @@ appropriate choices for the build one wants to perform. - Cray XE6 ``./build charm++ gni-crayxe --with-production -j8`` - Cray XK7 ``./build charm++ gni-crayxe-cuda --with-production -j8`` - Cray XC40 ``./build charm++ gni-crayxc --with-production -j8`` -+ Cray Shasta ``./build charm++ ofi-crayshasta --with-production -j8`` - ================================================================ ===================================================================== - - As mentioned earlier, one can also build Charm++ using the precompiled -@@ -11196,6 +11197,13 @@ Parameters that function as boolean flags within Charmrun (taking no - other parameters) can be prefixed with "no-" to negate their effect. - For example, ``++no-scalable-start``. - -+.. note:: -+ -+ When running on OFI platforms such as Cray Shasta, the OFI runtime parameter -+ ``+ofi_runtime_tcp`` may be required. By default, the exchange of EP names at -+ startup is done via both PMI and OFI. With this flag, it is only done via -+ PMI. -+ - .. _command line options: - - Command Line Options -diff --git a/smart-build.pl b/smart-build.pl -index ac4cb3006..917d7573d 100755 ---- a/smart-build.pl -+++ b/smart-build.pl -@@ -130,7 +130,7 @@ if($skip_choosing eq "false"){ - } - - --# check for GNI -+# check for Cray - - if($skip_choosing eq "false"){ - my $craycc_found = index(`which CC 2>/dev/null`, "/opt/cray/") != -1; -@@ -140,11 +140,23 @@ if($skip_choosing eq "false"){ - $PE_PRODUCT_LIST = ""; - } - -+ my $CRAYPE_NETWORK_TARGET = $ENV{'CRAYPE_NETWORK_TARGET'}; -+ if (not defined $CRAYPE_NETWORK_TARGET) { -+ $CRAYPE_NETWORK_TARGET = ""; -+ } -+ - my $CRAY_UGNI_found = index(":$PE_PRODUCT_LIST:", ":CRAY_UGNI:") != -1; - - my $gni_found = $craycc_found || $CRAY_UGNI_found; - -- if ($gni_found) { -+ if ($CRAYPE_NETWORK_TARGET eq "ofi") { -+ print "\nI found that you have a Cray environment.\nDo you want to build Charm++ targeting Cray Shasta? [Y/n]: "; -+ my $p = promptUserYN(); -+ if($p eq "yes" || $p eq "default") { -+ $arch = "ofi-crayshasta"; -+ $skip_choosing = "true"; -+ } -+ } elsif ($gni_found) { - my $CRAYPE_INTERLAGOS_found = index(":$PE_PRODUCT_LIST:", ":CRAYPE_INTERLAGOS:") != -1; - if ($CRAYPE_INTERLAGOS_found) { - print "\nI found that you have a Cray environment with Interlagos processors.\nDo you want to build Charm++ targeting Cray XE? [Y/n]: "; -@@ -462,8 +474,10 @@ $explanations{"bigsim"} = "Compile Charm++ as running on the BigSim emulator"; - $explanations{"nolb"} = "Build without load balancing support"; - $explanations{"perftools"} = "Build with support for the Cray perftools"; - $explanations{"persistent"} = "Build the persistent communication interface"; -+$explanations{"simplepmi"} = "Use simple PMI for task launching"; - $explanations{"slurmpmi"} = "Use Slurm PMI for task launching"; - $explanations{"slurmpmi2"} = "Use Slurm PMI2 for task launching"; -+$explanations{"ompipmix"} = "Use Open MPI PMIX for task launching"; - $explanations{"tsan"} = "Compile Charm++ with support for Thread Sanitizer"; - - -diff --git a/src/arch/common/conv-mach-craype.sh b/src/arch/common/conv-mach-craype.sh -index 1630d7c5e..5c15cc032 100644 ---- a/src/arch/common/conv-mach-craype.sh -+++ b/src/arch/common/conv-mach-craype.sh -@@ -1,6 +1,7 @@ - - PGCC=`CC -V 2>&1 | grep pgCC` - ICPC=`CC -V 2>&1 | grep Intel` -+CLANG=`CC -V 2>&1 | grep 'clang'` - GNU=`CC -V 2>&1 | grep 'g++'` - CCE=`CC -V 2>&1 | grep 'Cray'` - -@@ -15,7 +16,12 @@ CMK_CPP_C_FLAGS="-E" - - CMK_LINK_BINARY='-dynamic' - --CMK_CRAY_LIBS="$CRAY_PMI_POST_LINK_OPTS $CRAY_UGNI_POST_LINK_OPTS -lugni -lpmi $CRAY_RCA_POST_LINK_OPTS" -+if test -v CMK_CRAY_NOGNI -+then -+ CMK_CRAY_LIBS="$CRAY_PMI_POST_LINK_OPTS -lpmi $CRAY_RCA_POST_LINK_OPTS" -+else -+ CMK_CRAY_LIBS="$CRAY_PMI_POST_LINK_OPTS $CRAY_UGNI_POST_LINK_OPTS -lugni -lpmi $CRAY_RCA_POST_LINK_OPTS" -+fi - CMK_LIBS="-lckqt $CMK_CRAY_LIBS" - - CMK_LD_LIBRARY_PATH="-Wl,-rpath,$CHARMLIBSO/" -@@ -42,6 +48,11 @@ then - CMK_SEQ_CC="icc -fPIC " - CMK_SEQ_CXX="icpc -fPIC " - CMK_COMPILER='icc' -+elif test -n "$CLANG" -+then -+CMK_SEQ_CC="clang -fPIC " -+CMK_SEQ_CXX="clang++ -fPIC " -+CMK_COMPILER='clang' - else # gcc - CMK_SEQ_CC="gcc -fPIC" - CMK_SEQ_CXX="g++ -fPIC " -diff --git a/src/arch/mpi-crayshasta/conv-mach-smp.h b/src/arch/mpi-crayshasta/conv-mach-smp.h -new file mode 100644 -index 000000000..5913bf2c9 ---- /dev/null -+++ b/src/arch/mpi-crayshasta/conv-mach-smp.h -@@ -0,0 +1,7 @@ -+#define CMK_SMP 1 -+ -+ -+#undef CMK_SHARED_VARS_UNAVAILABLE -+#undef CMK_SHARED_VARS_POSIX_THREADS_SMP -+#define CMK_SHARED_VARS_UNAVAILABLE 0 -+#define CMK_SHARED_VARS_POSIX_THREADS_SMP 1 -diff --git a/src/arch/mpi-crayshasta/conv-mach-smp.sh b/src/arch/mpi-crayshasta/conv-mach-smp.sh -new file mode 100644 -index 000000000..2262eaacf ---- /dev/null -+++ b/src/arch/mpi-crayshasta/conv-mach-smp.sh -@@ -0,0 +1,3 @@ -+CMK_DEFS="$CMK_DEFS -D_REENTRANT" -+CMK_LIBS="-lpthread $CMK_LIBS " -+CMK_SMP="1" -diff --git a/src/arch/mpi-crayshasta/conv-mach.h b/src/arch/mpi-crayshasta/conv-mach.h -new file mode 100644 -index 000000000..1a2b90178 ---- /dev/null -+++ b/src/arch/mpi-crayshasta/conv-mach.h -@@ -0,0 +1,52 @@ -+ -+#ifndef _CONV_MACH_H -+#define _CONV_MACH_H -+ -+#define CMK_CONVERSE_MPI 1 -+ -+#define CMK_MEMORY_PREALLOCATE_HACK 0 -+ -+#define CMK_DEFAULT_MAIN_USES_COMMON_CODE 1 -+ -+#define CMK_MALLOC_USE_GNU_MALLOC 0 -+#define CMK_MALLOC_USE_OS_BUILTIN 1 -+ -+#define CMI_IO_BUFFER_EXPLICIT 1 -+#define CMI_IO_FLUSH_USER 1 -+ -+#define CMK_GETPAGESIZE_AVAILABLE 1 -+#define CMK_MEMORY_PAGESIZE 4096 -+#define CMK_MEMORY_PROTECTABLE 0 -+ -+ -+#define CMK_SHARED_VARS_UNAVAILABLE 1 -+ -+#define CMK_SIGNAL_NOT_NEEDED 0 -+#define CMK_SIGNAL_USE_SIGACTION 0 -+#define CMK_SIGNAL_USE_SIGACTION_WITH_RESTART 1 -+ -+#define CMK_THREADS_USE_CONTEXT 0 -+#define CMK_THREADS_USE_FCONTEXT 1 -+#define CMK_THREADS_USE_JCONTEXT 0 -+#define CMK_THREADS_USE_PTHREADS 0 -+ -+#define CMK_TIMER_USE_GETRUSAGE 0 -+#define CMK_TIMER_USE_SPECIAL 1 -+#define CMK_TIMER_USE_TIMES 0 -+ -+ -+#define CMK_WHEN_PROCESSOR_IDLE_BUSYWAIT 1 -+#define CMK_WHEN_PROCESSOR_IDLE_USLEEP 0 -+ -+#define CMK_64BIT 1 -+#define CMK_AMD64 1 -+ -+#define CMK_WEB_MODE 1 -+#define CMK_DEBUG_MODE 0 -+ -+#define CMK_LBDB_ON 1 -+ -+#define CMK_DISABLE_SYNC 1 -+ -+#endif -+ -diff --git a/src/arch/mpi-crayshasta/conv-mach.sh b/src/arch/mpi-crayshasta/conv-mach.sh -new file mode 100644 -index 000000000..ba4bddb91 ---- /dev/null -+++ b/src/arch/mpi-crayshasta/conv-mach.sh -@@ -0,0 +1,23 @@ -+# Cray Shasta build. October 2021. -+# CRAY COMPILER (CCE) BUILD -+# ======================================== -+# module load PrgEnv-cray # typically default -+# -+# INTEL BUILD -+# ================================ -+# module swap PrgEnv-cray PrgEnv-intel -+# -+# GCC BUILD -+# ================================ -+# module swap PrgEnv-cray PrgEnv-gnu -+# -+# # Build command is the same regardless of compiler environment: -+# -+# # MPI build -+# ./build charm++ mpi-crayshasta smp --with-production -+ -+CMK_BUILD_CRAY=1 -+ -+CMK_CRAY_NOGNI=1 -+ -+. $CHARMINC/conv-mach-craype.sh -diff --git a/src/arch/ofi-crayshasta/conv-mach-smp.h b/src/arch/ofi-crayshasta/conv-mach-smp.h -new file mode 100644 -index 000000000..f72decc97 ---- /dev/null -+++ b/src/arch/ofi-crayshasta/conv-mach-smp.h -@@ -0,0 +1,12 @@ -+#define CMK_SMP 1 -+ -+ -+#undef CMK_SHARED_VARS_UNAVAILABLE -+#undef CMK_SHARED_VARS_POSIX_THREADS_SMP -+#define CMK_SHARED_VARS_UNAVAILABLE 0 -+#define CMK_SHARED_VARS_POSIX_THREADS_SMP 1 -+ -+#undef CMK_TIMER_USE_GETRUSAGE -+#undef CMK_TIMER_USE_SPECIAL -+#define CMK_TIMER_USE_GETRUSAGE 1 -+#define CMK_TIMER_USE_SPECIAL 0 -diff --git a/src/arch/ofi-crayshasta/conv-mach-smp.sh b/src/arch/ofi-crayshasta/conv-mach-smp.sh -new file mode 100644 -index 000000000..7c2eadc6b ---- /dev/null -+++ b/src/arch/ofi-crayshasta/conv-mach-smp.sh -@@ -0,0 +1,3 @@ -+CMK_DEFS="$CMK_DEFS -D_REENTRANT" -+CMK_LIBS=" -lpthread $CMK_LIBS " -+CMK_SMP='1' -diff --git a/src/arch/ofi-crayshasta/conv-mach.h b/src/arch/ofi-crayshasta/conv-mach.h -new file mode 100644 -index 000000000..61d295df3 ---- /dev/null -+++ b/src/arch/ofi-crayshasta/conv-mach.h -@@ -0,0 +1,89 @@ -+#ifndef _CONV_MACH_H -+#define _CONV_MACH_H -+ -+#define CMK_OFI 1 -+ -+/* define the default linker, together with its options */ -+#define CMK_DLL_CC "g++ -shared -O3 -o " -+ -+/* 1 if the machine has a function called "getpagesize()", 0 otherwise . -+ used in the memory files of converse */ -+#define CMK_GETPAGESIZE_AVAILABLE 1 -+ -+/* defines which version of memory handlers should be used. -+ used in conv-core/machine.C */ -+#define CMK_MALLOC_USE_GNU_MALLOC 0 -+#define CMK_MALLOC_USE_OS_BUILTIN 1 -+ -+#define CMK_MEMORY_PAGESIZE 4096 -+#define CMK_MEMORY_PROTECTABLE 1 -+ -+/* the following definitions set the type of shared variables to be used. only -+ one of them must be 1, all the others 0. The different implementations are in -+ converse.h. Typically used are UNAVAILABLE for non SMP versions and -+ POSIX_THREADS_SMP for SMP versions. The others are used only in special -+ cases: NT_THREADS for Windows. */ -+#define CMK_SHARED_VARS_UNAVAILABLE 1 /* non SMP versions */ -+#define CMK_SHARED_VARS_POSIX_THREADS_SMP 0 /* SMP versions */ -+#define CMK_SHARED_VARS_NT_THREADS 0 -+ -+/* the following define if signal handlers should be used, both equal to zero -+ means that signals will not be used. only one of the following can be 1, the -+ other must be 0. they differ in the fact that the second (_WITH_RESTART) -+ enables retry on interrupt (a function is recalled upon interrupt and does -+ not return EINTR as in the first case) */ -+#define CMK_SIGNAL_USE_SIGACTION 0 -+#define CMK_SIGNAL_USE_SIGACTION_WITH_RESTART 1 -+ -+/* specifies whether the CthCpv variables should be defined as Cpv (0) or -+ directly as normal c variables (1) */ -+#define CMK_THREADS_REQUIRE_NO_CPV 0 -+ -+/* decide which is the default implementation of the threads (see threads.C) -+ Only one of the following can be 1. If none of them is selected, qthreads -+ will be used as default. This default can be overwritten at compile time -+ using -DCMK_THREADS_BUILD_"type"=1 */ -+#define CMK_THREADS_USE_CONTEXT 0 -+#define CMK_THREADS_USE_FCONTEXT 1 -+#define CMK_THREADS_USE_JCONTEXT 0 -+#define CMK_THREADS_USE_PTHREADS 0 -+ -+/* Specifies what kind of timer to use, and the correspondent headers will be -+ included in convcore.C. If none is selected, then the machine.C file needs to -+ implement the timer primitives. */ -+#define CMK_TIMER_USE_RTC 0 -+#define CMK_TIMER_USE_RDTSC 0 -+#define CMK_TIMER_USE_GETRUSAGE 1 -+#define CMK_TIMER_USE_SPECIAL 0 -+#define CMK_TIMER_USE_TIMES 0 -+#define CMK_TIMER_USE_BLUEGENEL 0 -+ -+/* Specifies what the processor will do when it is idle, either sleep (1) or go -+ into busy waiting mode (0). In convcore.C there are a few files included if -+ sleeping mode, but the real distinct implementation is in the machine.C -+ file. */ -+#define CMK_WHEN_PROCESSOR_IDLE_USLEEP 0 -+ -+/* specifies whether there is a web server collecting utilization statistics (1) -+ or not (0) */ -+#define CMK_WEB_MODE 1 -+ -+#define CMK_DEBUG_MODE 0 -+ -+/* enables the load balancer framework. set to 1 for almost all the machines */ -+#define CMK_LBDB_ON 1 -+ -+#define CMK_64BIT 1 -+#define CMK_AMD64 1 -+ -+/* Other possible definitions: -+ -+In fault tolerant architectures, CK_MEM_CHECKPOINT can be set. In this case the -+extended header must contain also another field called "pn" (phase number). -+ -+*/ -+ -+/* Use PMI2 by default on Cray systems with cray-pmi */ -+#include "conv-mach-slurmpmi2.h" -+ -+#endif -diff --git a/src/arch/ofi-crayshasta/conv-mach.sh b/src/arch/ofi-crayshasta/conv-mach.sh -new file mode 100644 -index 000000000..8c9699491 ---- /dev/null -+++ b/src/arch/ofi-crayshasta/conv-mach.sh -@@ -0,0 +1,31 @@ -+CMK_BUILD_CRAY=1 -+CMK_CRAY_NOGNI=1 -+. $CHARMINC/conv-mach-craype.sh -+ -+# For libfabric -+#If the user doesn't pass --basedir, use defaults for libfabric headers and library -+if test -z "$USER_OPTS_LD" -+then -+ if test -z "$LIBFABRIC" -+ then -+ CMK_INCDIR="$CMK_INCDIR -I/usr/include/" -+ CMK_LIBDIR="$CMK_LIBDIR -L/usr/lib64/" -+ else -+ CMK_INCDIR="$CMK_INCDIR -I$LIBFABRIC/include/" -+ CMK_LIBDIR="$CMK_LIBDIR -L$LIBFABRIC/lib64/" -+ fi -+fi -+ -+# For cray-pmi -+if test -n "$CRAY_PMI_PREFIX" -+then -+ CMK_INCDIR="$CMK_INCDIR -I$CRAY_PMI_PREFIX/include" -+ CMK_LIBDIR="$CMK_LIBDIR -L$CRAY_PMI_PREFIX/lib" -+fi -+ -+CMK_LIBS="$CMK_LIBS -lfabric" -+# Use PMI2 by default on Cray systems with cray-pmi -+. $CHARMINC/conv-mach-slurmpmi2.sh -+ -+# For runtime -+CMK_INCDIR="$CMK_INCDIR -I./proc_management/" -diff --git a/src/arch/ofi-linux-x86_64/conv-mach-slurmpmi2.h b/src/arch/ofi-linux-x86_64/conv-mach-slurmpmi2.h -deleted file mode 100644 -index 4c40206f3..000000000 ---- a/src/arch/ofi-linux-x86_64/conv-mach-slurmpmi2.h -+++ /dev/null -@@ -1,4 +0,0 @@ --#undef CMK_USE_PMI --#undef CMK_USE_PMI2 --#undef CMK_USE_SIMPLEPMI --#define CMK_USE_PMI2 1 -diff --git a/src/arch/ofi-linux-x86_64/conv-mach.h b/src/arch/ofi-linux-x86_64/conv-mach.h -index 57b4e77de..938d06c4d 100644 ---- a/src/arch/ofi-linux-x86_64/conv-mach.h -+++ b/src/arch/ofi-linux-x86_64/conv-mach.h -@@ -85,19 +85,4 @@ extended header must contain also another field called "pn" (phase number). - - */ - --/* -- * Specifies which version of PMI to use. -- * See src/arch/ofi/machine.C -- */ --#define CMK_USE_PMI 1 --#define CMK_USE_PMI2 0 -- --/* -- * Use Simple client-side implementation of PMI. -- * Valid only for CMK_USE_PMI. -- * Optional in an SLURM environment. -- * See src/arch/util/proc_management/simple_pmi/ -- */ --#define CMK_USE_SIMPLEPMI 1 -- - #endif -diff --git a/src/arch/ofi/conv-common.h b/src/arch/ofi/conv-common.h -index b459d7d13..3554df202 100644 ---- a/src/arch/ofi/conv-common.h -+++ b/src/arch/ofi/conv-common.h -@@ -86,3 +86,19 @@ - #define CMK_REG_REQUIRED CMK_ONESIDED_IMPL - - #define CMK_CONVERSE_MPI 0 -+ -+/* -+ * Specifies which version of PMI to use. -+ * See src/arch/ofi/machine.C -+ */ -+#define CMK_USE_PMI 1 -+#define CMK_USE_PMI2 0 -+#define CMK_USE_PMIX 0 -+ -+/* -+ * Use Simple client-side implementation of PMI. -+ * Valid only for CMK_USE_PMI. -+ * Optional in an SLURM environment. -+ * See src/arch/util/proc_management/simple_pmi/ -+ */ -+#define CMK_USE_SIMPLEPMI 1 -diff --git a/src/arch/ucx-linux-arm8/conv-mach-ompipmix.h b/src/arch/ofi/conv-mach-ompipmix.h -similarity index 100% -rename from src/arch/ucx-linux-arm8/conv-mach-ompipmix.h -rename to src/arch/ofi/conv-mach-ompipmix.h -diff --git a/src/arch/ucx-linux-arm8/conv-mach-ompipmix.sh b/src/arch/ofi/conv-mach-ompipmix.sh -similarity index 100% -rename from src/arch/ucx-linux-arm8/conv-mach-ompipmix.sh -rename to src/arch/ofi/conv-mach-ompipmix.sh -diff --git a/src/arch/ofi/conv-mach-simplepmi.h b/src/arch/ofi/conv-mach-simplepmi.h -new file mode 100644 -index 000000000..e66aeb56f ---- /dev/null -+++ b/src/arch/ofi/conv-mach-simplepmi.h -@@ -0,0 +1,5 @@ -+#undef CMK_USE_PMI -+#undef CMK_USE_PMI2 -+#undef CMK_USE_PMIX -+#undef CMK_USE_SIMPLEPMI -+#define CMK_USE_SIMPLEPMI 1 -diff --git a/src/arch/ofi/conv-mach-simplepmi.sh b/src/arch/ofi/conv-mach-simplepmi.sh -new file mode 100644 -index 000000000..e69de29bb -diff --git a/src/arch/ofi-linux-x86_64/conv-mach-slurmpmi.h b/src/arch/ofi/conv-mach-slurmpmi.h -similarity index 85% -rename from src/arch/ofi-linux-x86_64/conv-mach-slurmpmi.h -rename to src/arch/ofi/conv-mach-slurmpmi.h -index 003f21c9f..c9f6ca513 100644 ---- a/src/arch/ofi-linux-x86_64/conv-mach-slurmpmi.h -+++ b/src/arch/ofi/conv-mach-slurmpmi.h -@@ -1,4 +1,5 @@ - #undef CMK_USE_PMI - #undef CMK_USE_PMI2 -+#undef CMK_USE_PMIX - #undef CMK_USE_SIMPLEPMI - #define CMK_USE_PMI 1 -diff --git a/src/arch/ofi-linux-x86_64/conv-mach-slurmpmi.sh b/src/arch/ofi/conv-mach-slurmpmi.sh -similarity index 100% -rename from src/arch/ofi-linux-x86_64/conv-mach-slurmpmi.sh -rename to src/arch/ofi/conv-mach-slurmpmi.sh -diff --git a/src/arch/ucx-linux-arm8/conv-mach-slurmpmi2.h b/src/arch/ofi/conv-mach-slurmpmi2.h -similarity index 85% -rename from src/arch/ucx-linux-arm8/conv-mach-slurmpmi2.h -rename to src/arch/ofi/conv-mach-slurmpmi2.h -index 4c40206f3..c3211b1a4 100644 ---- a/src/arch/ucx-linux-arm8/conv-mach-slurmpmi2.h -+++ b/src/arch/ofi/conv-mach-slurmpmi2.h -@@ -1,4 +1,5 @@ - #undef CMK_USE_PMI - #undef CMK_USE_PMI2 -+#undef CMK_USE_PMIX - #undef CMK_USE_SIMPLEPMI - #define CMK_USE_PMI2 1 -diff --git a/src/arch/ofi-linux-x86_64/conv-mach-slurmpmi2.sh b/src/arch/ofi/conv-mach-slurmpmi2.sh -similarity index 100% -rename from src/arch/ofi-linux-x86_64/conv-mach-slurmpmi2.sh -rename to src/arch/ofi/conv-mach-slurmpmi2.sh -diff --git a/src/arch/ofi/machine.C b/src/arch/ofi/machine.C -index 934f6ae34..77645c981 100644 ---- a/src/arch/ofi/machine.C -+++ b/src/arch/ofi/machine.C -@@ -92,10 +92,12 @@ - #include "request.h" - - /* Runtime to exchange EP addresses during LrtsInit() */ --#if CMK_USE_PMI -+#if CMK_USE_PMI || CMK_USE_SIMPLEPMI - #include "runtime-pmi.C" - #elif CMK_USE_PMI2 - #include "runtime-pmi2.C" -+#elif CMK_USE_PMIX -+#include "runtime-pmix.C" - #endif - - #define USE_MEMPOOL 0 -@@ -1628,7 +1630,7 @@ int fill_av_ofi(int myid, - OFI_OP_NAMES, - &epnames_contexts[i]); - if (ret) { -- CmiAbort("OFI::LrtsInit::fi_tsend error"); -+ CmiAbort("OFI::LrtsInit::fi_tsend error (+ofi_runtime_tcp may be needed)"); - } - } - -diff --git a/src/arch/ucx-linux-arm8/conv-mach-slurmpmi.h b/src/arch/ucx-linux-arm8/conv-mach-slurmpmi.h -deleted file mode 100644 -index 003f21c9f..000000000 ---- a/src/arch/ucx-linux-arm8/conv-mach-slurmpmi.h -+++ /dev/null -@@ -1,4 +0,0 @@ --#undef CMK_USE_PMI --#undef CMK_USE_PMI2 --#undef CMK_USE_SIMPLEPMI --#define CMK_USE_PMI 1 -diff --git a/src/arch/ucx-linux-arm8/conv-mach.h b/src/arch/ucx-linux-arm8/conv-mach.h -index c4902c602..b4796757d 100644 ---- a/src/arch/ucx-linux-arm8/conv-mach.h -+++ b/src/arch/ucx-linux-arm8/conv-mach.h -@@ -78,12 +78,6 @@ - #define CMK_64BIT 1 - #define CMK_AMD64 0 - --/* By default use simple PMI */ --#define CMK_USE_PMI 1 --#define CMK_USE_SIMPLEPMI 1 --#define CMK_USE_PMI2 0 --#define CMK_USE_PMIX 0 -- - /* Other possible definitions: - - In fault tolerant architectures, CK_MEM_CHECKPOINT can be set. In this case the -diff --git a/src/arch/ucx-linux-x86_64/conv-mach-slurmpmi.sh b/src/arch/ucx-linux-x86_64/conv-mach-slurmpmi.sh -deleted file mode 100644 -index 512c4e72b..000000000 ---- a/src/arch/ucx-linux-x86_64/conv-mach-slurmpmi.sh -+++ /dev/null -@@ -1,2 +0,0 @@ --CMK_INCDIR="$CMK_INCDIR -I/usr/include/slurm/" --CMK_LIBS="$CMK_LIBS -lpmi" -diff --git a/src/arch/ucx-linux-x86_64/conv-mach-slurmpmi2.sh b/src/arch/ucx-linux-x86_64/conv-mach-slurmpmi2.sh -deleted file mode 100644 -index bb61bd872..000000000 ---- a/src/arch/ucx-linux-x86_64/conv-mach-slurmpmi2.sh -+++ /dev/null -@@ -1,2 +0,0 @@ --CMK_INCDIR="$CMK_INCDIR -I/usr/include/slurm/" --CMK_LIBS="$CMK_LIBS -lpmi2" -diff --git a/src/arch/ucx-linux-x86_64/conv-mach.h b/src/arch/ucx-linux-x86_64/conv-mach.h -index 55fc8e6d6..138b370d6 100644 ---- a/src/arch/ucx-linux-x86_64/conv-mach.h -+++ b/src/arch/ucx-linux-x86_64/conv-mach.h -@@ -78,12 +78,6 @@ - #define CMK_64BIT 1 - #define CMK_AMD64 1 - --/* By default use simple PMI */ --#define CMK_USE_PMI 1 --#define CMK_USE_SIMPLEPMI 1 --#define CMK_USE_PMI2 0 --#define CMK_USE_PMIX 0 -- - /* Other possible definitions: - - In fault tolerant architectures, CK_MEM_CHECKPOINT can be set. In this case the -diff --git a/src/arch/ucx/conv-common.h b/src/arch/ucx/conv-common.h -index c585d1213..8a7bba2e7 100644 ---- a/src/arch/ucx/conv-common.h -+++ b/src/arch/ucx/conv-common.h -@@ -86,3 +86,9 @@ - - #undef CMK_HAS_CMA - #define CMK_HAS_CMA 0 -+ -+/* By default use simple PMI */ -+#define CMK_USE_PMI 1 -+#define CMK_USE_SIMPLEPMI 1 -+#define CMK_USE_PMI2 0 -+#define CMK_USE_PMIX 0 -diff --git a/src/arch/ucx-linux-x86_64/conv-mach-ompipmix.h b/src/arch/ucx/conv-mach-ompipmix.h -similarity index 100% -rename from src/arch/ucx-linux-x86_64/conv-mach-ompipmix.h -rename to src/arch/ucx/conv-mach-ompipmix.h -diff --git a/src/arch/ucx-linux-x86_64/conv-mach-ompipmix.sh b/src/arch/ucx/conv-mach-ompipmix.sh -similarity index 100% -rename from src/arch/ucx-linux-x86_64/conv-mach-ompipmix.sh -rename to src/arch/ucx/conv-mach-ompipmix.sh -diff --git a/src/arch/ucx/conv-mach-simplepmi.h b/src/arch/ucx/conv-mach-simplepmi.h -new file mode 100644 -index 000000000..e66aeb56f ---- /dev/null -+++ b/src/arch/ucx/conv-mach-simplepmi.h -@@ -0,0 +1,5 @@ -+#undef CMK_USE_PMI -+#undef CMK_USE_PMI2 -+#undef CMK_USE_PMIX -+#undef CMK_USE_SIMPLEPMI -+#define CMK_USE_SIMPLEPMI 1 -diff --git a/src/arch/ucx/conv-mach-simplepmi.sh b/src/arch/ucx/conv-mach-simplepmi.sh -new file mode 100644 -index 000000000..e69de29bb -diff --git a/src/arch/ucx-linux-x86_64/conv-mach-slurmpmi.h b/src/arch/ucx/conv-mach-slurmpmi.h -similarity index 85% -rename from src/arch/ucx-linux-x86_64/conv-mach-slurmpmi.h -rename to src/arch/ucx/conv-mach-slurmpmi.h -index 003f21c9f..c9f6ca513 100644 ---- a/src/arch/ucx-linux-x86_64/conv-mach-slurmpmi.h -+++ b/src/arch/ucx/conv-mach-slurmpmi.h -@@ -1,4 +1,5 @@ - #undef CMK_USE_PMI - #undef CMK_USE_PMI2 -+#undef CMK_USE_PMIX - #undef CMK_USE_SIMPLEPMI - #define CMK_USE_PMI 1 -diff --git a/src/arch/ucx-linux-arm8/conv-mach-slurmpmi.sh b/src/arch/ucx/conv-mach-slurmpmi.sh -similarity index 100% -rename from src/arch/ucx-linux-arm8/conv-mach-slurmpmi.sh -rename to src/arch/ucx/conv-mach-slurmpmi.sh -diff --git a/src/arch/ucx-linux-x86_64/conv-mach-slurmpmi2.h b/src/arch/ucx/conv-mach-slurmpmi2.h -similarity index 85% -rename from src/arch/ucx-linux-x86_64/conv-mach-slurmpmi2.h -rename to src/arch/ucx/conv-mach-slurmpmi2.h -index 4c40206f3..c3211b1a4 100644 ---- a/src/arch/ucx-linux-x86_64/conv-mach-slurmpmi2.h -+++ b/src/arch/ucx/conv-mach-slurmpmi2.h -@@ -1,4 +1,5 @@ - #undef CMK_USE_PMI - #undef CMK_USE_PMI2 -+#undef CMK_USE_PMIX - #undef CMK_USE_SIMPLEPMI - #define CMK_USE_PMI2 1 -diff --git a/src/arch/ucx-linux-arm8/conv-mach-slurmpmi2.sh b/src/arch/ucx/conv-mach-slurmpmi2.sh -similarity index 100% -rename from src/arch/ucx-linux-arm8/conv-mach-slurmpmi2.sh -rename to src/arch/ucx/conv-mach-slurmpmi2.sh -diff --git a/src/arch/ucx/machine.C b/src/arch/ucx/machine.C -index 285c768aa..063c1c729 100644 ---- a/src/arch/ucx/machine.C -+++ b/src/arch/ucx/machine.C -@@ -21,7 +21,7 @@ - #include - #include - --#if CMK_USE_PMI -+#if CMK_USE_PMI || CMK_USE_SIMPLEPMI - #include "runtime-pmi.C" - #elif CMK_USE_PMI2 - #include "runtime-pmi2.C" -diff --git a/src/scripts/configure.ac b/src/scripts/configure.ac -index 76b294e89..66d8430cc 100644 ---- a/src/scripts/configure.ac -+++ b/src/scripts/configure.ac -@@ -1529,7 +1529,7 @@ int main(int argc, char **argv) - return 0; - } - EOT --test_cc "whether build on OFI" "yes" "no" "-lfabric" -+test_cc "whether build on OFI" "yes" "no" - AC_DEFINE_UNQUOTED(CMK_BUILD_ON_OFI, $strictpass, [build OFI.]) - BUILD_OFI=$strictpass - -diff --git a/src/util/ckBIconfig.h b/src/util/ckBIconfig.h -index 6a38afab1..765d020c4 100644 ---- a/src/util/ckBIconfig.h -+++ b/src/util/ckBIconfig.h -@@ -6,7 +6,7 @@ - - #ifndef CK_BI_CONFIG - #define CK_BI_CONFIG --#ifdef CMK_BALANCED_INJECTION_API -+#if defined(CMK_BALANCED_INJECTION_API) && CMK_BALANCED_INJECTION_API - #include - #include - diff --git a/repo/packages/charmpp/strictpass.patch b/repo/packages/charmpp/strictpass.patch deleted file mode 100644 index 44aa4fbd..00000000 --- a/repo/packages/charmpp/strictpass.patch +++ /dev/null @@ -1,16 +0,0 @@ ---- old/src/scripts/configure -+++ new/src/scripts/configure -@@ -2146,13 +2146,6 @@ - test_result $? "$1" "$2" "$3" - strictpass=$pass - strictfail=$fail -- if test $pass -eq 1 -- then -- if cat out | grep -i "warn" > /dev/null 2>&1 -- then -- strictpass="0" && strictfail="1" -- fi -- fi - cat out >> $charmout - /bin/rm -f out - } diff --git a/repo/packages/chgcentre/main.patch b/repo/packages/chgcentre/main.patch deleted file mode 100644 index fbc7cd06..00000000 --- a/repo/packages/chgcentre/main.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/main.cpp 2022-05-02 15:00:00 +0800 -+++ b/main.cpp 2022-05-02 15:01:00 +0800 -@@ -415,7 +415,7 @@ - MDirection::Ref(MDirection::J2000))(); - std::vector uvws(antennas.size()); - MEpoch time(MVEpoch(-1.0)); -- for(unsigned row=0; row!=std::min(set.nrow(),50u); ++row) -+ for(unsigned row=0; row!=std::min(static_cast(set.nrow()),50u); ++row) - { - if(fieldIdCol(row) == fieldIndex) - { diff --git a/repo/packages/chgcentre/package.py b/repo/packages/chgcentre/package.py deleted file mode 100644 index 180ea2d8..00000000 --- a/repo/packages/chgcentre/package.py +++ /dev/null @@ -1,22 +0,0 @@ -# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# Contribute the patch -from spack.package import * - -class Chgcentre(CMakePackage): - """ - The chgcentre tool can be used - to change the phase centre of a measurement set. - """ - - homepage = "https://sourceforge.net/p/wsclean/wiki/chgcentre/" - url = "https://downloads.sourceforge.net/project/wsclean/chgcentre-1.6/chgcentre-1.6.tar.bz2" - - version('1.6', sha256='5b14f9f56b900072c42dab2a8217cd399fb1bb50aae20f9e3b6ff30ec5b12008') - - depends_on('casacore') - depends_on('gsl') - patch('main.patch') - From 1b2132bf34005d599f37482b859e91275ec6dc08 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 11:00:16 +0800 Subject: [PATCH 05/21] cp2k already contributed. --- repo/packages/cp2k/package.py | 771 ------------------------ repo/packages/cp2k/posix_c_source.patch | 12 - 2 files changed, 783 deletions(-) delete mode 100644 repo/packages/cp2k/package.py delete mode 100644 repo/packages/cp2k/posix_c_source.patch diff --git a/repo/packages/cp2k/package.py b/repo/packages/cp2k/package.py deleted file mode 100644 index 4031598c..00000000 --- a/repo/packages/cp2k/package.py +++ /dev/null @@ -1,771 +0,0 @@ -# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# ======================================================================= -# PAWSEY ADDITIONS -# ======================================================================= -# This is a version of the recipe coming from the later 0.21.0-dev Spack -# version. It will allow us to have the latest versions. -# Already contributed -import copy -import os -import os.path - -import spack.util.environment -from spack.package import * - - -class Cp2k(MakefilePackage, CudaPackage): - """CP2K is a quantum chemistry and solid state physics software package - that can perform atomistic simulations of solid state, liquid, molecular, - periodic, material, crystal, and biological systems - """ - - homepage = "https://www.cp2k.org" - url = "https://github.com/cp2k/cp2k/releases/download/v3.0.0/cp2k-3.0.tar.bz2" - git = "https://github.com/cp2k/cp2k.git" - list_url = "https://github.com/cp2k/cp2k/releases" - - # maintainers("dev-zero") - - version("2023.1", sha256="dff343b4a80c3a79363b805429bdb3320d3e1db48e0ff7d20a3dfd1c946a51ce") - version("2022.2", sha256="1a473dea512fe264bb45419f83de432d441f90404f829d89cbc3a03f723b8354") - version("2022.1", sha256="2c34f1a7972973c62d471cd35856f444f11ab22f2ff930f6ead20f3454fd228b") - version("9.1", sha256="fedb4c684a98ad857cd49b69a3ae51a73f85a9c36e9cb63e3b02320c74454ce6") - version("8.2", sha256="2e24768720efed1a5a4a58e83e2aca502cd8b95544c21695eb0de71ed652f20a") - version("8.1", sha256="7f37aead120730234a60b2989d0547ae5e5498d93b1e9b5eb548c041ee8e7772") - version("7.1", sha256="ccd711a09a426145440e666310dd01cc5772ab103493c4ae6a3470898cd0addb") - version("6.1", sha256="af803558e0a6b9e9d9ce8a3ab955ba32bacd179922455424e061c82c9fefa34b") - version("5.1", sha256="e23613b593354fa82e0b8410e17d94c607a0b8c6d9b5d843528403ab09904412") - version("4.1", sha256="4a3e4a101d8a35ebd80a9e9ecb02697fb8256364f1eccdbe4e5a85d31fe21343") - version("3.0", sha256="1acfacef643141045b7cbade7006f9b7538476d861eeecd9658c9e468dc61151") - version("master", branch="master", submodules="True") - - variant("mpi", default=True, description="Enable MPI support") - variant("openmp", default=True, description="Enable OpenMP support") - variant( - "smm", - default="libxsmm", - values=("libxsmm", "libsmm", "blas"), - description="Library for small matrix multiplications", - ) - variant("plumed", default=False, description="Enable PLUMED support") - variant( - "libint", default=True, description="Use libint, required for HFX (and possibly others)" - ) - variant("libxc", default=True, description="Support additional functionals via libxc") - variant( - "pexsi", - default=False, - description=("Enable the alternative PEXSI method" "for density matrix evaluation"), - ) - variant( - "elpa", - default=False, - description="Enable optimised diagonalisation routines from ELPA", - when="@6.1:", - ) - variant( - "sirius", - default=False, - description=("Enable planewave electronic structure" " calculations via SIRIUS"), - ) - variant("cosma", default=False, description="Use COSMA for p?gemm") - variant( - "libvori", - default=False, - description=("Enable support for Voronoi integration" " and BQB compression"), - ) - variant("spglib", default=False, description="Enable support for spglib") - - with when("+cuda"): - variant( - "cuda_arch_35_k20x", - default=False, - description=( - "CP2K (resp. DBCSR) has specific parameter sets for" - " different GPU models. Enable this when building" - " with cuda_arch=35 for a K20x instead of a K40" - ), - ) - variant( - "cuda_fft", - default=False, - description=("Use CUDA also for FFTs in the PW part of CP2K"), - ) - variant( - "cuda_blas", - default=False, - when="@:7", # req in CP2K v8+ - description=("Use CUBLAS for general matrix operations in DBCSR"), - ) - - HFX_LMAX_RANGE = range(4, 8) - - variant( - "lmax", - description="Maximum supported angular momentum (HFX and others)", - default="5", - values=[str(x) for x in HFX_LMAX_RANGE], - multi=False, - ) - - depends_on("python", type="build") - depends_on("python@3:", when="@8:", type="build") - - depends_on("blas") - depends_on("lapack") - depends_on("fftw-api@3") - - # Force openmp propagation on some providers of blas / fftw-api - with when("+openmp"): - depends_on("fftw+openmp", when="^fftw") - depends_on("amdfftw+openmp", when="^amdfftw") - depends_on("cray-fftw+openmp", when="^cray-fftw") - depends_on("armpl-gcc threads=openmp", when="^armpl-gcc") - depends_on("openblas threads=openmp", when="^openblas") - # The Cray compiler wrappers will automatically add libsci_mp with - # -fopenmp. Since CP2K unconditionally links blas/lapack/scalapack - # we have to be consistent. - depends_on("cray-libsci+openmp", when="^cray-libsci") - - with when("smm=libxsmm"): - depends_on("libxsmm@1.17:~header-only", when="@9.1:") - # require libxsmm-1.11+ since 1.10 can leak file descriptors in Fortran - depends_on("libxsmm@1.11:~header-only", when="@:8.9") - # use pkg-config (support added in libxsmm-1.10) to link to libxsmm - depends_on("pkgconfig", type="build") - # please set variants: smm=blas by configuring packages.yaml or install - # cp2k with option smm=blas on aarch64 - conflicts("target=aarch64:", msg="libxsmm is not available on arm") - - with when("+libint"): - # ... and in CP2K 7.0+ for linking to libint2 - depends_on("pkgconfig", type="build", when="@7.0:") - # libint & libxc are always statically linked - depends_on("libint@1.1.4:1.2", when="@3.0:6.9") - for lmax in HFX_LMAX_RANGE: - # libint2 can be linked dynamically again - depends_on( - "libint@2.6.0:+fortran tune=cp2k-lmax-{0}".format(lmax), - when="@7.0: lmax={0}".format(lmax), - ) - - with when("+libxc"): - depends_on("pkgconfig", type="build", when="@7.0:") - depends_on("libxc@2.2.2:3", when="@:5", type="build") - depends_on("libxc@4.0.3:4", when="@6.0:6.9", type="build") - depends_on("libxc@4.0.3:4", when="@7.0:8.1") - depends_on("libxc@5.1.3:5.1", when="@8.2:8") - depends_on("libxc@5.1.7:5.1", when="@9:2022") - depends_on("libxc@6:6.1", when="@2023:") - - with when("+mpi"): - depends_on("mpi@2:") - depends_on("mpi@3:", when="@2023.1:") - depends_on("scalapack") - - with when("+cosma"): - depends_on("cosma+scalapack") - depends_on("cosma@2.5.1:", when="@9:") - depends_on("cosma+cuda", when="+cuda") - conflicts("~mpi") - # COSMA support was introduced in 8+ - conflicts("@:7") - - with when("+elpa"): - conflicts("~mpi", msg="elpa requires MPI") - depends_on("elpa+openmp", when="+openmp") - depends_on("elpa~openmp", when="~openmp") - depends_on("elpa@2021.05:", when="@8.3:") - depends_on("elpa@2021.11.001:", when="@9.1:") - - with when("+plumed"): - depends_on("plumed+shared") - depends_on("plumed+mpi", when="+mpi") - depends_on("plumed~mpi", when="~mpi") - - # while we link statically against PEXSI, its own deps may be linked in - # dynamically, therefore can't set this as pure build-type dependency. - with when("+pexsi"): - conflicts("~mpi", msg="pexsi requires MPI") - depends_on("pexsi+fortran@0.9.0:0.9", when="@:4") - depends_on("pexsi+fortran@0.10.0:", when="@5.0:") - - # only OpenMP should be consistently used, all other common things - # like ELPA, SCALAPACK are independent and Spack will ensure that - # a consistent/compatible combination is pulled into the dependency graph. - with when("+sirius"): - depends_on("sirius+fortran+shared") - depends_on("sirius+openmp", when="+openmp") - depends_on("sirius~openmp", when="~openmp") - depends_on("sirius@:6", when="@:7") - depends_on("sirius@7.0.0:7.0", when="@8:8.2") - depends_on("sirius@7.2", when="@8.3:8.9") - depends_on("sirius@7.3:", when="@9.1") - conflicts("~mpi") - # sirius support was introduced in 7+ - conflicts("@:6") - - with when("+libvori"): - depends_on("libvori@201219:", when="@8.1", type="build") - depends_on("libvori@210412:", when="@8.2:", type="build") - # libvori support was introduced in 8+ - conflicts("@:7") - - # the bundled libcusmm uses numpy in the parameter prediction (v7+) - # which is written using Python 3 - depends_on("py-numpy", when="@7:+cuda", type="build") - depends_on("python@3.6:", when="@7:+cuda", type="build") - - depends_on("spglib", when="+spglib") - - # Apparently cp2k@4.1 needs an "experimental" version of libwannier.a - # which is only available contacting the developer directly. See INSTALL - # in the stage of cp2k@4.1 - depends_on("wannier90", when="@3.0+mpi", type="build") - - # CP2K needs compiler specific compilation flags, e.g. optflags - conflicts("%apple-clang") - conflicts("%clang") - conflicts("%nag") - - conflicts("~openmp", when="@8:", msg="Building without OpenMP is not supported in CP2K 8+") - - # We only support specific cuda_archs for which we have parameter files - # for optimal kernels. Note that we don't override the cuda_archs property - # from the parent class, since the parent class defines constraints for all - # versions. Instead just mark all unsupported cuda archs as conflicting. - dbcsr_cuda_archs = ("35", "37", "60", "70") - cuda_msg = "cp2k only supports cuda_arch {0}".format(dbcsr_cuda_archs) - - for arch in CudaPackage.cuda_arch_values: - if arch not in dbcsr_cuda_archs: - conflicts("+cuda", when="cuda_arch={0}".format(arch), msg=cuda_msg) - - conflicts("+cuda", when="cuda_arch=none", msg=cuda_msg) - - # Fix 2- and 3-center integral calls to libint - patch( - "https://github.com/cp2k/cp2k/commit/5eaf864ed2bd21fb1b05a9173bb77a815ad4deda.patch?full_index=1", - sha256="3617abb877812c4b933f601438c70f95e21c6161bea177277b1d4125fd1c0bf9", - when="@8.2", - ) - patch("posix_c_source.patch", when="%aocc") - - def url_for_version(self, version): - url = "https://github.com/cp2k/cp2k/releases/download/v{0}/cp2k-{0}.tar.bz2" - return url.format(version) - - @property - def makefile_architecture(self): - return "{0.architecture}-{0.compiler.name}".format(self.spec) - - @property - def makefile_version(self): - return "{prefix}{suffix}".format( - prefix="p" if "+mpi" in self.spec else "s", - suffix="smp" if "+openmp" in self.spec else "opt", - ) - - @property - def makefile(self): - makefile_basename = ".".join([self.makefile_architecture, self.makefile_version]) - return join_path("arch", makefile_basename) - - @property - def archive_files(self): - return [join_path(self.stage.source_path, self.makefile)] - - def edit(self, spec, prefix): - pkgconf = which("pkg-config") - - fftw = spec["fftw-api:openmp" if "+openmp" in spec else "fftw-api"] - fftw_header_dir = fftw.headers.directories[0] - - # some providers (mainly Intel) keep the fftw headers in a subdirectory, find it - for incdir in [join_path(f, "fftw") for f in fftw.headers.directories]: - if os.path.exists(incdir): - fftw_header_dir = incdir - break - - optimization_flags = { - "gcc": ["-O2", "-funroll-loops", "-ftree-vectorize"], - "intel": ["-O2", "-pc64", "-unroll"], - "pgi": ["-fast"], - "nvhpc": ["-fast"], - "cce": ["-O2"], - "xl": ["-O3"], - "aocc": ["-O1"], - } - - dflags = ["-DNDEBUG"] - cppflags = ["-D__FFTW3", "-I{0}".format(fftw_header_dir)] - - # CP2K requires MPI 3 starting at version 2023.1 - # and __MPI_VERSION is not supported anymore. - if "@:2022.2" in spec: - if "^mpi@3:" in spec: - cppflags.append("-D__MPI_VERSION=3") - elif "^mpi@2:" in spec: - cppflags.append("-D__MPI_VERSION=2") - - cflags = optimization_flags[self.spec.compiler.name][:] - cxxflags = optimization_flags[self.spec.compiler.name][:] - fcflags = optimization_flags[self.spec.compiler.name][:] - nvflags = ["-O3"] - ldflags = [] - libs = [] - gpuver = "" - - # CP2K Makefile doesn't set C standard, but the source code uses - # C99-style for-loops with inline definition of iterating variable. - cflags.append(self.compiler.c99_flag) - - if "%intel" in spec: - cflags.append("-fp-model precise") - cxxflags.append("-fp-model precise") - fcflags += ["-fp-model precise", "-heap-arrays 64", "-g", "-traceback"] - elif "%gcc" in spec: - fcflags += [ - "-ffree-form", - "-ffree-line-length-none", - "-ggdb", # make sure we get proper Fortran backtraces - ] - elif "%aocc" in spec: - fcflags += ["-ffree-form", "-Mbackslash"] - elif "%pgi" in spec or "%nvhpc" in spec: - fcflags += ["-Mfreeform", "-Mextend"] - elif "%cce" in spec: - fcflags += ["-emf", "-ffree", "-hflex_mp=strict"] - elif "%xl" in spec: - fcflags += ["-qpreprocess", "-qstrict", "-q64"] - ldflags += ["-Wl,--allow-multiple-definition"] - - if "%gcc@10: +mpi" in spec and spec["mpi"].name in ["mpich", "cray-mpich"]: - fcflags += [ - "-fallow-argument-mismatch" - ] # https://github.com/pmodels/mpich/issues/4300 - - if "+openmp" in spec: - cflags.append(self.compiler.openmp_flag) - cxxflags.append(self.compiler.openmp_flag) - fcflags.append(self.compiler.openmp_flag) - ldflags.append(self.compiler.openmp_flag) - nvflags.append('-Xcompiler="{0}"'.format(self.compiler.openmp_flag)) - elif "%cce" in spec: # Cray enables OpenMP by default - cflags += ["-hnoomp"] - cxxflags += ["-hnoomp"] - fcflags += ["-hnoomp"] - ldflags += ["-hnoomp"] - - if "@7:" in spec: # recent versions of CP2K use C++14 CUDA code - cxxflags.append(self.compiler.cxx14_flag) - nvflags.append(self.compiler.cxx14_flag) - - ldflags.append(fftw.libs.search_flags) - - if "superlu-dist@4.3" in spec: - ldflags.insert(0, "-Wl,--allow-multiple-definition") - - if "+plumed" in self.spec: - dflags.extend(["-D__PLUMED2"]) - cppflags.extend(["-D__PLUMED2"]) - libs.extend( - [join_path(self.spec["plumed"].prefix.lib, "libplumed.{0}".format(dso_suffix))] - ) - - cc = spack_cc if "~mpi" in spec else spec["mpi"].mpicc - cxx = spack_cxx if "~mpi" in spec else spec["mpi"].mpicxx - fc = spack_fc if "~mpi" in spec else spec["mpi"].mpifc - - # Intel - if "%intel" in spec: - cppflags.extend(["-D__INTEL", "-D__HAS_ISO_C_BINDING", "-D__USE_CP2K_TRACE"]) - fcflags.extend(["-diag-disable 8290,8291,10010,10212,11060", "-free", "-fpp"]) - - # FFTW, LAPACK, BLAS - lapack = spec["lapack"].libs - blas = spec["blas"].libs - ldflags.append((lapack + blas).search_flags) - libs.extend([str(x) for x in (fftw.libs, lapack, blas)]) - - if self.spec.satisfies("platform=darwin"): - cppflags.extend(["-D__NO_STATM_ACCESS"]) - - if spec["blas"].name in ("intel-mkl", "intel-parallel-studio", "intel-oneapi-mkl"): - cppflags += ["-D__MKL"] - elif spec["blas"].name == "accelerate": - cppflags += ["-D__ACCELERATE"] - - if "+cosma" in spec: - # add before ScaLAPACK to override the p?gemm symbols - cosma = spec["cosma"].libs - ldflags.append(cosma.search_flags) - libs.extend(cosma) - - # MPI - if "+mpi" in spec: - cppflags.extend(["-D__parallel", "-D__SCALAPACK"]) - - if spec["mpi"].name == "intel-oneapi-mpi": - mpi = [join_path(spec["intel-oneapi-mpi"].libs.directories[0], "libmpi.so")] - else: - mpi = spec["mpi:cxx"].libs - - # while intel-mkl has a mpi variant and adds the scalapack - # libs to its libs, intel-oneapi-mkl does not. - if spec["scalapack"].name == "intel-oneapi-mkl": - mpi_impl = "openmpi" if spec["mpi"] == "openmpi" else "intelmpi" - scalapack = [ - join_path( - spec["intel-oneapi-mkl"].libs.directories[0], "libmkl_scalapack_lp64.so" - ), - join_path( - spec["intel-oneapi-mkl"].libs.directories[0], - "libmkl_blacs_{0}_lp64.so".format(mpi_impl), - ), - ] - else: - scalapack = spec["scalapack"].libs - ldflags.append(scalapack.search_flags) - - libs.extend(scalapack) - libs.extend(mpi) - libs.extend(self.compiler.stdcxx_libs) - - if "wannier90" in spec: - cppflags.append("-D__WANNIER90") - wannier = join_path(spec["wannier90"].libs.directories[0], "libwannier.a") - libs.append(wannier) - - if "+libint" in spec: - cppflags += ["-D__LIBINT"] - - if "@:6.9" in spec: - cppflags += ["-D__LIBINT_MAX_AM=6", "-D__LIBDERIV_MAX_AM1=5"] - - # libint-1.x.y has to be linked statically to work around - # inconsistencies in its Fortran interface definition - # (short-int vs int) which otherwise causes segfaults at - # runtime due to wrong offsets into the shared library - # symbols. - libs.extend( - [ - join_path(spec["libint"].libs.directories[0], "libderiv.a"), - join_path(spec["libint"].libs.directories[0], "libint.a"), - ] - ) - else: - fcflags += pkgconf("--cflags", "libint2", output=str).split() - libs += pkgconf("--libs", "libint2", output=str).split() - - if "+libxc" in spec: - cppflags += ["-D__LIBXC"] - - if "@:6.9" in spec: - libxc = spec["libxc:fortran,static"] - cppflags += [libxc.headers.cpp_flags] - ldflags.append(libxc.libs.search_flags) - libs.append(str(libxc.libs)) - else: - fcflags += pkgconf("--cflags", "libxcf03", output=str).split() - # some Fortran functions seem to be direct wrappers of the - # C functions such that we get a direct dependency on them, - # requiring `-lxc` to be present in addition to `-lxcf03` - libs += pkgconf("--libs", "libxcf03", "libxc", output=str).split() - - if "+pexsi" in spec: - cppflags.append("-D__LIBPEXSI") - fcflags.append("-I" + join_path(spec["pexsi"].prefix, "fortran")) - libs.extend( - [ - join_path(spec["pexsi"].libs.directories[0], "libpexsi.a"), - join_path(spec["superlu-dist"].libs.directories[0], "libsuperlu_dist.a"), - join_path( - spec["parmetis"].libs.directories[0], "libparmetis.{0}".format(dso_suffix) - ), - join_path( - spec["metis"].libs.directories[0], "libmetis.{0}".format(dso_suffix) - ), - ] - ) - - if "+elpa" in spec: - elpa = spec["elpa"] - elpa_suffix = "_openmp" if "+openmp" in elpa else "" - elpa_incdir = elpa.headers.directories[0] - - fcflags += ["-I{0}".format(join_path(elpa_incdir, "modules"))] - - # Currently AOCC support only static libraries of ELPA - if "%aocc" in spec: - libs.append( - join_path( - elpa.prefix.lib, ("libelpa{elpa_suffix}.a".format(elpa_suffix=elpa_suffix)) - ) - ) - else: - libs.append( - join_path( - elpa.libs.directories[0], - ( - "libelpa{elpa_suffix}.{dso_suffix}".format( - elpa_suffix=elpa_suffix, dso_suffix=dso_suffix - ) - ), - ) - ) - - if spec.satisfies("@:4"): - if elpa.satisfies("@:2014.5"): - cppflags.append("-D__ELPA") - elif elpa.satisfies("@2014.6:2015.10"): - cppflags.append("-D__ELPA2") - else: - cppflags.append("-D__ELPA3") - else: - cppflags.append( - "-D__ELPA={0}{1:02d}".format(elpa.version[0], int(elpa.version[1])) - ) - fcflags += ["-I{0}".format(join_path(elpa_incdir, "elpa"))] - - if "+cuda" in spec and "+cuda" in elpa: - cppflags += ["-D__ELPA_NVIDIA_GPU"] - - if spec.satisfies("+sirius"): - sirius = spec["sirius"] - cppflags.append("-D__SIRIUS") - fcflags += ["-I{0}".format(sirius.prefix.include.sirius)] - libs += list(sirius.libs) - - if spec.satisfies("+cuda"): - libs += [ - "-L{}".format(spec["cuda"].libs.directories[0]), - "-L{}/stubs".format(spec["cuda"].libs.directories[0]), - "-lcuda", - "-lcudart", - "-lnvrtc", - "-lstdc++", - ] - - if spec.satisfies("@9:"): - if spec.satisfies("@2022:"): - cppflags += ["-D__OFFLOAD_CUDA"] - - acc_compiler_var = "OFFLOAD_CC" - acc_flags_var = "OFFLOAD_FLAGS" - cppflags += ["-D__DBCSR_ACC", "-D__GRID_CUDA", "-DOFFLOAD_TARGET=cuda"] - libs += ["-lcublas"] - - if spec.satisfies("+cuda_fft"): - if spec.satisfies("@:9"): - cppflags += ["-D__PW_CUDA"] - - libs += ["-lcufft"] - else: - if spec.satisfies("@2022:"): - cppflags += ["-D__NO_OFFLOAD_PW"] - else: - acc_compiler_var = "NVCC" - acc_flags_var = "NVFLAGS" - cppflags += ["-D__ACC"] - if spec.satisfies("+cuda_blas"): - cppflags += ["-D__DBCSR_ACC=2"] - libs += ["-lcublas"] - else: - cppflags += ["-D__DBCSR_ACC"] - - if spec.satisfies("+cuda_fft"): - cppflags += ["-D__PW_CUDA"] - libs += ["-lcufft", "-lcublas"] - - cuda_arch = spec.variants["cuda_arch"].value[0] - if cuda_arch: - gpuver = {"35": "K40", "37": "K80", "60": "P100", "70": "V100"}[cuda_arch] - - if cuda_arch == "35" and spec.satisfies("+cuda_arch_35_k20x"): - gpuver = "K20X" - - if "smm=libsmm" in spec: - lib_dir = join_path("lib", self.makefile_architecture, self.makefile_version) - mkdirp(lib_dir) - try: - copy(env["LIBSMM_PATH"], join_path(lib_dir, "libsmm.a")) - except KeyError: - raise KeyError( - "Point environment variable LIBSMM_PATH to " - "the absolute path of the libsmm.a file" - ) - except IOError: - raise IOError( - "The file LIBSMM_PATH pointed to does not " - "exist. Note that it must be absolute path." - ) - cppflags.extend(["-D__HAS_smm_dnn", "-D__HAS_smm_vec"]) - libs.append("-lsmm") - - elif "smm=libxsmm" in spec: - cppflags += ["-D__LIBXSMM"] - cppflags += pkgconf("--cflags-only-other", "libxsmmf", output=str).split() - fcflags += pkgconf("--cflags-only-I", "libxsmmf", output=str).split() - libs += pkgconf("--libs", "libxsmmf", output=str).split() - - if "+libvori" in spec: - cppflags += ["-D__LIBVORI"] - libvori = spec["libvori"].libs - ldflags += [libvori.search_flags] - libs += libvori - libs += ["-lstdc++"] - - if "+spglib" in spec: - cppflags += ["-D__SPGLIB"] - spglib = spec["spglib"].libs - ldflags += [spglib.search_flags] - libs += spglib - - dflags.extend(cppflags) - cflags.extend(cppflags) - cxxflags.extend(cppflags) - fcflags.extend(cppflags) - nvflags.extend(cppflags) - - with open(self.makefile, "w") as mkf: - if "+plumed" in spec: - mkf.write( - "# include Plumed.inc as recommended by" - "PLUMED to include libraries and flags" - ) - mkf.write("include {0}\n".format(spec["plumed"].package.plumed_inc)) - - mkf.write("\n# COMPILER, LINKER, TOOLS\n\n") - mkf.write( - "FC = {0}\n" "CC = {1}\n" "CXX = {2}\n" "LD = {3}\n".format(fc, cc, cxx, fc) - ) - - if "%intel" in spec: - intel_bin_dir = ancestor(self.compiler.cc) - # CPP is a commented command in Intel arch of CP2K - # This is the hack through which cp2k developers avoid doing : - # - # ${CPP} .F > .f90 - # - # and use `-fpp` instead - mkf.write("CPP = # {0} -P\n".format(spack_cc)) - mkf.write("AR = {0}/xiar -qs\n".format(intel_bin_dir)) - else: - mkf.write("CPP = # {0} -E\n".format(spack_cc)) - mkf.write("AR = ar -qs\n") # r = qs is a GNU extension - - if "+cuda" in spec: - mkf.write( - "{0} = {1}\n".format( - acc_compiler_var, join_path(spec["cuda"].prefix, "bin", "nvcc") - ) - ) - - # Write compiler flags to file - def fflags(var, lst): - return "{0} = {1}\n\n".format(var, " \\\n\t".join(lst)) - - mkf.write("\n# FLAGS & LIBRARIES\n") - mkf.write(fflags("DFLAGS", dflags)) - mkf.write(fflags("CPPFLAGS", cppflags)) - mkf.write(fflags("CFLAGS", cflags)) - mkf.write(fflags("CXXFLAGS", cxxflags)) - if "+cuda" in spec: - mkf.write(fflags(acc_flags_var, nvflags)) - mkf.write(fflags("FCFLAGS", fcflags)) - mkf.write(fflags("LDFLAGS", ldflags)) - mkf.write(fflags("LIBS", libs)) - - if "%intel" in spec: - mkf.write(fflags("LDFLAGS_C", ldflags + ["-nofor-main"])) - - mkf.write("# CP2K-specific flags\n\n") - mkf.write("GPUVER = {0}\n".format(gpuver)) - mkf.write("DATA_DIR = {0}\n".format(self.prefix.share.data)) - - @property - def build_directory(self): - build_dir = self.stage.source_path - - if self.spec.satisfies("@:6"): - # prior to version 7.1 was the Makefile located in makefiles/ - build_dir = join_path(build_dir, "makefiles") - - return build_dir - - @property - def build_targets(self): - return [ - "ARCH={0}".format(self.makefile_architecture), - "VERSION={0}".format(self.makefile_version), - ] - - def build(self, spec, prefix): - if "+cuda" in spec and len(spec.variants["cuda_arch"].value) > 1: - raise InstallError("cp2k supports only one cuda_arch at a time") - - # Apparently the Makefile bases its paths on PWD - # so we need to set PWD = self.build_directory - with spack.util.environment.set_env(PWD=self.build_directory): - super(Cp2k, self).build(spec, prefix) - - with working_dir(self.build_directory): - make("libcp2k", *self.build_targets) - - def install(self, spec, prefix): - exe_dir = join_path("exe", self.makefile_architecture) - lib_dir = join_path("lib", self.makefile_architecture, self.makefile_version) - - install_tree(exe_dir, self.prefix.bin) - install_tree("data", self.prefix.share.data) - install_tree(lib_dir, self.prefix.lib) - - mkdirp(self.prefix.include) - install("src/start/libcp2k.h", join_path(self.prefix.include, "libcp2k.h")) - - @run_after("install") - def fix_package_config(self): - """ - Default build procedure generates libcp2k.pc with invalid paths, - because they are collected from temporary directory. - - Ignoring invalid paths, most library-related switches are correct - except for fftw and openblas. - - This procedure is appending two missing switches (tested with GROMACS 2022.2 + CP2K). - - In case such approach causes issues in the future, it might be necessary - to generate and override entire libcp2k.pc. - """ - if self.spec.satisfies("@9.1:"): - pkgconfig_file = join_path(self.prefix.lib.pkgconfig, "libcp2k.pc") - filter_file(r"(^includedir=).*", r"\1{0}".format(self.prefix.include), pkgconfig_file) - filter_file(r"(^libdir=).*", r"\1{0}".format(self.prefix.lib), pkgconfig_file) - - with open(pkgconfig_file, "r+") as handle: - content = handle.read().rstrip() - - content += " " + self.spec["blas"].libs.ld_flags - content += " " + self.spec["lapack"].libs.ld_flags - content += " " + self.spec["fftw-api"].libs.ld_flags - - if (self.spec["fftw-api"].name == "fftw") and ("+openmp" in self.spec["fftw"]): - content += " -lfftw3_omp" - - content += "\n" - - handle.seek(0) - handle.write(content) - - def check(self): - data_dir = join_path(self.stage.source_path, "data") - - # CP2K < 7 still uses $PWD to detect the current working dir - # and Makefile is in a subdir, account for both facts here: - with spack.util.environment.set_env(CP2K_DATA_DIR=data_dir, PWD=self.build_directory): - with working_dir(self.build_directory): - make("test", *self.build_targets) diff --git a/repo/packages/cp2k/posix_c_source.patch b/repo/packages/cp2k/posix_c_source.patch deleted file mode 100644 index 87a544a7..00000000 --- a/repo/packages/cp2k/posix_c_source.patch +++ /dev/null @@ -1,12 +0,0 @@ ---- a/src/sockets.c 2019-12-24 01:41:57.000000000 +0530 -+++ b/src/sockets.c 2023-05-15 18:35:33.941236292 +0530 -@@ -35,6 +35,7 @@ - */ - #ifndef __NO_IPI_DRIVER - -+#define _POSIX_C_SOURCE 200112L - #include - #include - #include - - From 5436840213d22d069659edd7373d7e7934057f76 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 11:11:12 +0800 Subject: [PATCH 06/21] Contributed the idg repo. --- repo/packages/idg/package.py | 28 ---------------------------- 1 file changed, 28 deletions(-) delete mode 100644 repo/packages/idg/package.py diff --git a/repo/packages/idg/package.py b/repo/packages/idg/package.py deleted file mode 100644 index 089d3c40..00000000 --- a/repo/packages/idg/package.py +++ /dev/null @@ -1,28 +0,0 @@ -# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# Contribute back the recipe -from spack.package import * - - -class Idg(CMakePackage): - """ - Image Domain Gridding (IDG) is a fast method for convolutional resampling (gridding/degridding) - of radio astronomical data (visibilities). Direction-dependent effects (DDEs) - or A-tems can be applied in the gridding process. - """ - - homepage = "https://www.astron.nl/citt/IDG/" - git = "https://git.astron.nl/RD/idg.git" - - version('1.0.0', commit='3322756fb8b6e3bb1fe5293f3e07e40623ff8486') - version('0.8.1', commit='a09f3c85094c592f9304fff4c31e920c7592c3c3') - - depends_on('boost') - depends_on('fftw-api@3') - depends_on('blas') - - def url_for_version(self, version): - return ("https://git.astron.nl/RD/idg/-/archive/{0}/idg-{0}.tar.gz".format(version)) - From 71d4cfe2a4aabb26a9f2d97cfbf394738f00461a Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 11:19:13 +0800 Subject: [PATCH 07/21] Removed tower-cli, already in spack/develop. --- repo/packages/tower-cli/package.py | 29 ----------------------------- 1 file changed, 29 deletions(-) delete mode 100644 repo/packages/tower-cli/package.py diff --git a/repo/packages/tower-cli/package.py b/repo/packages/tower-cli/package.py deleted file mode 100644 index 69765ca4..00000000 --- a/repo/packages/tower-cli/package.py +++ /dev/null @@ -1,29 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# can remove -import sys - -from spack.package import * - - -class TowerCli(Package): - """Tower on the Command Line brings Nextflow Tower concepts - including Pipelines, Actions and Compute Environments - to the terminal. - """ - - homepage = "https://github.com/seqeralabs/tower-cli" - - if sys.platform == 'darwin': - url = "https://github.com/seqeralabs/tower-cli/releases/download/v0.7.0/tw-0.7.0-osx-x86_64" - version('0.7.0', sha256='b1b3ade4231de2c7303832bac406510c9de171d07d6384a54945903f5123f772', expand=False) - elif sys.platform.startswith('linux'): - url = "https://github.com/seqeralabs/tower-cli/releases/download/v0.7.0/tw-0.7.0-linux-x86_64" - version('0.7.0', sha256='651f564b80585c9060639f1a8fc82966f81becb0ab3e3ba34e53baf3baabff39', expand=False) - - def install(self, spec, prefix): - mkdirp(prefix.bin) - install(self.stage.archive_file, join_path(prefix.bin, "tw")) - set_executable(join_path(prefix.bin, "tw")) From e74b15db4b21fdc26112e62392cb8802e95ac513 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 11:32:35 +0800 Subject: [PATCH 08/21] Contributed miniocli. --- repo/packages/miniocli/package.py | 49 ------------------------------- 1 file changed, 49 deletions(-) delete mode 100644 repo/packages/miniocli/package.py diff --git a/repo/packages/miniocli/package.py b/repo/packages/miniocli/package.py deleted file mode 100644 index 9c0d658d..00000000 --- a/repo/packages/miniocli/package.py +++ /dev/null @@ -1,49 +0,0 @@ -# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# Contribute this -from spack.package import * - - -class Miniocli(MakefilePackage): - """MinIO Client (mc) provides a modern alternative to UNIX commands - like ls, cat, cp, mirror, diff etc. It supports filesystems and - Amazon S3 compatible cloud storage service (AWS Signature v2 and v4).""" - - homepage = "https://docs.min.io/docs/minio-client-complete-guide.html" - url = "https://github.com/minio/mc/archive/refs/tags/RELEASE.2022-02-02T02-03-24Z.tar.gz" - - version( - '2023-06-28', - sha256='033a80439474595665bdbc3ec72b059dc9e69e99db85fe6820877ad8973a080b', - url='https://github.com/minio/mc/archive/refs/tags/RELEASE.2023-06-28T21-54-17Z.tar.gz', - ) - version( - '2022-05-04', - sha256='2b935c3744228978c93c14186b65a6078e4ffc267f32cdb8c994eff2dda95a6e', - url="https://github.com/minio/mc/archive/RELEASE.2022-05-04T06-07-55Z.tar.gz", - ) - version( - '2022-03-31', - sha256='3b983ea1cc50768b0826989dba931044ac3f8e841cc09aefed217301c92fa8a3', - url="https://github.com/minio/mc/archive/RELEASE.2022-03-31T04-55-30Z.tar.gz", - ) - # versions of 2022-03-* or later require github.com/shirou/gopsutil/v3 and this is generating an error - version( - '2022-02-02', - sha256='2d4a64c17935d40d0e325761cc214b2efceb19ce006101c192da9b31f8920a97', - url="https://github.com/minio/mc/archive/RELEASE.2022-02-02T02-03-24Z.tar.gz", - ) - version( - '2022-01-05', - sha256='d5dbd32b7a7f79baace09dd6518121798d2fcbb84b81046b61ff90f980c8f963', - url="https://github.com/minio/mc/archive/RELEASE.2022-01-05T23-52-51Z.tar.gz", - ) - - depends_on('go', type='build') - - def install(self, spec, prefix): - go('build') - mkdirp(prefix.bin) - install('mc', prefix.bin) From cca880e4c1cf0a163867ed008ccd74327247fcf4 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 11:36:39 +0800 Subject: [PATCH 09/21] Tower-agent already contributed. --- repo/packages/tower-agent/package.py | 24 ------------------------ 1 file changed, 24 deletions(-) delete mode 100644 repo/packages/tower-agent/package.py diff --git a/repo/packages/tower-agent/package.py b/repo/packages/tower-agent/package.py deleted file mode 100644 index 2bb213d0..00000000 --- a/repo/packages/tower-agent/package.py +++ /dev/null @@ -1,24 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# can remove -from spack.package import * - - -class TowerAgent(Package): - """Tower Agent allows Nextflow Tower to launch pipelines - on HPC clusters that do not allow direct access through - an SSH client. - """ - - homepage = "https://github.com/seqeralabs/tower-agent" - url = "https://github.com/seqeralabs/tower-agent/releases/download/v0.4.3/tw-agent-linux-x86_64" - - version('0.4.5', sha256='d3f38931ff769299b9f9f7e78d9f6a55f93914878c09117b8eaf5decd0c734ec', expand=False) - version('0.4.3', sha256='1125e64d4e3342e77fcf7f6827f045e421084654fe8faafd5389e356e0613cc0', expand=False) - - def install(self, spec, prefix): - mkdirp(prefix.bin) - install(self.stage.archive_file, join_path(prefix.bin, "tw-agent")) - set_executable(join_path(prefix.bin, "tw-agent")) From a720f5ac9df3cf36516a48800e068cf08ad86fc0 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 13:49:14 +0800 Subject: [PATCH 10/21] Contributed kokkos to Spack. --- repo/packages/kokkos-kernels/package.py | 181 -------- .../kokkos/hpx_profiling_fences.patch | 84 ---- repo/packages/kokkos/package.py | 410 ------------------ 3 files changed, 675 deletions(-) delete mode 100644 repo/packages/kokkos-kernels/package.py delete mode 100644 repo/packages/kokkos/hpx_profiling_fences.patch delete mode 100644 repo/packages/kokkos/package.py diff --git a/repo/packages/kokkos-kernels/package.py b/repo/packages/kokkos-kernels/package.py deleted file mode 100644 index 9bfc8cc8..00000000 --- a/repo/packages/kokkos-kernels/package.py +++ /dev/null @@ -1,181 +0,0 @@ -# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# ======================================================================= -# PAWSEY ADDITIONS -# ======================================================================= -# This is a version of the recipe coming from the later 0.21.0-dev Spack -# version. Required by newer kokkkos from spack 0.21 -from spack.package import * - - -class KokkosKernels(CMakePackage, CudaPackage): - """Kokkos Kernels provides math kernels, often BLAS or LAPACK - for small matrices, that can be used in larger Kokkos parallel routines""" - - homepage = "https://github.com/kokkos/kokkos-kernels" - git = "https://github.com/kokkos/kokkos-kernels.git" - url = "https://github.com/kokkos/kokkos-kernels/archive/3.6.00.tar.gz" - - tags = ["e4s"] - - test_requires_compiler = True - - # maintainers("lucbv", "srajama1", "brian-kelley") - - # generate checksum for each release tarball with the following command - # openssl sha256 kokkos-kernels-x.y.z.tar.gz - version("develop", branch="develop") - version("master", branch="master") - version("3.7.00", sha256="51bc6db3995392065656848e2b152cfd1c3a95a951ab18a3934278113d59f32b") - version("3.6.01", sha256="f000b156c8c0b80e85d38587907c11d9479aaf362408b812effeda5e22b24d0d") - version("3.6.00", sha256="2753643fd643b9eed9f7d370e0ff5fa957211d08a91aa75398e31cbc9e5eb0a5") - version("3.5.00", sha256="a03a41a047d95f9f07cd1e1d30692afdb75b5c705ef524e19c1d02fe60ccf8d1") - version("3.4.01", sha256="f504aa4afbffb58fa7c4430d0fdb8fd5690a268823fa15eb0b7d58dab9d351e6") - version("3.4.00", sha256="07ba11869e686cb0d47272d1ef494ccfbcdef3f93ff1c8b64ab9e136a53a227a") - version("3.3.01", sha256="0f21fe6b5a8b6ae7738290e293aa990719aefe88b32f84617436bfd6074a8f77") - version("3.3.00", sha256="8d7f78815301afb90ddba7914dce5b718cea792ac0c7350d2f8d00bd2ef1cece") - version("3.2.01", sha256="c486e5cac19e354a517498c362838619435734d64b44f44ce909b0531c21d95c") - version("3.2.00", sha256="8ac20ee28ae7813ce1bda461918800ad57fdbac2af86ef5d1ba74e83e10956de") - version("3.1.00", sha256="27fea241ae92f41bd5b070b1a590ba3a56a06aca750207a98bea2f64a4a40c89") - version("3.0.00", sha256="e4b832aed3f8e785de24298f312af71217a26067aea2de51531e8c1e597ef0e6") - - depends_on("kokkos") - depends_on("kokkos@master", when="@master") - depends_on("kokkos@develop", when="@develop") - depends_on("kokkos@3.7.00", when="@3.7.00") - depends_on("kokkos@3.6.01", when="@3.6.01") - depends_on("kokkos@3.6.00", when="@3.6.00") - depends_on("kokkos@3.5.00", when="@3.5.00") - depends_on("kokkos@3.4.01", when="@3.4.01") - depends_on("kokkos@3.4.00", when="@3.4.00") - depends_on("kokkos@3.3.01", when="@3.3.01") - depends_on("kokkos@3.3.00", when="@3.3.00") - depends_on("kokkos@3.2.01", when="@3.2.01") - depends_on("kokkos@3.2.00", when="@3.2.00") - depends_on("kokkos@3.1.00", when="@3.1.00") - depends_on("kokkos@3.0.00", when="@3.0.00") - depends_on("cmake@3.16:", type="build") - - backends = { - "serial": (False, "enable Serial backend (default)"), - "cuda": (False, "enable Cuda backend"), - "openmp": (False, "enable OpenMP backend"), - "threads": (False, "enable C++ threads backend"), - } - - for backend in backends: - deflt_bool, descr = backends[backend] - variant(backend.lower(), default=deflt_bool, description=descr) - depends_on("kokkos+%s" % backend.lower(), when="+%s" % backend.lower()) - - space_etis = { - "execspace_cuda": ("auto", "", "cuda"), - "execspace_openmp": ("auto", "", "openmp"), - "execspace_threads": ("auto", "", "threads"), - "execspace_serial": ("auto", "", "serial"), - "memspace_cudauvmspace": ("auto", "", "cuda"), - "memspace_cudaspace": ("auto", "", "cuda"), - } - for eti in space_etis: - deflt, descr, backend_required = space_etis[eti] - variant(eti, default=deflt, description=descr) - depends_on("kokkos+%s" % backend_required, when="+%s" % eti) - - numeric_etis = { - "ordinals": ( - "int", - "ORDINAL_", # default, cmake name - ["int", "int64_t"], - ), # allowed values - "offsets": ("int,size_t", "OFFSET_", ["int", "size_t"]), - "layouts": ("left", "LAYOUT", ["left", "right"]), - "scalars": ("double", "", ["float", "double", "complex_float", "complex_double"]), - } - for eti in numeric_etis: - deflt, cmake_name, vals = numeric_etis[eti] - variant(eti, default=deflt, values=vals, multi=True) - - tpls = { - # variant name #deflt #spack name #root var name #docstring - "blas": (False, "blas", "BLAS", "Link to system BLAS"), - "lapack": (False, "lapack", "LAPACK", "Link to system LAPACK"), - "mkl": (False, "mkl", "MKL", "Link to system MKL"), - "cublas": (False, "cuda", None, "Link to CUDA BLAS library"), - "cusparse": (False, "cuda", None, "Link to CUDA sparse library"), - "superlu": (False, "superlu", "SUPERLU", "Link to SuperLU library"), - "cblas": (False, "cblas", "CBLAS", "Link to CBLAS library"), - "lapacke": (False, "clapack", "LAPACKE", "Link to LAPACKE library"), - } - - for tpl in tpls: - deflt_bool, spackname, rootname, descr = tpls[tpl] - variant(tpl, default=deflt_bool, description=descr) - depends_on(spackname, when="+%s" % tpl) - - variant("shared", default=True, description="Build shared libraries") - - def cmake_args(self): - spec = self.spec - options = [] - - isdiy = "+diy" in spec - if isdiy: - options.append("-DSpack_WORKAROUND=On") - - options.append("-DKokkos_ROOT=%s" % spec["kokkos"].prefix) - if spec.satisfies("^kokkos+rocm"): - options.append("-DCMAKE_CXX_COMPILER=%s" % spec["hip"].hipcc) - else: - # Compiler weirdness due to nvcc_wrapper - options.append("-DCMAKE_CXX_COMPILER=%s" % spec["kokkos"].kokkos_cxx) - - if self.run_tests: - options.append("-DKokkosKernels_ENABLE_TESTS=ON") - - for tpl in self.tpls: - on_flag = "+%s" % tpl - off_flag = "~%s" % tpl - dflt, spackname, rootname, descr = self.tpls[tpl] - if on_flag in self.spec: - options.append("-DKokkosKernels_ENABLE_TPL_%s=ON" % tpl.upper()) - if rootname: - options.append("-D%s_ROOT=%s" % (rootname, spec[spackname].prefix)) - else: - pass # this should get picked up automatically, we hope - elif off_flag in self.spec: - options.append("-DKokkosKernels_ENABLE_TPL_%s=OFF" % tpl.upper()) - - for eti in self.numeric_etis: - deflt, cmake_name, vals = self.numeric_etis[eti] - for val in vals: - keyval = "%s=%s" % (eti, val) - cmake_option = "KokkosKernels_INST_%s%s" % (cmake_name.upper(), val.upper()) - if keyval in spec: - options.append("-D%s=ON" % cmake_option) - else: - options.append("-D%s=OFF" % cmake_option) - - for eti in self.space_etis: - deflt, descr, _ = self.space_etis[eti] - if deflt == "auto": - value = spec.variants[eti].value - # spack does these as strings, not reg booleans - if str(value) == "True": - options.append("-DKokkosKernels_INST_%s=ON" % eti.upper()) - elif str(value) == "False": - options.append("-DKokkosKernels_INST_%s=OFF" % eti.upper()) - else: - pass # don't pass anything, let CMake decide - else: # simple option - on_flag = "+%s" % eti - off_flag = "~%s" % eti - if on_flag in self.spec: - options.append("-DKokkosKernels_INST_%s=ON" % eti.upper()) - elif off_flag in self.spec: - options.append("-DKokkosKernels_INST_%s=OFF" % eti.upper()) - - options.append(self.define_from_variant("BUILD_SHARED_LIBS", "shared")) - - return options diff --git a/repo/packages/kokkos/hpx_profiling_fences.patch b/repo/packages/kokkos/hpx_profiling_fences.patch deleted file mode 100644 index 013fbd9f..00000000 --- a/repo/packages/kokkos/hpx_profiling_fences.patch +++ /dev/null @@ -1,84 +0,0 @@ -diff --git a/core/src/HPX/Kokkos_HPX_Task.hpp b/core/src/HPX/Kokkos_HPX_Task.hpp -index 7bb3ca5d0..ff50fdc5f 100644 ---- a/core/src/HPX/Kokkos_HPX_Task.hpp -+++ b/core/src/HPX/Kokkos_HPX_Task.hpp -@@ -216,7 +216,7 @@ class TaskQueueSpecializationConstrained< - task_queue.scheduler = &scheduler; - Kokkos::Impl::dispatch_execute_task(&task_queue, - Kokkos::Experimental::HPX()); -- Kokkos::Experimental::HPX().fence()"Kokkos::Impl::TaskQueueSpecializationConstrained::execute: fence after task execution"; -+ Kokkos::Experimental::HPX().fence("Kokkos::Impl::TaskQueueSpecializationConstrained::execute: fence after task execution"); - } - - // Must provide task queue execution function -diff --git a/core/src/Kokkos_HPX.hpp b/core/src/Kokkos_HPX.hpp -index 236211864..3e8522e94 100644 ---- a/core/src/Kokkos_HPX.hpp -+++ b/core/src/Kokkos_HPX.hpp -@@ -282,11 +282,11 @@ class HPX { - m_mode = other.m_mode; - m_independent_instance_data = other.m_independent_instance_data; - m_buffer = m_mode == instance_mode::independent -- ? m_independent_instance_data->m_buffer -- : m_global_instance_data.m_buffer; -- m_future = m_mode == instance_mode::independent -- ? m_independent_instance_data->m_future -- : m_global_instance_data.m_future; -+ ? m_independent_instance_data->m_buffer -+ : m_global_instance_data.m_buffer; -+ m_future = m_mode == instance_mode::independent -+ ? m_independent_instance_data->m_future -+ : m_global_instance_data.m_future; - return *this; - } - #else -@@ -322,25 +322,36 @@ class HPX { - "Fence"); - } - void impl_fence_instance(const std::string &name) const { -- Kokkos::Tools::Experimental::Impl::profile_fence_event(name, *this, [&]() { -- if (hpx::threads::get_self_ptr() == nullptr) { -- hpx::threads::run_as_hpx_thread([this]() { impl_get_future().wait(); }); -- } else { -- impl_get_future().wait(); -- } -- }); -+ Kokkos::Tools::Experimental::Impl::profile_fence_event< -+ Kokkos::Experimental::HPX>( -+ name, -+ Kokkos::Tools::Experimental::Impl::DirectFenceIDHandle{ -+ impl_instance_id()}, -+ [&]() { -+ if (hpx::threads::get_self_ptr() == nullptr) { -+ hpx::threads::run_as_hpx_thread( -+ [this]() { impl_get_future().wait(); }); -+ } else { -+ impl_get_future().wait(); -+ } -+ }); - } - - void impl_fence_all_instances() const { -- impl_fence_instance( -+ impl_fence_all_instances( - "Kokkos::Experimental::HPX::impl_fence_all_instances: Unnamed Global " - "HPX Fence"); - } -- void impl_fence_all_instances(const std::string &namename) const { -- Kokkos::Tools::Experimental::Impl::profile_fence_event(name, *this, [&]() { -- hpx::util::yield_while( -- []() { return m_active_parallel_region_count.load() != 0; }); -- }); -+ void impl_fence_all_instances(const std::string &name) const { -+ Kokkos::Tools::Experimental::Impl::profile_fence_event< -+ Kokkos::Experimental::HPX>( -+ name, -+ Kokkos::Tools::Experimental::SpecialSynchronizationCases:: -+ GlobalDeviceSynchronization, -+ [&]() { -+ hpx::util::yield_while( -+ []() { return m_active_parallel_region_count.load() != 0; }); -+ }); - } - #endif - diff --git a/repo/packages/kokkos/package.py b/repo/packages/kokkos/package.py deleted file mode 100644 index c5ba01c2..00000000 --- a/repo/packages/kokkos/package.py +++ /dev/null @@ -1,410 +0,0 @@ -# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# ======================================================================= -# PAWSEY ADDITIONS -# ======================================================================= -# This is a version of the recipe coming from the later 0.21.0-dev Spack -# version. It will allow us to have the latest versions. -import os.path - -from llnl.util import tty - -from spack.package import * - - -class Kokkos(CMakePackage, CudaPackage, ROCmPackage): - """Kokkos implements a programming model in C++ for writing performance - portable applications targeting all major HPC platforms.""" - - homepage = "https://github.com/kokkos/kokkos" - git = "https://github.com/kokkos/kokkos.git" - url = "https://github.com/kokkos/kokkos/archive/3.6.00.tar.gz" - - tags = ["e4s"] - - test_requires_compiler = True - - #maintainers("janciesko", "crtrott") - - version("master", branch="master") - version("develop", branch="develop") - version("4.0.01", sha256="bb942de8afdd519fd6d5d3974706bfc22b6585a62dd565c12e53bdb82cd154f0") - version("4.0.00", sha256="1829a423883d4b44223c7c3a53d3c51671145aad57d7d23e6a1a4bebf710dcf6") - version("3.7.02", sha256="5024979f06bc8da2fb696252a66297f3e0e67098595a0cc7345312b3b4aa0f54") - version("3.7.01", sha256="0481b24893d1bcc808ec68af1d56ef09b82a1138a1226d6be27c3b3c3da65ceb") - version("3.7.00", sha256="62e3f9f51c798998f6493ed36463f66e49723966286ef70a9dcba329b8443040") - version("3.6.01", sha256="1b80a70c5d641da9fefbbb652e857d7c7a76a0ebad1f477c253853e209deb8db") - version("3.6.00", sha256="53b11fffb53c5d48da5418893ac7bc814ca2fde9c86074bdfeaa967598c918f4") - version("3.5.00", sha256="748f06aed63b1e77e3653cd2f896ef0d2c64cb2e2d896d9e5a57fec3ff0244ff") - version("3.4.01", sha256="146d5e233228e75ef59ca497e8f5872d9b272cb93e8e9cdfe05ad34a23f483d1") - version("3.4.00", sha256="2e4438f9e4767442d8a55e65d000cc9cde92277d415ab4913a96cd3ad901d317") - version("3.3.01", sha256="4919b00bb7b6eb80f6c335a32f98ebe262229d82e72d3bae6dd91aaf3d234c37") - version("3.3.00", sha256="170b9deaa1943185e928f8fcb812cd4593a07ed7d220607467e8f0419e147295") - version("3.2.01", sha256="9e27a3d8f81559845e190d60f277d84d6f558412a3df3301d9545e91373bcaf1") - version("3.2.00", sha256="05e1b4dd1ef383ca56fe577913e1ff31614764e65de6d6f2a163b2bddb60b3e9") - version("3.1.01", sha256="ff5024ebe8570887d00246e2793667e0d796b08c77a8227fe271127d36eec9dd") - version("3.1.00", sha256="b935c9b780e7330bcb80809992caa2b66fd387e3a1c261c955d622dae857d878") - version("3.0.00", sha256="c00613d0194a4fbd0726719bbed8b0404ed06275f310189b3493f5739042a92b") - - depends_on("cmake@3.16:", type="build") - - devices_variants = { - "cuda": [False, "Whether to build CUDA backend"], - "openmp": [False, "Whether to build OpenMP backend"], - "threads": [False, "Whether to build the C++ threads backend"], - "serial": [True, "Whether to build serial backend"], - "rocm": [False, "Whether to build HIP backend"], - "sycl": [False, "Whether to build the SYCL backend"], - "openmptarget": [False, "Whether to build the OpenMPTarget backend"], - } - conflicts("+rocm", when="@:3.0") - conflicts("+sycl", when="@:3.3") - conflicts("+openmptarget", when="@:3.5") - - # https://github.com/spack/spack/issues/29052 - conflicts("@:3.5 +sycl", when="%dpcpp@2022:") - conflicts("@:3.5 +sycl", when="%oneapi@2022:") - - tpls_variants = { - "hpx": [False, "Whether to enable the HPX library"], - "hwloc": [False, "Whether to enable the HWLOC library"], - "numactl": [False, "Whether to enable the LIBNUMA library"], - "memkind": [False, "Whether to enable the MEMKIND library"], - } - - options_variants = { - "aggressive_vectorization": [False, "Aggressively vectorize loops"], - "compiler_warnings": [False, "Print all compiler warnings"], - "cuda_constexpr": [False, "Activate experimental constexpr features"], - "cuda_lambda": [False, "Activate experimental lambda features"], - "cuda_ldg_intrinsic": [False, "Use CUDA LDG intrinsics"], - "cuda_relocatable_device_code": [False, "Enable RDC for CUDA"], - "cuda_uvm": [False, "Enable unified virtual memory (UVM) for CUDA"], - "debug": [False, "Activate extra debug features - may increase compiletimes"], - "debug_bounds_check": [False, "Use bounds checking - will increase runtime"], - "debug_dualview_modify_check": [False, "Debug check on dual views"], - "deprecated_code": [False, "Whether to enable deprecated code"], - "examples": [False, "Whether to build examples"], - "hpx_async_dispatch": [False, "Whether HPX supports asynchronous dispath"], - "tuning": [False, "Create bindings for tuning tools"], - "tests": [False, "Build for tests"], - } - - spack_micro_arch_map = { - "thunderx2": "THUNDERX2", - "zen": "ZEN", - "zen2": "ZEN2", - "zen3": "ZEN3", - "steamroller": "KAVERI", - "excavator": "CARIZO", - "power7": "POWER7", - "power8": "POWER8", - "power9": "POWER9", - "power8le": "POWER8", - "power9le": "POWER9", - "sandybridge": "SNB", - "haswell": "HSW", - "mic_knl": "KNL", - "cannonlake": "SKX", - "cascadelake": "SKX", - "westmere": "WSM", - "ivybridge": "SNB", - "broadwell": "BDW", - # @AndrewGaspar: Kokkos does not have an arch for plain-skylake - only - # for Skylake-X (i.e. Xeon). For now, I'm mapping this to Broadwell - # until Kokkos learns to optimize for SkyLake without the AVX-512 - # extensions. SkyLake with AVX-512 will still be optimized using the - # separate `skylake_avx512` arch. - "skylake": "BDW", - "icelake": "SKX", - "skylake_avx512": "SKX", - } - - spack_cuda_arch_map = { - "30": "kepler30", - "32": "kepler32", - "35": "kepler35", - "37": "kepler37", - "50": "maxwell50", - "52": "maxwell52", - "53": "maxwell53", - "60": "pascal60", - "61": "pascal61", - "70": "volta70", - "72": "volta72", - "75": "turing75", - "80": "ampere80", - "86": "ampere86", - "89": "ada89", - "90": "hopper90", - } - cuda_arches = spack_cuda_arch_map.values() - conflicts("+cuda", when="cuda_arch=none") - - amdgpu_arch_map = { - "gfx900": "vega900", - "gfx906": "vega906", - "gfx908": "vega908", - "gfx90a": "vega90A", - "gfx1030": "navi1030", - "gfx1100": "navi1100", - } - amd_support_conflict_msg = ( - "{0} is not supported; " - "Kokkos supports the following AMD GPU targets: " + ", ".join(amdgpu_arch_map.keys()) - ) - for arch in ROCmPackage.amdgpu_targets: - if arch not in amdgpu_arch_map: - conflicts( - "+rocm", - when="amdgpu_target={0}".format(arch), - msg=amd_support_conflict_msg.format(arch), - ) - - intel_gpu_arches = ( - "intel_gen", - "intel_gen9", - "intel_gen11", - "intel_gen12lp", - "intel_dg1", - "intel_xehp", - "intel_pvc", - ) - variant( - "intel_gpu_arch", - default="none", - values=("none",) + intel_gpu_arches, - description="Intel GPU architecture", - ) - - devices_values = list(devices_variants.keys()) - for dev in devices_variants: - dflt, desc = devices_variants[dev] - variant(dev, default=dflt, description=desc) - conflicts("+cuda", when="+rocm", msg="CUDA and ROCm are not compatible in Kokkos.") - - options_values = list(options_variants.keys()) - for opt in options_values: - if "cuda" in opt: - conflicts("+%s" % opt, when="~cuda", msg="Must enable CUDA to use %s" % opt) - dflt, desc = options_variants[opt] - variant(opt, default=dflt, description=desc) - - tpls_values = list(tpls_variants.keys()) - for tpl in tpls_values: - dflt, desc = tpls_variants[tpl] - variant(tpl, default=dflt, description=desc) - depends_on(tpl, when="+%s" % tpl) - - variant("wrapper", default=False, description="Use nvcc-wrapper for CUDA build") - depends_on("kokkos-nvcc-wrapper", when="+wrapper") - depends_on("kokkos-nvcc-wrapper@develop", when="@develop+wrapper") - depends_on("kokkos-nvcc-wrapper@master", when="@master+wrapper") - conflicts("+wrapper", when="~cuda") - - stds = ["11", "14", "17", "20"] - # TODO: This should be named cxxstd for consistency with other packages - variant("std", default="17", values=stds, multi=False) - variant("pic", default=False, description="Build position independent code") - - conflicts("std=11", when="@3.7:") - conflicts("std=14", when="@4.0:") - - conflicts("+cuda", when="std=17 ^cuda@:10") - conflicts("+cuda", when="std=20 ^cuda@:11") - - # SYCL and OpenMPTarget require C++17 or higher - for stdver in stds[: stds.index("17")]: - conflicts("+sycl", when="std={0}".format(stdver), msg="SYCL requires C++17 or higher") - conflicts( - "+openmptarget", - when="std={0}".format(stdver), - msg="OpenMPTarget requires C++17 or higher", - ) - - # HPX should use the same C++ standard - for std in stds: - depends_on("hpx cxxstd={0}".format(std), when="+hpx std={0}".format(std)) - - # HPX version constraints - depends_on("hpx@:1.6", when="@:3.5 +hpx") - depends_on("hpx@1.7:", when="@3.6: +hpx") - - # Patches - patch("hpx_profiling_fences.patch", when="@3.5.00 +hpx") - - variant("shared", default=True, description="Build shared libraries") - - # Filter spack-generated files that may include links to the - # spack compiler wrappers - filter_compiler_wrappers("kokkos_launch_compiler", relative_root="bin") - filter_compiler_wrappers( - "KokkosConfigCommon.cmake", relative_root=os.path.join("lib64", "cmake", "Kokkos") - ) - - @classmethod - def get_microarch(cls, target): - """Get the Kokkos microarch name for a Spack target (spec.target).""" - smam = cls.spack_micro_arch_map - - # Find closest ancestor that has a known microarch optimization - if target.name not in smam: - for target in target.ancestors: - if target.name in smam: - break - else: - # No known microarch optimizatinos - return None - - return smam[target.name] - - def append_args(self, cmake_prefix, cmake_options, spack_options): - variant_to_cmake_option = {"rocm": "hip"} - for variant_name in cmake_options: - opt = variant_to_cmake_option.get(variant_name, variant_name) - optname = "Kokkos_%s_%s" % (cmake_prefix, opt.upper()) - # Explicitly enable or disable - option = self.define_from_variant(optname, variant_name) - if option not in spack_options: - spack_options.append(option) - - def setup_dependent_package(self, module, dependent_spec): - try: - self.spec.kokkos_cxx = self.spec["kokkos-nvcc-wrapper"].kokkos_cxx - except Exception: - self.spec.kokkos_cxx = spack_cxx - - def cmake_args(self): - spec = self.spec - from_variant = self.define_from_variant - - if spec.satisfies("~wrapper+cuda") and not ( - spec.satisfies("%clang") or spec.satisfies("%cce") - ): - raise InstallError("Kokkos requires +wrapper when using +cuda" "without clang") - - options = [ - from_variant("CMAKE_POSITION_INDEPENDENT_CODE", "pic"), - from_variant("CMAKE_CXX_STANDARD", "std"), - from_variant("BUILD_SHARED_LIBS", "shared"), - ] - - spack_microarches = [] - if "+cuda" in spec: - # this is a list - for cuda_arch in spec.variants["cuda_arch"].value: - if not cuda_arch == "none": - kokkos_arch_name = self.spack_cuda_arch_map[cuda_arch] - spack_microarches.append(kokkos_arch_name) - - kokkos_microarch_name = self.get_microarch(spec.target) - if kokkos_microarch_name: - spack_microarches.append(kokkos_microarch_name) - - if "+rocm" in spec: - for amdgpu_target in spec.variants["amdgpu_target"].value: - if amdgpu_target != "none": - if amdgpu_target in self.amdgpu_arch_map: - spack_microarches.append(self.amdgpu_arch_map[amdgpu_target]) - else: - # Note that conflict declarations should prevent - # choosing an unsupported AMD GPU target - raise SpackError("Unsupported target: {0}".format(amdgpu_target)) - - if self.spec.variants["intel_gpu_arch"].value != "none": - spack_microarches.append(self.spec.variants["intel_gpu_arch"].value) - - for arch in spack_microarches: - options.append(self.define("Kokkos_ARCH_" + arch.upper(), True)) - - self.append_args("ENABLE", self.devices_values, options) - self.append_args("ENABLE", self.options_values, options) - self.append_args("ENABLE", self.tpls_values, options) - - for tpl in self.tpls_values: - if spec.variants[tpl].value: - options.append(self.define(tpl + "_DIR", spec[tpl].prefix)) - - if "+rocm" in self.spec: - options.append(self.define("CMAKE_CXX_COMPILER", self.spec["hip"].hipcc)) - elif "+wrapper" in self.spec: - options.append( - self.define("CMAKE_CXX_COMPILER", self.spec["kokkos-nvcc-wrapper"].kokkos_cxx) - ) - - return options - - test_script_relative_path = join_path("scripts", "spack_test") - - # TODO: Replace this method and its 'get' use for cmake path with - # join_path(self.spec['cmake'].prefix.bin, 'cmake') once stand-alone - # tests can access build dependencies through self.spec['cmake']. - def cmake_bin(self, set=True): - """(Hack) Set/get cmake dependency path.""" - filepath = join_path(self.install_test_root, "cmake_bin_path.txt") - if set: - with open(filepath, "w") as out_file: - cmake_bin = join_path(self.spec["cmake"].prefix.bin, "cmake") - out_file.write("{0}\n".format(cmake_bin)) - elif os.path.isfile(filepath): - with open(filepath, "r") as in_file: - return in_file.read().strip() - - @run_after("install") - def setup_build_tests(self): - # Skip if unsupported version - cmake_source_path = join_path(self.stage.source_path, self.test_script_relative_path) - if not os.path.exists(cmake_source_path): - return - """Copy test.""" - cmake_out_path = join_path(self.test_script_relative_path, "out") - cmake_args = [ - cmake_source_path, - "-DSPACK_PACKAGE_SOURCE_DIR:PATH={0}".format(self.stage.source_path), - "-DSPACK_PACKAGE_TEST_ROOT_DIR:PATH={0}".format( - join_path(self.install_test_root, cmake_out_path) - ), - "-DSPACK_PACKAGE_INSTALL_DIR:PATH={0}".format(self.prefix), - ] - cmake(*cmake_args) - self.cache_extra_test_sources(cmake_out_path) - self.cmake_bin(set=True) - - def build_tests(self, cmake_path): - """Build test.""" - cmake_bin = self.cmake_bin(set=False) - - if not cmake_bin: - tty.msg("Skipping kokkos test: cmake_bin_path.txt not found") - return - - cmake_args = [cmake_path, "-DEXECUTABLE_OUTPUT_PATH=" + cmake_path] - - if not self.run_test(cmake_bin, options=cmake_args, purpose="Generate the Makefile"): - tty.warn("Skipping kokkos test: failed to generate Makefile") - return - - if not self.run_test("make", purpose="Build test software"): - tty.warn("Skipping kokkos test: failed to build test") - - def run_tests(self, cmake_path): - """Run test.""" - if not self.run_test( - "make", options=[cmake_path, "test"], purpose="Checking ability to execute." - ): - tty.warn("Failed to run kokkos test") - - def test(self): - # Skip if unsupported version - cmake_path = join_path( - self.test_suite.current_test_cache_dir, self.test_script_relative_path, "out" - ) - - if not os.path.exists(cmake_path): - tty.warn("Skipping smoke tests: {0} is missing".format(cmake_path)) - return - - self.build_tests(cmake_path) - self.run_tests(cmake_path) From eaf824d88af67535bb3ffc656a14f1551d661f3f Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 14:19:39 +0800 Subject: [PATCH 11/21] Removed LLVM - just added some versions. --- repo/packages/llvm/D133513.diff | 29 - repo/packages/llvm/constexpr_longdouble.patch | 28 - .../llvm/constexpr_longdouble_9.0.patch | 38 - .../llvm/libomp-libflags-as-list.patch | 14 - .../llvm/lldb_external_ncurses-10.patch | 31 - repo/packages/llvm/llvm-gcc11.patch | 9 - repo/packages/llvm/llvm12-thread.patch | 31 - repo/packages/llvm/llvm13-14-thread.patch | 19 - repo/packages/llvm/llvm13-fujitsu.patch | 15 - repo/packages/llvm/llvm14-hwloc-ompd.patch | 13 - repo/packages/llvm/llvm15-thread.patch | 23 - .../packages/llvm/llvm4-lld-ELF-Symbols.patch | 112 --- .../packages/llvm/llvm5-lld-ELF-Symbols.patch | 33 - .../packages/llvm/llvm5-sanitizer-ustat.patch | 25 - repo/packages/llvm/llvm7_intel.patch | 50 -- repo/packages/llvm/llvm_gcc7.patch | 10 - repo/packages/llvm/llvm_py37.patch | 37 - repo/packages/llvm/llvm_python_path.patch | 14 - repo/packages/llvm/missing-includes.patch | 23 - repo/packages/llvm/no_cyclades.patch | 81 -- repo/packages/llvm/no_cyclades9.patch | 42 - repo/packages/llvm/package.py | 846 ------------------ .../llvm/sanitizer-ipc_perm_mode.patch | 9 - repo/packages/llvm/thread-p9.patch | 16 - .../llvm/xray_buffer_queue-cstddef.patch | 5 - 25 files changed, 1553 deletions(-) delete mode 100644 repo/packages/llvm/D133513.diff delete mode 100644 repo/packages/llvm/constexpr_longdouble.patch delete mode 100644 repo/packages/llvm/constexpr_longdouble_9.0.patch delete mode 100644 repo/packages/llvm/libomp-libflags-as-list.patch delete mode 100644 repo/packages/llvm/lldb_external_ncurses-10.patch delete mode 100644 repo/packages/llvm/llvm-gcc11.patch delete mode 100644 repo/packages/llvm/llvm12-thread.patch delete mode 100644 repo/packages/llvm/llvm13-14-thread.patch delete mode 100644 repo/packages/llvm/llvm13-fujitsu.patch delete mode 100644 repo/packages/llvm/llvm14-hwloc-ompd.patch delete mode 100644 repo/packages/llvm/llvm15-thread.patch delete mode 100644 repo/packages/llvm/llvm4-lld-ELF-Symbols.patch delete mode 100644 repo/packages/llvm/llvm5-lld-ELF-Symbols.patch delete mode 100644 repo/packages/llvm/llvm5-sanitizer-ustat.patch delete mode 100644 repo/packages/llvm/llvm7_intel.patch delete mode 100644 repo/packages/llvm/llvm_gcc7.patch delete mode 100644 repo/packages/llvm/llvm_py37.patch delete mode 100644 repo/packages/llvm/llvm_python_path.patch delete mode 100644 repo/packages/llvm/missing-includes.patch delete mode 100644 repo/packages/llvm/no_cyclades.patch delete mode 100644 repo/packages/llvm/no_cyclades9.patch delete mode 100644 repo/packages/llvm/package.py delete mode 100644 repo/packages/llvm/sanitizer-ipc_perm_mode.patch delete mode 100644 repo/packages/llvm/thread-p9.patch delete mode 100644 repo/packages/llvm/xray_buffer_queue-cstddef.patch diff --git a/repo/packages/llvm/D133513.diff b/repo/packages/llvm/D133513.diff deleted file mode 100644 index 54849b8e..00000000 --- a/repo/packages/llvm/D133513.diff +++ /dev/null @@ -1,29 +0,0 @@ -Index: lldb/bindings/python/get-python-config.py -=================================================================== ---- lldb/bindings/python/get-python-config.py -+++ lldb/bindings/python/get-python-config.py -@@ -44,15 +44,21 @@ - elif args.variable_name == "LLDB_PYTHON_EXE_RELATIVE_PATH": - tried = list() - exe = sys.executable -- prefix = os.path.realpath(sys.prefix) -+ prefix = sys.prefix - while True: - try: - print(relpath_nodots(exe, prefix)) - break - except ValueError: - tried.append(exe) -- if os.path.islink(exe): -- exe = os.path.join(os.path.realpath(os.path.dirname(exe)), os.readlink(exe)) -+ real_exe_dirname = os.path.realpath(os.path.dirname(exe)) -+ real_prefix = os.path.realpath(prefix) -+ if prefix != real_prefix: -+ prefix = real_prefix -+ exe = os.path.join(real_exe_dirname, os.path.basename(exe)) -+ continue -+ elif os.path.islink(exe): -+ exe = os.path.join(real_exe_dirname, os.readlink(exe)) - continue - else: - print("Could not find a relative path to sys.executable under sys.prefix", file=sys.stderr) diff --git a/repo/packages/llvm/constexpr_longdouble.patch b/repo/packages/llvm/constexpr_longdouble.patch deleted file mode 100644 index 8b90001d..00000000 --- a/repo/packages/llvm/constexpr_longdouble.patch +++ /dev/null @@ -1,28 +0,0 @@ -From 3bf63cf3b366d3a57cf5cbad4112a6abf6c0c3b1 Mon Sep 17 00:00:00 2001 -From: Marshall Clow -Date: Tue, 2 Apr 2019 14:46:36 +0000 -Subject: [PATCH] Special case some duration arithmetic for GCC and PPC because - their long double constant folding is broken. Fixes PR#39696. - -llvm-svn: 357478 ---- - libcxx/include/thread | 5 +++++ - 1 file changed, 5 insertions(+) - -diff --git a/libcxx/include/thread b/libcxx/include/thread -index df06ff70f8e37f22f4108be8e5e79a38052a11dd..400459ae7f32c4d7cd24b2d85c49d789500e432d 100644 ---- a/libcxx/include/thread -+++ b/libcxx/include/thread -@@ -434,7 +434,12 @@ sleep_for(const chrono::duration<_Rep, _Period>& __d) - using namespace chrono; - if (__d > duration<_Rep, _Period>::zero()) - { -+#if defined(_LIBCPP_COMPILER_GCC) && (__powerpc__ || __POWERPC__) -+ // GCC's long double const folding is incomplete for IBM128 long doubles. -+ _LIBCPP_CONSTEXPR duration _Max = duration(ULLONG_MAX/1000000000ULL) ; -+#else - _LIBCPP_CONSTEXPR duration _Max = nanoseconds::max(); -+#endif - nanoseconds __ns; - if (__d < _Max) - { diff --git a/repo/packages/llvm/constexpr_longdouble_9.0.patch b/repo/packages/llvm/constexpr_longdouble_9.0.patch deleted file mode 100644 index 9a62f270..00000000 --- a/repo/packages/llvm/constexpr_longdouble_9.0.patch +++ /dev/null @@ -1,38 +0,0 @@ -From d9a42ec98adcb1ebc0c3837715df4e5a50c7ccc0 Mon Sep 17 00:00:00 2001 -From: "Joel E. Denny" -Date: Wed, 10 Jun 2020 12:40:43 -0400 -Subject: [PATCH] [libc++] Work around gcc/Power9 bug in `include/thread` - -This fixes PR39696, which breaks the libcxx build with gcc (I tested -7.5.0) on Power9. This fix was suggested at - -https://bugs.llvm.org/show_bug.cgi?id=39696#c38 - -but never applied. It just reverts 0583d9ea8d5e, which reverses -components of the original fix in 3bf63cf3b366, which is correct. - -Fixes https://llvm.org/PR39696 - -Reviewed By: ldionne - -Differential Revision: https://reviews.llvm.org/D81438 ---- - libcxx/include/thread | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/libcxx/include/thread b/libcxx/include/thread -index 22aa4f201295867cff57b7a944e6b7bd67b22ad3..6eff1800acdbef09eae4417eee977fa350c596ea 100644 ---- a/libcxx/include/thread -+++ b/libcxx/include/thread -@@ -365,9 +365,9 @@ sleep_for(const chrono::duration<_Rep, _Period>& __d) - { - #if defined(_LIBCPP_COMPILER_GCC) && (__powerpc__ || __POWERPC__) - // GCC's long double const folding is incomplete for IBM128 long doubles. -- _LIBCPP_CONSTEXPR duration _Max = nanoseconds::max(); --#else - _LIBCPP_CONSTEXPR duration _Max = duration(ULLONG_MAX/1000000000ULL) ; -+#else -+ _LIBCPP_CONSTEXPR duration _Max = nanoseconds::max(); - #endif - nanoseconds __ns; - if (__d < _Max) diff --git a/repo/packages/llvm/libomp-libflags-as-list.patch b/repo/packages/llvm/libomp-libflags-as-list.patch deleted file mode 100644 index 995f55a4..00000000 --- a/repo/packages/llvm/libomp-libflags-as-list.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff --git a/openmp/runtime/cmake/LibompHandleFlags.cmake b/openmp/runtime/cmake/LibompHandleFlags.cmake -index 9e19e59ba17d..f92fa12d851a 100644 ---- a/openmp/runtime/cmake/LibompHandleFlags.cmake -+++ b/openmp/runtime/cmake/LibompHandleFlags.cmake -@@ -144,7 +144,8 @@ function(libomp_get_libflags libflags) - endif() - set(libflags_local ${libflags_local} ${LIBOMP_LIBFLAGS}) - libomp_setup_flags(libflags_local) -- set(${libflags} ${libflags_local} PARENT_SCOPE) -+ libomp_string_to_list("${libflags_local}" libflags_local_list) -+ set(${libflags} ${libflags_local_list} PARENT_SCOPE) - endfunction() - - # Fortran flags diff --git a/repo/packages/llvm/lldb_external_ncurses-10.patch b/repo/packages/llvm/lldb_external_ncurses-10.patch deleted file mode 100644 index 34ed0e3c..00000000 --- a/repo/packages/llvm/lldb_external_ncurses-10.patch +++ /dev/null @@ -1,31 +0,0 @@ -diff --git a/lldb/include/lldb/Host/Config.h.cmake b/lldb/include/lldb/Host/Config.h.cmake ---- a/lldb/include/lldb/Host/Config.h.cmake -+++ b/lldb/include/lldb/Host/Config.h.cmake -@@ -38,6 +38,8 @@ - - #cmakedefine01 LLDB_ENABLE_CURSES - -+#cmakedefine01 CURSES_HAVE_NCURSES_CURSES_H -+ - #cmakedefine01 LLDB_ENABLE_LIBEDIT - - #cmakedefine01 LLDB_ENABLE_LIBXML2 -diff --git a/lldb/source/Core/IOHandlerCursesGUI.cpp b/lldb/source/Core/IOHandlerCursesGUI.cpp ---- a/lldb/source/Core/IOHandlerCursesGUI.cpp -+++ b/lldb/source/Core/IOHandlerCursesGUI.cpp -@@ -10,9 +10,14 @@ - #include "lldb/Host/Config.h" - - #if LLDB_ENABLE_CURSES -+#if CURSES_HAVE_NCURSES_CURSES_H -+#include -+#include -+#else - #include - #include - #endif -+#endif - - #if defined(__APPLE__) - #include - diff --git a/repo/packages/llvm/llvm-gcc11.patch b/repo/packages/llvm/llvm-gcc11.patch deleted file mode 100644 index 8e081e87..00000000 --- a/repo/packages/llvm/llvm-gcc11.patch +++ /dev/null @@ -1,9 +0,0 @@ ---- a/llvm/utils/benchmark/src/benchmark_register.h -+++ b/llvm/utils/benchmark/src/benchmark_register.h -@@ -2,6 +2,7 @@ - #define BENCHMARK_REGISTER_H - - #include -+#include - - #include "check.h" diff --git a/repo/packages/llvm/llvm12-thread.patch b/repo/packages/llvm/llvm12-thread.patch deleted file mode 100644 index bbe3c253..00000000 --- a/repo/packages/llvm/llvm12-thread.patch +++ /dev/null @@ -1,31 +0,0 @@ -diff --git a/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake b/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake -index e3c2a580396e..5f76992d193e 100644 ---- a/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake -+++ b/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake -@@ -249,3 +249,6 @@ if (NOT LIBOMPTARGET_CUDA_TOOLKIT_ROOT_DIR_PRESET AND - endif() - endif() - endif() -+ -+find_package(Threads REQUIRED) -+set(OPENMP_PTHREAD_LIB ${CMAKE_THREAD_LIBS_INIT}) -diff --git a/openmp/libomptarget/src/CMakeLists.txt b/openmp/libomptarget/src/CMakeLists.txt -index 15e6c3bbaf1f..3e5a73504a08 100644 ---- a/openmp/libomptarget/src/CMakeLists.txt -+++ b/openmp/libomptarget/src/CMakeLists.txt -@@ -30,6 +30,7 @@ if(OPENMP_STANDALONE_BUILD OR (NOT OPENMP_ENABLE_LIBOMPTARGET_PROFILING)) - add_library(omptarget SHARED ${LIBOMPTARGET_SRC_FILES}) - target_link_libraries(omptarget - ${CMAKE_DL_LIBS} -+ ${OPENMP_PTHREAD_LIB} - "-Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/exports") - else() - set(LLVM_LINK_COMPONENTS -@@ -37,6 +38,7 @@ else() - ) - add_llvm_library(omptarget SHARED ${LIBOMPTARGET_SRC_FILES} - LINK_LIBS ${CMAKE_DL_LIBS} -+ ${OPENMP_PTHREAD_LIB} - "-Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/exports" - ) - target_compile_definitions(omptarget PUBLIC OMPTARGET_PROFILE_ENABLED) diff --git a/repo/packages/llvm/llvm13-14-thread.patch b/repo/packages/llvm/llvm13-14-thread.patch deleted file mode 100644 index 0067a930..00000000 --- a/repo/packages/llvm/llvm13-14-thread.patch +++ /dev/null @@ -1,19 +0,0 @@ ---- spack-src/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake.org 2022-02-08 14:58:13.000000000 +0900 -+++ spack-src/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake 2022-02-08 13:58:53.000000000 +0900 -@@ -276,4 +276,5 @@ - endif() - endif() - --set(OPENMP_PTHREAD_LIB ${LLVM_PTHREAD_LIB}) -+find_package(Threads REQUIRED) -+set(OPENMP_PTHREAD_LIB ${CMAKE_THREAD_LIBS_INIT}) ---- spack-src/openmp/libomptarget/src/CMakeLists.txt.org 2022-02-09 08:49:35.000000000 +0900 -+++ spack-src/openmp/libomptarget/src/CMakeLists.txt 2022-02-09 08:50:18.000000000 +0900 -@@ -36,6 +36,7 @@ - endif() - target_link_libraries(omptarget PRIVATE - ${CMAKE_DL_LIBS} -+ ${OPENMP_PTHREAD_LIB} - "-Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/exports") - - # Install libomptarget under the lib destination folder. diff --git a/repo/packages/llvm/llvm13-fujitsu.patch b/repo/packages/llvm/llvm13-fujitsu.patch deleted file mode 100644 index aa215bcf..00000000 --- a/repo/packages/llvm/llvm13-fujitsu.patch +++ /dev/null @@ -1,15 +0,0 @@ ---- spack-src/libcxx/include/__config.org 2022-02-03 14:36:11.000000000 +0900 -+++ spack-src/libcxx/include/__config 2022-02-04 08:39:59.000000000 +0900 -@@ -52,7 +52,11 @@ - # elif __cplusplus <= 201703L - # define _LIBCPP_STD_VER 17 - # elif __cplusplus <= 202002L --# define _LIBCPP_STD_VER 20 -+# if defined(__FUJITSU) || defined(__CLANG_FUJITSU) -+# define _LIBCPP_STD_VER 17 -+# else -+# define _LIBCPP_STD_VER 20 -+# endif - # else - # define _LIBCPP_STD_VER 21 // current year, or date of c++2b ratification - # endif diff --git a/repo/packages/llvm/llvm14-hwloc-ompd.patch b/repo/packages/llvm/llvm14-hwloc-ompd.patch deleted file mode 100644 index bdae92e0..00000000 --- a/repo/packages/llvm/llvm14-hwloc-ompd.patch +++ /dev/null @@ -1,13 +0,0 @@ ---- a/openmp/libompd/src/CMakeLists.txt -+++ b/openmp/libompd/src/CMakeLists.txt -@@ -44,6 +44,10 @@ - ${LIBOMP_SRC_DIR} - ) - -+if(${LIBOMP_USE_HWLOC}) -+ include_directories(${LIBOMP_HWLOC_INSTALL_DIR}/include) -+endif() -+ - INSTALL( TARGETS ompd - LIBRARY DESTINATION ${OPENMP_INSTALL_LIBDIR} - ARCHIVE DESTINATION ${OPENMP_INSTALL_LIBDIR} diff --git a/repo/packages/llvm/llvm15-thread.patch b/repo/packages/llvm/llvm15-thread.patch deleted file mode 100644 index cffb5591..00000000 --- a/repo/packages/llvm/llvm15-thread.patch +++ /dev/null @@ -1,23 +0,0 @@ -diff --git a/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake b/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake -index 1f2a50667c4f..d3ff232f6bd3 100644 ---- a/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake -+++ b/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake -@@ -280,4 +280,5 @@ if (NOT LIBOMPTARGET_CUDA_TOOLKIT_ROOT_DIR_PRESET AND - endif() - endif() - --set(OPENMP_PTHREAD_LIB ${LLVM_PTHREAD_LIB}) -+find_package(Threads REQUIRED) -+set(OPENMP_PTHREAD_LIB Threads::Threads) -diff --git a/openmp/libomptarget/src/CMakeLists.txt b/openmp/libomptarget/src/CMakeLists.txt -index 071ec61889a2..b782c3b07e6f 100644 ---- a/openmp/libomptarget/src/CMakeLists.txt -+++ b/openmp/libomptarget/src/CMakeLists.txt -@@ -33,6 +33,7 @@ add_llvm_library(omptarget - LINK_LIBS - PRIVATE - ${CMAKE_DL_LIBS} -+ ${OPENMP_PTHREAD_LIB} - "-Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/exports" - NO_INSTALL_RPATH - ) diff --git a/repo/packages/llvm/llvm4-lld-ELF-Symbols.patch b/repo/packages/llvm/llvm4-lld-ELF-Symbols.patch deleted file mode 100644 index 1a86cda3..00000000 --- a/repo/packages/llvm/llvm4-lld-ELF-Symbols.patch +++ /dev/null @@ -1,112 +0,0 @@ ---- a/lldb/include/lldb/Utility/TaskPool.h -+++ b/lldb/include/lldb/Utility/TaskPool.h -@@ -33,6 +33,7 @@ - #include - #include - #include -+#include - - // Global TaskPool class for running tasks in parallel on a set of worker thread - // created the first -# Fix lld templates: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=230463 ---- a/lld/ELF/LTO.cpp -+++ b/lld/ELF/LTO.cpp -@@ -158,7 +158,7 @@ - return Ret; - } - --template void BitcodeCompiler::template add(BitcodeFile &); --template void BitcodeCompiler::template add(BitcodeFile &); --template void BitcodeCompiler::template add(BitcodeFile &); --template void BitcodeCompiler::template add(BitcodeFile &); -+template void BitcodeCompiler::add(BitcodeFile &); -+template void BitcodeCompiler::add(BitcodeFile &); -+template void BitcodeCompiler::add(BitcodeFile &); -+template void BitcodeCompiler::add(BitcodeFile &); ---- a/lld/ELF/Symbols.cpp -+++ b/lld/ELF/Symbols.cpp -@@ -343,45 +343,45 @@ - template bool SymbolBody::hasThunk() const; - template bool SymbolBody::hasThunk() const; - --template uint32_t SymbolBody::template getVA(uint32_t) const; --template uint32_t SymbolBody::template getVA(uint32_t) const; --template uint64_t SymbolBody::template getVA(uint64_t) const; --template uint64_t SymbolBody::template getVA(uint64_t) const; -- --template uint32_t SymbolBody::template getGotVA() const; --template uint32_t SymbolBody::template getGotVA() const; --template uint64_t SymbolBody::template getGotVA() const; --template uint64_t SymbolBody::template getGotVA() const; -- --template uint32_t SymbolBody::template getGotOffset() const; --template uint32_t SymbolBody::template getGotOffset() const; --template uint64_t SymbolBody::template getGotOffset() const; --template uint64_t SymbolBody::template getGotOffset() const; -- --template uint32_t SymbolBody::template getGotPltVA() const; --template uint32_t SymbolBody::template getGotPltVA() const; --template uint64_t SymbolBody::template getGotPltVA() const; --template uint64_t SymbolBody::template getGotPltVA() const; -- --template uint32_t SymbolBody::template getThunkVA() const; --template uint32_t SymbolBody::template getThunkVA() const; --template uint64_t SymbolBody::template getThunkVA() const; --template uint64_t SymbolBody::template getThunkVA() const; -- --template uint32_t SymbolBody::template getGotPltOffset() const; --template uint32_t SymbolBody::template getGotPltOffset() const; --template uint64_t SymbolBody::template getGotPltOffset() const; --template uint64_t SymbolBody::template getGotPltOffset() const; -- --template uint32_t SymbolBody::template getPltVA() const; --template uint32_t SymbolBody::template getPltVA() const; --template uint64_t SymbolBody::template getPltVA() const; --template uint64_t SymbolBody::template getPltVA() const; -- --template uint32_t SymbolBody::template getSize() const; --template uint32_t SymbolBody::template getSize() const; --template uint64_t SymbolBody::template getSize() const; --template uint64_t SymbolBody::template getSize() const; -+template uint32_t SymbolBody::getVA(uint32_t) const; -+template uint32_t SymbolBody::getVA(uint32_t) const; -+template uint64_t SymbolBody::getVA(uint64_t) const; -+template uint64_t SymbolBody::getVA(uint64_t) const; -+ -+template uint32_t SymbolBody::getGotVA() const; -+template uint32_t SymbolBody::getGotVA() const; -+template uint64_t SymbolBody::getGotVA() const; -+template uint64_t SymbolBody::getGotVA() const; -+ -+template uint32_t SymbolBody::getGotOffset() const; -+template uint32_t SymbolBody::getGotOffset() const; -+template uint64_t SymbolBody::getGotOffset() const; -+template uint64_t SymbolBody::getGotOffset() const; -+ -+template uint32_t SymbolBody::getGotPltVA() const; -+template uint32_t SymbolBody::getGotPltVA() const; -+template uint64_t SymbolBody::getGotPltVA() const; -+template uint64_t SymbolBody::getGotPltVA() const; -+ -+template uint32_t SymbolBody::getThunkVA() const; -+template uint32_t SymbolBody::getThunkVA() const; -+template uint64_t SymbolBody::getThunkVA() const; -+template uint64_t SymbolBody::getThunkVA() const; -+ -+template uint32_t SymbolBody::getGotPltOffset() const; -+template uint32_t SymbolBody::getGotPltOffset() const; -+template uint64_t SymbolBody::getGotPltOffset() const; -+template uint64_t SymbolBody::getGotPltOffset() const; -+ -+template uint32_t SymbolBody::getPltVA() const; -+template uint32_t SymbolBody::getPltVA() const; -+template uint64_t SymbolBody::getPltVA() const; -+template uint64_t SymbolBody::getPltVA() const; -+ -+template uint32_t SymbolBody::getSize() const; -+template uint32_t SymbolBody::getSize() const; -+template uint64_t SymbolBody::getSize() const; -+template uint64_t SymbolBody::getSize() const; - - template class elf::Undefined; - template class elf::Undefined; diff --git a/repo/packages/llvm/llvm5-lld-ELF-Symbols.patch b/repo/packages/llvm/llvm5-lld-ELF-Symbols.patch deleted file mode 100644 index 727647d3..00000000 --- a/repo/packages/llvm/llvm5-lld-ELF-Symbols.patch +++ /dev/null @@ -1,33 +0,0 @@ -# Fix lld templates: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=230463 ---- a/lld/ELF/Symbols.cpp -+++ b/lld/ELF/Symbols.cpp -@@ -383,17 +383,17 @@ - return B.getName(); - } - --template uint32_t SymbolBody::template getSize() const; --template uint32_t SymbolBody::template getSize() const; --template uint64_t SymbolBody::template getSize() const; --template uint64_t SymbolBody::template getSize() const; -+template uint32_t SymbolBody::getSize() const; -+template uint32_t SymbolBody::getSize() const; -+template uint64_t SymbolBody::getSize() const; -+template uint64_t SymbolBody::getSize() const; - --template bool DefinedRegular::template isMipsPIC() const; --template bool DefinedRegular::template isMipsPIC() const; --template bool DefinedRegular::template isMipsPIC() const; --template bool DefinedRegular::template isMipsPIC() const; -+template bool DefinedRegular::isMipsPIC() const; -+template bool DefinedRegular::isMipsPIC() const; -+template bool DefinedRegular::isMipsPIC() const; -+template bool DefinedRegular::isMipsPIC() const; - --template uint32_t SharedSymbol::template getAlignment() const; --template uint32_t SharedSymbol::template getAlignment() const; --template uint32_t SharedSymbol::template getAlignment() const; --template uint32_t SharedSymbol::template getAlignment() const; -+template uint32_t SharedSymbol::getAlignment() const; -+template uint32_t SharedSymbol::getAlignment() const; -+template uint32_t SharedSymbol::getAlignment() const; -+template uint32_t SharedSymbol::getAlignment() const; diff --git a/repo/packages/llvm/llvm5-sanitizer-ustat.patch b/repo/packages/llvm/llvm5-sanitizer-ustat.patch deleted file mode 100644 index 531a3c5d..00000000 --- a/repo/packages/llvm/llvm5-sanitizer-ustat.patch +++ /dev/null @@ -1,25 +0,0 @@ -# has been removed from glibc 2.28, -# backport fix from llvm-6.0.1: ---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cc -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cc -@@ -159,1 +159,0 @@ --#include -@@ -252,5 +252,17 @@ - - #if SANITIZER_LINUX && !SANITIZER_ANDROID -- unsigned struct_ustat_sz = sizeof(struct ustat); -+ // Use pre-computed size of struct ustat to avoid which -+ // has been removed from glibc 2.28. -+#if defined(__aarch64__) || defined(__s390x__) || defined (__mips64) \ -+ || defined(__powerpc64__) || defined(__arch64__) || defined(__sparcv9) \ -+ || defined(__x86_64__) -+#define SIZEOF_STRUCT_USTAT 32 -+#elif defined(__arm__) || defined(__i386__) || defined(__mips__) \ -+ || defined(__powerpc__) || defined(__s390__) -+#define SIZEOF_STRUCT_USTAT 20 -+#else -+#error Unknown size of struct ustat -+#endif -+ unsigned struct_ustat_sz = SIZEOF_STRUCT_USTAT; - unsigned struct_rlimit64_sz = sizeof(struct rlimit64); - unsigned struct_statvfs64_sz = sizeof(struct statvfs64); diff --git a/repo/packages/llvm/llvm7_intel.patch b/repo/packages/llvm/llvm7_intel.patch deleted file mode 100644 index 710545a6..00000000 --- a/repo/packages/llvm/llvm7_intel.patch +++ /dev/null @@ -1,50 +0,0 @@ -diff --git a/llvm/include/llvm/ADT/StringExtras.h b/llvm/include/llvm/ADT/StringExtras.h -index 71b0e7527cb..3304a378f37 100644 ---- a/llvm/include/llvm/ADT/StringExtras.h -+++ b/llvm/include/llvm/ADT/StringExtras.h -@@ -369,7 +369,7 @@ inline size_t join_items_size(const A1 &A, Args &&... Items) { - template - inline std::string join(IteratorT Begin, IteratorT End, StringRef Separator) { - using tag = typename std::iterator_traits::iterator_category; -- return detail::join_impl(Begin, End, Separator, tag()); -+ return llvm::detail::join_impl(Begin, End, Separator, tag()); - } - - /// Joins the strings in the range [R.begin(), R.end()), adding Separator -diff --git a/llvm/include/llvm/Analysis/BlockFrequencyInfoImpl.h b/llvm/include/llvm/Analysis/BlockFrequencyInfoImpl.h -index 25b2efd33c9..40144d96044 100644 ---- a/llvm/include/llvm/Analysis/BlockFrequencyInfoImpl.h -+++ b/llvm/include/llvm/Analysis/BlockFrequencyInfoImpl.h -@@ -186,8 +186,9 @@ public: - /// topological sort) and it's class is the same regardless of block type. - struct BlockNode { - using IndexType = uint32_t; -+ using IndexTypeLimits = std::numeric_limits; - -- IndexType Index = std::numeric_limits::max(); -+ IndexType Index = IndexTypeLimits::max(); - - BlockNode() = default; - BlockNode(IndexType Index) : Index(Index) {} -diff --git a/llvm/lib/ExecutionEngine/Orc/Core.cpp b/llvm/lib/ExecutionEngine/Orc/Core.cpp -index 4325d57f73d..96e1e1d5503 100644 ---- a/llvm/lib/ExecutionEngine/Orc/Core.cpp -+++ b/llvm/lib/ExecutionEngine/Orc/Core.cpp -@@ -1423,7 +1423,7 @@ VSO::lookupImpl(std::shared_ptr &Q, - if (SymI->second.getAddress() != 0) { - Q->resolve(Name, SymI->second); - if (Q->isFullyResolved()) -- ActionFlags |= NotifyFullyResolved; -+ ActionFlags = static_cast(ActionFlags | NotifyFullyResolved); - } - - // If the symbol is lazy, get the MaterialiaztionUnit for it. -@@ -1456,7 +1456,7 @@ VSO::lookupImpl(std::shared_ptr &Q, - // continue. - Q->notifySymbolReady(); - if (Q->isFullyReady()) -- ActionFlags |= NotifyFullyReady; -+ ActionFlags = static_cast(ActionFlags | NotifyFullyReady); - continue; - } - diff --git a/repo/packages/llvm/llvm_gcc7.patch b/repo/packages/llvm/llvm_gcc7.patch deleted file mode 100644 index c6d9d33a..00000000 --- a/repo/packages/llvm/llvm_gcc7.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- a/lldb/include/lldb/Utility/TaskPool.h 2016-09-06 16:57:50.000000000 -0400 -+++ b/lldb/include/lldb/Utility/TaskPool.h 2017-08-29 16:29:41.448584015 -0400 -@@ -28,6 +28,7 @@ - - #include - #include -+#include - #include - #include - #include diff --git a/repo/packages/llvm/llvm_py37.patch b/repo/packages/llvm/llvm_py37.patch deleted file mode 100644 index 478be879..00000000 --- a/repo/packages/llvm/llvm_py37.patch +++ /dev/null @@ -1,37 +0,0 @@ -From ecdefed7f6ba11421fe1ecc6c13a135ab7bcda73 Mon Sep 17 00:00:00 2001 -From: Pavel Labath -Date: Mon, 23 Jul 2018 11:37:36 +0100 -Subject: [PATCH] Fix PythonString::GetString for >=python-3.7 - -The return value of PyUnicode_AsUTF8AndSize is now "const char *". ---- - .../Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp | 6 ++++-- - 1 file changed, 4 insertions(+), 2 deletions(-) - -diff --git a/tools/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp b/tools/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp -index 6a9d57d5a..94f16b2c7 100644 ---- a/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp -+++ b/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp -@@ -404,14 +404,16 @@ llvm::StringRef PythonString::GetString() const { - return llvm::StringRef(); - - Py_ssize_t size; -- char *c; -+ const char *data; - - #if PY_MAJOR_VERSION >= 3 -- c = PyUnicode_AsUTF8AndSize(m_py_obj, &size); -+ data = PyUnicode_AsUTF8AndSize(m_py_obj, &size); - #else -+ char *c; - PyString_AsStringAndSize(m_py_obj, &c, &size); -+ data = c; - #endif -- return llvm::StringRef(c, size); -+ return llvm::StringRef(data, size); - } - - size_t PythonString::GetSize() const { --- -2.18.0.233.g985f88cf7e-goog - diff --git a/repo/packages/llvm/llvm_python_path.patch b/repo/packages/llvm/llvm_python_path.patch deleted file mode 100644 index 9f821cc3..00000000 --- a/repo/packages/llvm/llvm_python_path.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff --git a/compiler-rt/cmake/Modules/AddCompilerRT.cmake b/compiler-rt/cmake/Modules/AddCompilerRT.cmake -index dab55707338..6f4c6791141 100644 ---- a/compiler-rt/cmake/Modules/AddCompilerRT.cmake -+++ b/compiler-rt/cmake/Modules/AddCompilerRT.cmake -@@ -612,6 +612,9 @@ macro(add_custom_libcxx name prefix) - CMAKE_OBJDUMP - CMAKE_STRIP - CMAKE_SYSROOT -+ PYTHON_EXECUTABLE -+ Python3_EXECUTABLE -+ Python2_EXECUTABLE - CMAKE_SYSTEM_NAME) - foreach(variable ${PASSTHROUGH_VARIABLES}) - get_property(is_value_set CACHE ${variable} PROPERTY VALUE SET) diff --git a/repo/packages/llvm/missing-includes.patch b/repo/packages/llvm/missing-includes.patch deleted file mode 100644 index e88b8fcf..00000000 --- a/repo/packages/llvm/missing-includes.patch +++ /dev/null @@ -1,23 +0,0 @@ -# https://github.com/spack/spack/issues/24270 (This hunk is upstream since llvm-10) ---- a/llvm/include/llvm/Demangle/MicrosoftDemangleNodes.h -+++ b/llvm/include/llvm/Demangle/MicrosoftDemangleNodes.h -@@ -4,6 +4,8 @@ - #include "llvm/Demangle/Compiler.h" - #include "llvm/Demangle/StringView.h" - #include -+#include -+#include - - class OutputStream; - -# https://github.com/spack/spack/pull/27233 ---- a/llvm/utils/benchmark/src/benchmark_register.h -+++ b/llvm/utils/benchmark/src/benchmark_register.h -@@ -2,6 +2,7 @@ - #define BENCHMARK_REGISTER_H - - #include -+#include - - #include "check.h" - diff --git a/repo/packages/llvm/no_cyclades.patch b/repo/packages/llvm/no_cyclades.patch deleted file mode 100644 index 10f9d079..00000000 --- a/repo/packages/llvm/no_cyclades.patch +++ /dev/null @@ -1,81 +0,0 @@ -diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc b/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc ---- a/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc -@@ -370,15 +370,6 @@ - - #if SANITIZER_GLIBC - // _(SIOCDEVPLIP, WRITE, struct_ifreq_sz); // the same as EQL_ENSLAVE -- _(CYGETDEFTHRESH, WRITE, sizeof(int)); -- _(CYGETDEFTIMEOUT, WRITE, sizeof(int)); -- _(CYGETMON, WRITE, struct_cyclades_monitor_sz); -- _(CYGETTHRESH, WRITE, sizeof(int)); -- _(CYGETTIMEOUT, WRITE, sizeof(int)); -- _(CYSETDEFTHRESH, NONE, 0); -- _(CYSETDEFTIMEOUT, NONE, 0); -- _(CYSETTHRESH, NONE, 0); -- _(CYSETTIMEOUT, NONE, 0); - _(EQL_EMANCIPATE, WRITE, struct_ifreq_sz); - _(EQL_ENSLAVE, WRITE, struct_ifreq_sz); - _(EQL_GETMASTRCFG, WRITE, struct_ifreq_sz); -diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h ---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h -@@ -983,7 +983,6 @@ - - #if SANITIZER_LINUX && !SANITIZER_ANDROID - extern unsigned struct_ax25_parms_struct_sz; --extern unsigned struct_cyclades_monitor_sz; - extern unsigned struct_input_keymap_entry_sz; - extern unsigned struct_ipx_config_data_sz; - extern unsigned struct_kbdiacrs_sz; -@@ -1328,15 +1327,6 @@ - #endif // SANITIZER_LINUX - - #if SANITIZER_LINUX && !SANITIZER_ANDROID --extern unsigned IOCTL_CYGETDEFTHRESH; --extern unsigned IOCTL_CYGETDEFTIMEOUT; --extern unsigned IOCTL_CYGETMON; --extern unsigned IOCTL_CYGETTHRESH; --extern unsigned IOCTL_CYGETTIMEOUT; --extern unsigned IOCTL_CYSETDEFTHRESH; --extern unsigned IOCTL_CYSETDEFTIMEOUT; --extern unsigned IOCTL_CYSETTHRESH; --extern unsigned IOCTL_CYSETTIMEOUT; - extern unsigned IOCTL_EQL_EMANCIPATE; - extern unsigned IOCTL_EQL_ENSLAVE; - extern unsigned IOCTL_EQL_GETMASTRCFG; -diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp ---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp -@@ -143,7 +143,6 @@ - # include - #endif - #include --#include - #include - #include - #include -@@ -460,7 +459,6 @@ - - #if SANITIZER_GLIBC - unsigned struct_ax25_parms_struct_sz = sizeof(struct ax25_parms_struct); -- unsigned struct_cyclades_monitor_sz = sizeof(struct cyclades_monitor); - #if EV_VERSION > (0x010000) - unsigned struct_input_keymap_entry_sz = sizeof(struct input_keymap_entry); - #else -@@ -824,15 +822,6 @@ - #endif // SANITIZER_LINUX - - #if SANITIZER_LINUX && !SANITIZER_ANDROID -- unsigned IOCTL_CYGETDEFTHRESH = CYGETDEFTHRESH; -- unsigned IOCTL_CYGETDEFTIMEOUT = CYGETDEFTIMEOUT; -- unsigned IOCTL_CYGETMON = CYGETMON; -- unsigned IOCTL_CYGETTHRESH = CYGETTHRESH; -- unsigned IOCTL_CYGETTIMEOUT = CYGETTIMEOUT; -- unsigned IOCTL_CYSETDEFTHRESH = CYSETDEFTHRESH; -- unsigned IOCTL_CYSETDEFTIMEOUT = CYSETDEFTIMEOUT; -- unsigned IOCTL_CYSETTHRESH = CYSETTHRESH; -- unsigned IOCTL_CYSETTIMEOUT = CYSETTIMEOUT; - unsigned IOCTL_EQL_EMANCIPATE = EQL_EMANCIPATE; - unsigned IOCTL_EQL_ENSLAVE = EQL_ENSLAVE; - unsigned IOCTL_EQL_GETMASTRCFG = EQL_GETMASTRCFG; diff --git a/repo/packages/llvm/no_cyclades9.patch b/repo/packages/llvm/no_cyclades9.patch deleted file mode 100644 index 7532865e..00000000 --- a/repo/packages/llvm/no_cyclades9.patch +++ /dev/null @@ -1,42 +0,0 @@ ---- a/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc -@@ -370,9 +370,0 @@ -- _(CYGETDEFTHRESH, WRITE, sizeof(int)); -- _(CYGETDEFTIMEOUT, WRITE, sizeof(int)); -- _(CYGETMON, WRITE, struct_cyclades_monitor_sz); -- _(CYGETTHRESH, WRITE, sizeof(int)); -- _(CYGETTIMEOUT, WRITE, sizeof(int)); -- _(CYSETDEFTHRESH, NONE, 0); -- _(CYSETDEFTIMEOUT, NONE, 0); -- _(CYSETTHRESH, NONE, 0); -- _(CYSETTIMEOUT, NONE, 0); ---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h -@@ -986,1 +986,0 @@ -- extern unsigned struct_cyclades_monitor_sz; -@@ -1331,9 +1327,0 @@ -- extern unsigned IOCTL_CYGETDEFTHRESH; -- extern unsigned IOCTL_CYGETDEFTIMEOUT; -- extern unsigned IOCTL_CYGETMON; -- extern unsigned IOCTL_CYGETTHRESH; -- extern unsigned IOCTL_CYGETTIMEOUT; -- extern unsigned IOCTL_CYSETDEFTHRESH; -- extern unsigned IOCTL_CYSETDEFTIMEOUT; -- extern unsigned IOCTL_CYSETTHRESH; -- extern unsigned IOCTL_CYSETTIMEOUT; ---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cc -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cc -@@ -143,1 +143,0 @@ --#include -@@ -460,1 +459,0 @@ -- unsigned struct_cyclades_monitor_sz = sizeof(struct cyclades_monitor); -@@ -824,9 +822,0 @@ -- unsigned IOCTL_CYGETDEFTHRESH = CYGETDEFTHRESH; -- unsigned IOCTL_CYGETDEFTIMEOUT = CYGETDEFTIMEOUT; -- unsigned IOCTL_CYGETMON = CYGETMON; -- unsigned IOCTL_CYGETTHRESH = CYGETTHRESH; -- unsigned IOCTL_CYGETTIMEOUT = CYGETTIMEOUT; -- unsigned IOCTL_CYSETDEFTHRESH = CYSETDEFTHRESH; -- unsigned IOCTL_CYSETDEFTIMEOUT = CYSETDEFTIMEOUT; -- unsigned IOCTL_CYSETTHRESH = CYSETTHRESH; -- unsigned IOCTL_CYSETTIMEOUT = CYSETTIMEOUT; diff --git a/repo/packages/llvm/package.py b/repo/packages/llvm/package.py deleted file mode 100644 index 64e69d01..00000000 --- a/repo/packages/llvm/package.py +++ /dev/null @@ -1,846 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# Just version upgrades -import os -import os.path -import re -import sys - -import llnl.util.tty as tty - -import spack.build_environment -import spack.util.executable -from spack.package import * - - -class Llvm(CMakePackage, CudaPackage): - """The LLVM Project is a collection of modular and reusable compiler and - toolchain technologies. Despite its name, LLVM has little to do - with traditional virtual machines, though it does provide helpful - libraries that can be used to build them. The name "LLVM" itself - is not an acronym; it is the full name of the project. - """ - - homepage = "https://llvm.org/" - url = "https://github.com/llvm/llvm-project/archive/llvmorg-7.1.0.tar.gz" - list_url = "https://releases.llvm.org/download.html" - git = "https://github.com/llvm/llvm-project" - maintainers = ["trws", "haampie"] - - tags = ["e4s"] - - generator = "Ninja" - - family = "compiler" # Used by lmod - - # fmt: off - version("main", branch="main") - version("15.0.4", sha256="e24b4d3bf7821dcb1c901d1e09096c1f88fb00095c5a6ef893baab4836975e52") - version("15.0.3", sha256="8ac8e4c0982bf236526d737d385db5e1e66543ab217a9355d54159659eae3774") - version("15.0.2", sha256="dc11d35e60ab61792baa607dff080c993b39de23fb93b3d3369ba15b0601c307") - version("15.0.1", sha256="20bccb964e39f604fdc16d1258f94d2053fbdcdab2b2f6d5e20e6095ec403c00") - version("15.0.0", sha256="36d83cd84e1caf2bcfda1669c029e2b949adb9860cff01e7d3246ac2348b11ae") - version("14.0.6", sha256="98f15f842700bdb7220a166c8d2739a03a72e775b67031205078f39dd756a055") - version("14.0.5", sha256="a4a57f029cb81f04618e05853f05fc2d21b64353c760977d8e7799bf7218a23a") - version("14.0.4", sha256="1333236f9bee38658762076be4236cb5ebf15ae9b7f2bfce6946b96ae962dc73") - version("14.0.3", sha256="0e1d049b050127ecf6286107e9a4400b0550f841d5d2288b9d31fd32ed0683d5") - version("14.0.2", sha256="ca52232b3451c8e017f00eb882277707c13e30fac1271ec97015f6d0eeb383d1") - version("14.0.1", sha256="c8be00406e872c8a24f8571cf6f5517b73ae707104724b1fd1db2f0af9544019") - version("14.0.0", sha256="87b1a068b370df5b79a892fdb2935922a8efb1fddec4cc506e30fe57b6a1d9c4") - version("13.0.1", sha256="09c50d558bd975c41157364421820228df66632802a4a6a7c9c17f86a7340802") - version("13.0.0", sha256="a1131358f1f9f819df73fa6bff505f2c49d176e9eef0a3aedd1fdbce3b4630e8") - version("12.0.1", sha256="66b64aa301244975a4aea489f402f205cde2f53dd722dad9e7b77a0459b4c8df") - version("12.0.0", sha256="8e6c99e482bb16a450165176c2d881804976a2d770e0445af4375e78a1fbf19c") - version("11.1.0", sha256="53a0719f3f4b0388013cfffd7b10c7d5682eece1929a9553c722348d1f866e79") - version("11.0.1", sha256="9c7ad8e8ec77c5bde8eb4afa105a318fd1ded7dff3747d14f012758719d7171b") - version("11.0.0", sha256="8ad4ddbafac4f2c8f2ea523c2c4196f940e8e16f9e635210537582a48622a5d5") - version("10.0.1", sha256="c7ccb735c37b4ec470f66a6c35fbae4f029c0f88038f6977180b1a8ddc255637") - version("10.0.0", sha256="b81c96d2f8f40dc61b14a167513d87c0d813aae0251e06e11ae8a4384ca15451") - version("9.0.1", sha256="be7b034641a5fda51ffca7f5d840b1a768737779f75f7c4fd18fe2d37820289a") - version("9.0.0", sha256="7807fac25330e24e9955ca46cd855dd34bbc9cc4fdba8322366206654d1036f2") - version("8.0.1", sha256="5b18f6111c7aee7c0933c355877d4abcfe6cb40c1a64178f28821849c725c841") - version("8.0.0", sha256="d81238b4a69e93e29f74ce56f8107cbfcf0c7d7b40510b7879e98cc031e25167") - version("7.1.0", sha256="71c93979f20e01f1a1cc839a247945f556fa5e63abf2084e8468b238080fd839") - version("7.0.1", sha256="f17a6cd401e8fd8f811fbfbb36dcb4f455f898c9d03af4044807ad005df9f3c0") - version("6.0.1", sha256="aefadceb231f4c195fe6d6cd3b1a010b269c8a22410f339b5a089c2e902aa177") - version("6.0.0", sha256="1946ec629c88d30122afa072d3c6a89cc5d5e4e2bb28dc63b2f9ebcc7917ee64") - version("5.0.2", sha256="fe87aa11558c08856739bfd9bd971263a28657663cb0c3a0af01b94f03b0b795") - version("5.0.1", sha256="84ca454abf262579814a2a2b846569f6e0cb3e16dc33ca3642b4f1dff6fbafd3") - version("5.0.0", sha256="1f1843315657a4371d8ca37f01265fa9aae17dbcf46d2d0a95c1fdb3c6a4bab6") - version("4.0.1", sha256="cd664fb3eec3208c08fb61189c00c9118c290b3be5adb3215a97b24255618be5") - version("4.0.0", sha256="28ca4b2fc434cb1f558e8865386c233c2a6134437249b8b3765ae745ffa56a34") - version("3.9.1", sha256="f5b6922a5c65f9232f83d89831191f2c3ccf4f41fdd8c63e6645bbf578c4ab92") - version("3.9.0", sha256="9c6563a72c8b5b79941c773937d997dd2b1b5b3f640136d02719ec19f35e0333") - version("3.8.1", sha256="69360f0648fde0dc3d3c4b339624613f3bc2a89c4858933bc3871a250ad02826") - version("3.8.0", sha256="b5cc5974cc2fd4e9e49e1bbd0700f872501a8678bd9694fa2b36c65c026df1d1") - version("3.7.1", sha256="d2cb0eb9b8eb21e07605bfe5e7a5c6c5f5f8c2efdac01ec1da6ffacaabe4195a") - version("3.7.0", sha256="dc00bc230be2006fb87b84f6fe4800ca28bc98e6692811a98195da53c9cb28c6") - version("3.6.2", sha256="f75d703a388ba01d607f9cf96180863a5e4a106827ade17b221d43e6db20778a") - version("3.5.1", sha256="5d739684170d5b2b304e4fb521532d5c8281492f71e1a8568187bfa38eb5909d") - # fmt: on - - # NOTE: The debug version of LLVM is an order of magnitude larger than - # the release version, and may take up 20-30 GB of space. If you want - # to save space, build with `build_type=Release`. - - variant( - "clang", - default=True, - description="Build the LLVM C/C++/Objective-C compiler frontend", - ) - variant( - "flang", - default=False, - when="@11: +clang", - description="Build the LLVM Fortran compiler frontend " - "(experimental - parser only, needs GCC)", - ) - variant( - "omp_debug", - default=False, - description="Include debugging code in OpenMP runtime libraries", - ) - variant("lldb", default=True, when="+clang", description="Build the LLVM debugger") - variant("lld", default=True, description="Build the LLVM linker") - variant("mlir", default=False, when="@10:", description="Build with MLIR support") - variant( - "internal_unwind", - default=True, - when="+clang", - description="Build the libcxxabi libunwind", - ) - variant( - "polly", - default=True, - description="Build the LLVM polyhedral optimization plugin, " "only builds for 3.7.0+", - ) - variant( - "libcxx", - default=True, - when="+clang", - description="Build the LLVM C++ standard library", - ) - variant( - "compiler-rt", - when="+clang", - default=True, - description="Build LLVM compiler runtime, including sanitizers", - ) - variant( - "gold", - default=(sys.platform != "darwin"), - description="Add support for LTO with the gold linker plugin", - ) - variant( - "split_dwarf", - default=False, - description="Build with split dwarf information", - ) - variant( - "llvm_dylib", - default=True, - description="Build a combined LLVM shared library with all components", - ) - variant( - "link_llvm_dylib", - default=False, - when="+llvm_dylib", - description="Link LLVM tools against the LLVM shared library", - ) - variant( - "targets", - default="none", - description=( - "What targets to build. Spack's target family is always added " - "(e.g. X86 is automatically enabled when targeting znver2)." - ), - values=( - "all", - "none", - "aarch64", - "amdgpu", - "arm", - "avr", - "bpf", - "cppbackend", - "hexagon", - "lanai", - "mips", - "msp430", - "nvptx", - "powerpc", - "riscv", - "sparc", - "systemz", - "webassembly", - "x86", - "xcore", - ), - multi=True, - ) - variant( - "build_type", - default="Release", - description="CMake build type", - values=("Debug", "Release", "RelWithDebInfo", "MinSizeRel"), - ) - variant( - "omp_tsan", - default=False, - when="@6:", - description="Build with OpenMP capable thread sanitizer", - ) - variant( - "omp_as_runtime", - default=True, - when="+clang @12:", - description="Build OpenMP runtime via ENABLE_RUNTIME by just-built Clang", - ) - variant( - "code_signing", - default=False, - when="+lldb platform=darwin", - description="Enable code-signing on macOS", - ) - variant("python", default=False, description="Install python bindings") - variant("version_suffix", default="none", description="Add a symbol suffix") - variant( - "shlib_symbol_version", - default="none", - description="Add shared library symbol version", - when="@13:", - ) - variant( - "z3", default=False, when="+clang @8:", description="Use Z3 for the clang static analyzer" - ) - - provides("libllvm@14", when="@14.0.0:14") - provides("libllvm@13", when="@13.0.0:13") - provides("libllvm@12", when="@12.0.0:12") - provides("libllvm@11", when="@11.0.0:11") - provides("libllvm@10", when="@10.0.0:10") - provides("libllvm@9", when="@9.0.0:9") - provides("libllvm@8", when="@8.0.0:8") - provides("libllvm@7", when="@7.0.0:7") - provides("libllvm@6", when="@6.0.0:6") - provides("libllvm@5", when="@5.0.0:5") - provides("libllvm@4", when="@4.0.0:4") - provides("libllvm@3", when="@3.0.0:3") - - extends("python", when="+python") - - # Build dependency - depends_on("cmake@3.4.3:", type="build") - depends_on("cmake@3.13.4:", type="build", when="@12:") - depends_on("ninja", type="build") - depends_on("python@2.7:2.8", when="@:4 ~python", type="build") - depends_on("python", when="@5: ~python", type="build") - depends_on("pkgconfig", type="build") - - # Universal dependency - depends_on("python@2.7:2.8", when="@:4+python") - depends_on("python", when="@5:+python") - - # clang and clang-tools dependencies - depends_on("z3@4.7.1:", when="+z3") - - # openmp dependencies - depends_on("perl-data-dumper", type=("build")) - depends_on("hwloc") - depends_on("libelf", when="+cuda") # libomptarget - depends_on("libffi", when="+cuda") # libomptarget - - # llvm-config --system-libs libraries. - depends_on("zlib") - - # lldb dependencies - with when("+lldb +python"): - depends_on("swig") - depends_on("swig@2:", when="@10:") - depends_on("swig@3:", when="@12:") - depends_on("libedit", when="+lldb") - depends_on("ncurses", when="+lldb") - depends_on("py-six", when="@5.0.0: +lldb +python") - - # gold support, required for some features - depends_on("binutils+gold+ld+plugins", when="+gold") - - # polly plugin - depends_on("gmp", when="@:3.6 +polly") - depends_on("isl", when="@:3.6 +polly") - - # Older LLVM do not build with newer compilers, and vice versa - conflicts("%gcc@8:", when="@:5") - conflicts("%gcc@:5.0", when="@8:") - # clang/lib: a lambda parameter cannot shadow an explicitly captured entity - conflicts("%clang@8:", when="@:4") - # Internal compiler error on gcc 8.4 on aarch64 https://bugzilla.redhat.com/show_bug.cgi?id=1958295 - conflicts("%gcc@8.4:8.4.9", when="@12: target=aarch64:") - - # When these versions are concretized, but not explicitly with +libcxx, these - # conflicts will enable clingo to set ~libcxx, making the build successful: - - # libc++ of LLVM13, see https://libcxx.llvm.org/#platform-and-compiler-support - # @13 does not support %gcc@:10 https://bugs.llvm.org/show_bug.cgi?id=51359#c1 - # GCC 11 - latest stable release per GCC release page - # Clang: 11, 12 - latest two stable releases per LLVM release page - # AppleClang 12 - latest stable release per Xcode release page - conflicts("%gcc@:10", when="@13:+libcxx") - conflicts("%clang@:10", when="@13:+libcxx") - conflicts("%apple-clang@:11", when="@13:+libcxx") - - # libcxx-4 and compiler-rt-4 fail to build with "newer" clang and gcc versions: - conflicts("%gcc@7:", when="@:4+libcxx") - conflicts("%clang@6:", when="@:4+libcxx") - conflicts("%apple-clang@6:", when="@:4+libcxx") - conflicts("%gcc@7:", when="@:4+compiler-rt") - conflicts("%clang@6:", when="@:4+compiler-rt") - conflicts("%apple-clang@6:", when="@:4+compiler-rt") - - # cuda_arch value must be specified - conflicts("cuda_arch=none", when="+cuda", msg="A value for cuda_arch must be specified.") - - # LLVM bug https://bugs.llvm.org/show_bug.cgi?id=48234 - # CMake bug: https://gitlab.kitware.com/cmake/cmake/-/issues/21469 - # Fixed in upstream versions of both - conflicts("^cmake@3.19.0", when="@6:11.0.0") - - # Github issue #4986 - patch("llvm_gcc7.patch", when="@4.0.0:4.0.1+lldb %gcc@7.0:") - - # sys/ustat.h has been removed in favour of statfs from glibc-2.28. Use fixed sizes: - patch("llvm5-sanitizer-ustat.patch", when="@4:6.0.0+compiler-rt") - - # Fix lld templates: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=230463 - patch("llvm4-lld-ELF-Symbols.patch", when="@4+lld%clang@6:") - patch("llvm5-lld-ELF-Symbols.patch", when="@5+lld%clang@7:") - - # Fix missing std:size_t in 'llvm@4:5' when built with '%clang@7:' - patch("xray_buffer_queue-cstddef.patch", when="@4:5+compiler-rt%clang@7:") - - # https://github.com/llvm/llvm-project/commit/947f9692440836dcb8d88b74b69dd379d85974ce - patch("sanitizer-ipc_perm_mode.patch", when="@5:7+compiler-rt%clang@11:") - patch("sanitizer-ipc_perm_mode.patch", when="@5:9+compiler-rt%gcc@9:") - - # github.com/spack/spack/issues/24270: MicrosoftDemangle for %gcc@10: and %clang@13: - patch("missing-includes.patch", when="@8") - - # Backport from llvm upstream gcc ppc const expr long double issue - # see https://bugs.llvm.org/show_bug.cgi?id=39696 - # This fix was initially commited (3bf63cf3b366) for the 9.0 release - # but was then broken (0583d9ea8d5e) prior to the 9.0 release and - # eventually unbroken (d9a42ec98adc) for the 11.0 release. The first - # patch backports the original correct fix to previous releases. The - # second patch backports the un-breaking of the original fix. - patch("constexpr_longdouble.patch", when="@6:8+libcxx") - patch("constexpr_longdouble_9.0.patch", when="@9:10+libcxx") - - # Backport from llvm master; see - # https://bugs.llvm.org/show_bug.cgi?id=38233 - # for a bug report about this problem in llvm master. - patch("llvm_py37.patch", when="@4:6 ^python@3.7:") - - # https://github.com/spack/spack/issues/19625, - # merged in llvm-11.0.0_rc2, but not found in 11.0.1 - patch("lldb_external_ncurses-10.patch", when="@10.0.0:11.0.1+lldb") - - # https://github.com/spack/spack/issues/19908 - # merged in llvm main prior to 12.0.0 - patch("llvm_python_path.patch", when="@:11") - - # Workaround for issue https://github.com/spack/spack/issues/18197 - patch("llvm7_intel.patch", when="@7 %intel@18.0.2,19.0.0:19.1.99") - - # Remove cyclades support to build against newer kernel headers - # https://reviews.llvm.org/D102059 - patch("no_cyclades.patch", when="@10:12.0.0") - patch("no_cyclades9.patch", when="@6:9") - - patch("llvm-gcc11.patch", when="@9:11%gcc@11:") - - # add -lpthread to build OpenMP libraries with Fujitsu compiler - patch("llvm12-thread.patch", when="@12 %fj") - - # add -lpthread to build OpenMP libraries - patch("llvm13-14-thread.patch", when="@13:14") - patch("llvm15-thread.patch", when="@15") - - # avoid build failed with Fujitsu compiler - patch("llvm13-fujitsu.patch", when="@13 %fj") - - # patch for missing hwloc.h include for libompd - patch("llvm14-hwloc-ompd.patch", when="@14") - - # make libflags a list in openmp subproject when ~omp_as_runtime - patch("libomp-libflags-as-list.patch", when="@3.7:14") - - # Add missing include leading to build fail with clang - patch( - "https://github.com/llvm/llvm-project/commit/b498303066a63a203d24f739b2d2e0e56dca70d1.patch?full_index=1", - sha256="514926d661635de47972c7d403c9c4669235aa51e22e56d44676d2a2709179b6", - when="@8:11", - ) - - # fix detection of LLDB_PYTHON_EXE_RELATIVE_PATH - # see https://reviews.llvm.org/D133513 - # TODO: adjust version constraint and switch to fetching from the upstream GitHub repo - # when/if the bugfix is merged - patch("D133513.diff", level=0, when="@14:15+lldb+python") - - # The functions and attributes below implement external package - # detection for LLVM. See: - # - # https://spack.readthedocs.io/en/latest/packaging_guide.html#making-a-package-discoverable-with-spack-external-find - executables = ["clang", "flang", "ld.lld", "lldb"] - - @classmethod - def filter_detected_exes(cls, prefix, exes_in_prefix): - result = [] - for exe in exes_in_prefix: - # Executables like lldb-vscode-X are daemon listening - # on some port and would hang Spack during detection. - # clang-cl and clang-cpp are dev tools that we don't - # need to test - if any(x in exe for x in ("vscode", "cpp", "-cl", "-gpu")): - continue - result.append(exe) - return result - - @classmethod - def determine_version(cls, exe): - version_regex = re.compile( - # Normal clang compiler versions are left as-is - r"clang version ([^ )\n]+)-svn[~.\w\d-]*|" - # Don't include hyphenated patch numbers in the version - # (see https://github.com/spack/spack/pull/14365 for details) - r"clang version ([^ )\n]+?)-[~.\w\d-]*|" - r"clang version ([^ )\n]+)|" - # LLDB - r"lldb version ([^ )\n]+)|" - # LLD - r"LLD ([^ )\n]+) \(compatible with GNU linkers\)" - ) - try: - compiler = Executable(exe) - output = compiler("--version", output=str, error=str) - if "Apple" in output: - return None - match = version_regex.search(output) - if match: - return match.group(match.lastindex) - except spack.util.executable.ProcessError: - pass - except Exception as e: - tty.debug(e) - - return None - - @classmethod - def determine_variants(cls, exes, version_str): - variants, compilers = ["+clang"], {} - lld_found, lldb_found = False, False - for exe in exes: - if "clang++" in exe: - compilers["cxx"] = exe - elif "clang" in exe: - compilers["c"] = exe - elif "flang" in exe: - variants.append("+flang") - compilers["fc"] = exe - compilers["f77"] = exe - elif "ld.lld" in exe: - lld_found = True - compilers["ld"] = exe - elif "lldb" in exe: - lldb_found = True - compilers["lldb"] = exe - - variants.append("+lld" if lld_found else "~lld") - variants.append("+lldb" if lldb_found else "~lldb") - - return "".join(variants), {"compilers": compilers} - - @classmethod - def validate_detected_spec(cls, spec, extra_attributes): - # For LLVM 'compilers' is a mandatory attribute - msg = 'the extra attribute "compilers" must be set for ' 'the detected spec "{0}"'.format( - spec - ) - assert "compilers" in extra_attributes, msg - compilers = extra_attributes["compilers"] - for key in ("c", "cxx"): - msg = "{0} compiler not found for {1}" - assert key in compilers, msg.format(key, spec) - - @property - def cc(self): - msg = "cannot retrieve C compiler [spec is not concrete]" - assert self.spec.concrete, msg - if self.spec.external: - return self.spec.extra_attributes["compilers"].get("c", None) - result = None - if "+clang" in self.spec: - result = os.path.join(self.spec.prefix.bin, "clang") - return result - - @property - def cxx(self): - msg = "cannot retrieve C++ compiler [spec is not concrete]" - assert self.spec.concrete, msg - if self.spec.external: - return self.spec.extra_attributes["compilers"].get("cxx", None) - result = None - if "+clang" in self.spec: - result = os.path.join(self.spec.prefix.bin, "clang++") - return result - - @property - def fc(self): - msg = "cannot retrieve Fortran compiler [spec is not concrete]" - assert self.spec.concrete, msg - if self.spec.external: - return self.spec.extra_attributes["compilers"].get("fc", None) - result = None - if "+flang" in self.spec: - result = os.path.join(self.spec.prefix.bin, "flang") - return result - - @property - def f77(self): - msg = "cannot retrieve Fortran 77 compiler [spec is not concrete]" - assert self.spec.concrete, msg - if self.spec.external: - return self.spec.extra_attributes["compilers"].get("f77", None) - result = None - if "+flang" in self.spec: - result = os.path.join(self.spec.prefix.bin, "flang") - return result - - @property - def libs(self): - return LibraryList(self.llvm_config("--libfiles", "all", result="list")) - - @run_before("cmake") - def codesign_check(self): - if self.spec.satisfies("+code_signing"): - codesign = which("codesign") - mkdir("tmp") - llvm_check_file = join_path("tmp", "llvm_check") - copy("/usr/bin/false", llvm_check_file) - try: - codesign("-f", "-s", "lldb_codesign", "--dryrun", llvm_check_file) - - except ProcessError: - # Newer LLVM versions have a simple script that sets up - # automatically when run with sudo priviliges - setup = Executable("./lldb/scripts/macos-setup-codesign.sh") - try: - setup() - except Exception: - raise RuntimeError( - "spack was unable to either find or set up" - "code-signing on your system. Please refer to" - "https://lldb.llvm.org/resources/build.html#" - "code-signing-on-macos for details on how to" - "create this identity." - ) - - def flag_handler(self, name, flags): - if name == "cxxflags": - flags.append(self.compiler.cxx11_flag) - return (None, flags, None) - elif name == "ldflags" and self.spec.satisfies("%intel"): - flags.append("-shared-intel") - return (None, flags, None) - return (flags, None, None) - - def setup_build_environment(self, env): - """When using %clang, add only its ld.lld-$ver and/or ld.lld to our PATH""" - if self.compiler.name in ["clang", "apple-clang"]: - for lld in "ld.lld-{0}".format(self.compiler.version.version[0]), "ld.lld": - bin = os.path.join(os.path.dirname(self.compiler.cc), lld) - sym = os.path.join(self.stage.path, "ld.lld") - if os.path.exists(bin) and not os.path.exists(sym): - mkdirp(self.stage.path) - os.symlink(bin, sym) - env.prepend_path("PATH", self.stage.path) - - def setup_run_environment(self, env): - if "+clang" in self.spec: - env.set("CC", join_path(self.spec.prefix.bin, "clang")) - env.set("CXX", join_path(self.spec.prefix.bin, "clang++")) - if "+flang" in self.spec: - env.set("FC", join_path(self.spec.prefix.bin, "flang")) - env.set("F77", join_path(self.spec.prefix.bin, "flang")) - - root_cmakelists_dir = "llvm" - - def cmake_args(self): - spec = self.spec - define = self.define - from_variant = self.define_from_variant - - python = spec["python"] - cmake_args = [ - define("LLVM_REQUIRES_RTTI", True), - define("LLVM_ENABLE_RTTI", True), - define("LLVM_ENABLE_EH", True), - define("LLVM_ENABLE_LIBXML2", False), - define("CLANG_DEFAULT_OPENMP_RUNTIME", "libomp"), - define("PYTHON_EXECUTABLE", python.command.path), - define("LIBOMP_USE_HWLOC", True), - define("LIBOMP_HWLOC_INSTALL_DIR", spec["hwloc"].prefix), - ] - - version_suffix = spec.variants["version_suffix"].value - if version_suffix != "none": - cmake_args.append(define("LLVM_VERSION_SUFFIX", version_suffix)) - - shlib_symbol_version = spec.variants.get("shlib_symbol_version", None) - if shlib_symbol_version is not None and shlib_symbol_version.value != "none": - cmake_args.append(define("LLVM_SHLIB_SYMBOL_VERSION", shlib_symbol_version.value)) - - if python.version >= Version("3"): - cmake_args.append(define("Python3_EXECUTABLE", python.command.path)) - else: - cmake_args.append(define("Python2_EXECUTABLE", python.command.path)) - - projects = [] - runtimes = [] - - if "+cuda" in spec: - cmake_args.extend( - [ - define("CUDA_TOOLKIT_ROOT_DIR", spec["cuda"].prefix), - define( - "LIBOMPTARGET_NVPTX_COMPUTE_CAPABILITIES", - ",".join(spec.variants["cuda_arch"].value), - ), - define( - "CLANG_OPENMP_NVPTX_DEFAULT_ARCH", - "sm_{0}".format(spec.variants["cuda_arch"].value[-1]), - ), - ] - ) - if "+omp_as_runtime" in spec: - cmake_args.extend( - [ - define("LIBOMPTARGET_NVPTX_ENABLE_BCLIB", True), - # work around bad libelf detection in libomptarget - define( - "LIBOMPTARGET_DEP_LIBELF_INCLUDE_DIR", spec["libelf"].prefix.include - ), - ] - ) - else: - # still build libomptarget but disable cuda - cmake_args.extend( - [ - define("CUDA_TOOLKIT_ROOT_DIR", "IGNORE"), - define("CUDA_SDK_ROOT_DIR", "IGNORE"), - define("CUDA_NVCC_EXECUTABLE", "IGNORE"), - define("LIBOMPTARGET_DEP_CUDA_DRIVER_LIBRARIES", "IGNORE"), - ] - ) - - cmake_args.append(from_variant("LIBOMPTARGET_ENABLE_DEBUG", "omp_debug")) - - if "+lldb" in spec: - projects.append("lldb") - cmake_args.append(define("LLDB_ENABLE_LIBEDIT", True)) - cmake_args.append(define("LLDB_ENABLE_CURSES", True)) - if spec["ncurses"].satisfies("+termlib"): - cmake_args.append(define("LLVM_ENABLE_TERMINFO", True)) - else: - cmake_args.append(define("LLVM_ENABLE_TERMINFO", False)) - cmake_args.append(define("LLDB_ENABLE_LIBXML2", False)) - if spec.version >= Version("10"): - cmake_args.append(from_variant("LLDB_ENABLE_PYTHON", "python")) - else: - cmake_args.append(define("LLDB_DISABLE_PYTHON", "~python" in spec)) - if spec.satisfies("@5.0.0: +python"): - cmake_args.append(define("LLDB_USE_SYSTEM_SIX", True)) - else: - cmake_args.append(define("LLVM_ENABLE_TERMINFO", False)) - - if "+gold" in spec: - cmake_args.append(define("LLVM_BINUTILS_INCDIR", spec["binutils"].prefix.include)) - - if "+clang" in spec: - projects.append("clang") - projects.append("clang-tools-extra") - if "+omp_as_runtime" in spec: - runtimes.append("openmp") - else: - projects.append("openmp") - - if "@8" in spec: - cmake_args.append(from_variant("CLANG_ANALYZER_ENABLE_Z3_SOLVER", "z3")) - elif "@9:" in spec: - cmake_args.append(from_variant("LLVM_ENABLE_Z3_SOLVER", "z3")) - - if "+flang" in spec: - projects.append("flang") - if "+lld" in spec: - projects.append("lld") - if "+compiler-rt" in spec: - if self.spec.satisfies("@15.0.0:"): - runtimes.append("compiler-rt") - else: - projects.append("compiler-rt") - if "+libcxx" in spec: - if self.spec.satisfies("@15.0.0:"): - runtimes.extend(["libcxx", "libcxxabi"]) - else: - projects.extend(["libcxx", "libcxxabi"]) - if "+mlir" in spec: - projects.append("mlir") - if "+internal_unwind" in spec: - if self.spec.satisfies("@15.0.0:"): - runtimes.append("libunwind") - else: - projects.append("libunwind") - if "+polly" in spec: - projects.append("polly") - cmake_args.append(define("LINK_POLLY_INTO_TOOLS", True)) - - cmake_args.extend( - [ - define("BUILD_SHARED_LIBS", False), - from_variant("LLVM_BUILD_LLVM_DYLIB", "llvm_dylib"), - from_variant("LLVM_LINK_LLVM_DYLIB", "link_llvm_dylib"), - from_variant("LLVM_USE_SPLIT_DWARF", "split_dwarf"), - # By default on Linux, libc++.so is a ldscript. CMake fails to add - # CMAKE_INSTALL_RPATH to it, which fails. Statically link libc++abi.a - # into libc++.so, linking with -lc++ or -stdlib=libc++ is enough. - define("LIBCXX_ENABLE_STATIC_ABI_LIBRARY", True), - ] - ) - - cmake_args.append(define("LLVM_TARGETS_TO_BUILD", get_llvm_targets_to_build(spec))) - - cmake_args.append(from_variant("LIBOMP_TSAN_SUPPORT", "omp_tsan")) - - if self.compiler.name == "gcc": - cmake_args.append(define("GCC_INSTALL_PREFIX", self.compiler.prefix)) - - if self.spec.satisfies("~code_signing platform=darwin"): - cmake_args.append(define("LLDB_USE_SYSTEM_DEBUGSERVER", True)) - - # Enable building with CLT [and not require full Xcode] - # https://github.com/llvm/llvm-project/issues/57037 - if self.spec.satisfies("@15.0.0: platform=darwin"): - cmake_args.append(define("BUILTINS_CMAKE_ARGS", "-DCOMPILER_RT_ENABLE_IOS=OFF")) - - # Semicolon seperated list of projects to enable - cmake_args.append(define("LLVM_ENABLE_PROJECTS", projects)) - - # Semicolon seperated list of runtimes to enable - if runtimes: - cmake_args.append(define("LLVM_ENABLE_RUNTIMES", runtimes)) - - return cmake_args - - @run_after("install") - def post_install(self): - spec = self.spec - define = self.define - - # unnecessary if we build openmp via LLVM_ENABLE_RUNTIMES - if "+cuda ~omp_as_runtime" in self.spec: - ompdir = "build-bootstrapped-omp" - prefix_paths = spack.build_environment.get_cmake_prefix_path(self) - prefix_paths.append(str(spec.prefix)) - # rebuild libomptarget to get bytecode runtime library files - with working_dir(ompdir, create=True): - cmake_args = [ - "-G", - "Ninja", - define("CMAKE_BUILD_TYPE", spec.variants["build_type"].value), - define("CMAKE_C_COMPILER", spec.prefix.bin + "/clang"), - define("CMAKE_CXX_COMPILER", spec.prefix.bin + "/clang++"), - define("CMAKE_INSTALL_PREFIX", spec.prefix), - define("CMAKE_PREFIX_PATH", prefix_paths), - ] - cmake_args.extend(self.cmake_args()) - cmake_args.extend( - [ - define("LIBOMPTARGET_NVPTX_ENABLE_BCLIB", True), - define( - "LIBOMPTARGET_DEP_LIBELF_INCLUDE_DIR", spec["libelf"].prefix.include - ), - self.stage.source_path + "/openmp", - ] - ) - - cmake(*cmake_args) - ninja() - ninja("install") - if "+python" in self.spec: - install_tree("llvm/bindings/python", python_platlib) - - if "+clang" in self.spec: - install_tree("clang/bindings/python", python_platlib) - - with working_dir(self.build_directory): - install_tree("bin", join_path(self.prefix, "libexec", "llvm")) - - def llvm_config(self, *args, **kwargs): - lc = Executable(self.prefix.bin.join("llvm-config")) - if not kwargs.get("output"): - kwargs["output"] = str - ret = lc(*args, **kwargs) - if kwargs.get("result") == "list": - return ret.split() - else: - return ret - - -def get_llvm_targets_to_build(spec): - targets = spec.variants["targets"].value - - # Build everything? - if "all" in targets: - return "all" - - # Convert targets variant values to CMake LLVM_TARGETS_TO_BUILD array. - spack_to_cmake = { - "aarch64": "AArch64", - "amdgpu": "AMDGPU", - "arm": "ARM", - "avr": "AVR", - "bpf": "BPF", - "cppbackend": "CppBackend", - "hexagon": "Hexagon", - "lanai": "Lanai", - "mips": "Mips", - "msp430": "MSP430", - "nvptx": "NVPTX", - "powerpc": "PowerPC", - "riscv": "RISCV", - "sparc": "Sparc", - "systemz": "SystemZ", - "webassembly": "WebAssembly", - "x86": "X86", - "xcore": "XCore", - } - - if "none" in targets: - llvm_targets = set() - else: - llvm_targets = set(spack_to_cmake[target] for target in targets) - - if spec.target.family in ("x86", "x86_64"): - llvm_targets.add("X86") - elif spec.target.family == "arm": - llvm_targets.add("ARM") - elif spec.target.family == "aarch64": - llvm_targets.add("AArch64") - elif spec.target.family in ("sparc", "sparc64"): - llvm_targets.add("Sparc") - elif spec.target.family in ("ppc64", "ppc64le", "ppc", "ppcle"): - llvm_targets.add("PowerPC") - - return list(llvm_targets) diff --git a/repo/packages/llvm/sanitizer-ipc_perm_mode.patch b/repo/packages/llvm/sanitizer-ipc_perm_mode.patch deleted file mode 100644 index 8f91703a..00000000 --- a/repo/packages/llvm/sanitizer-ipc_perm_mode.patch +++ /dev/null @@ -1,9 +0,0 @@ -# ipc_perm.mode is not used and has changed from short to int over architecures -# and versions. The last change was in glibc-2.31. -# LLVM upstream decided to not check ipc_perm.mode below glibc-2.31, -# because it is not actually used in the sanitizer: -# github.com/llvm/llvm-project/commit/947f9692440836dcb8d88b74b69dd379d85974ce ---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cc -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cc -@@ -1143,1 +1143,0 @@ --CHECK_SIZE_AND_OFFSET(ipc_perm, mode); diff --git a/repo/packages/llvm/thread-p9.patch b/repo/packages/llvm/thread-p9.patch deleted file mode 100644 index 140473a8..00000000 --- a/repo/packages/llvm/thread-p9.patch +++ /dev/null @@ -1,16 +0,0 @@ -diff --git a/libcxx/include/thread b/libcxx/include/thread -index 02da703..d1677a1 100644 ---- a/projects/libcxx/include/thread -+++ b/projects/libcxx/include/thread -@@ -368,9 +368,9 @@ sleep_for(const chrono::duration<_Rep, _Period>& __d) - { - #if defined(_LIBCPP_COMPILER_GCC) && (__powerpc__ || __POWERPC__) - // GCC's long double const folding is incomplete for IBM128 long doubles. -- _LIBCPP_CONSTEXPR duration _Max = nanoseconds::max(); --#else - _LIBCPP_CONSTEXPR duration _Max = duration(ULLONG_MAX/1000000000ULL) ; -+#else -+ _LIBCPP_CONSTEXPR duration _Max = nanoseconds::max(); - #endif - nanoseconds __ns; - if (__d < _Max) diff --git a/repo/packages/llvm/xray_buffer_queue-cstddef.patch b/repo/packages/llvm/xray_buffer_queue-cstddef.patch deleted file mode 100644 index b5ca841e..00000000 --- a/repo/packages/llvm/xray_buffer_queue-cstddef.patch +++ /dev/null @@ -1,5 +0,0 @@ -# Fix missing std:size_t in 'llvm@4:5' for build with '%clang@7:' ---- a/compiler-rt/lib/xray/xray_buffer_queue.h -+++ b/compiler-rt/lib/xray/xray_buffer_queue.h -@@ -18,0 +18,1 @@ -+#include From 46cb91102077e86ff0b7eca6272ec0b5e3205374 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 14:28:13 +0800 Subject: [PATCH 12/21] Contributed IOR. --- repo/packages/ior/package.py | 104 ----------------------------------- 1 file changed, 104 deletions(-) delete mode 100644 repo/packages/ior/package.py diff --git a/repo/packages/ior/package.py b/repo/packages/ior/package.py deleted file mode 100644 index 600418c5..00000000 --- a/repo/packages/ior/package.py +++ /dev/null @@ -1,104 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# Differences for the 'ior' package -# 1c1 -# < # Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# --- -# > # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other -# 6c6 -# < from spack.package import * -# --- -# > from spack import * -# 25d24 -# < variant('lustre', default=False, description='support configurable Lustre striping values') -# 34d32 -# < depends_on('lustre', when='+lustre') -# 38,39c36,37 -# < patch('https://github.com/hpc/ior/commit/1dbca5c293f95074f9887ddb2043fa984670fb4d.patch?full_index=1', -# < sha256='ce7fa0eabf408f9b712c478a08aa62d68737d213901707ef8cbfc3aec02e2713', -# --- -# > patch('https://github.com/hpc/ior/commit/1dbca5c293f95074f9887ddb2043fa984670fb4d.patch', -# > sha256='f28d6638a74a09e147e9fa870930e54a82ff580d1c232add47a67c375e255ada', -# 41,45d38 -# < # Needs patch to make Lustre variant work -# < # See https://github.com/hpc/ior/issues/353 -# < patch('https://github.com/glennklockwood/ior/commit/e49476be64d4100c2da662ea415f327348b3d11d.patch?full_index=1', -# < sha256='ee3527023ef70ea9aee2e6208f8be7126d5a48f26c587deed3d6238b4f848a06', -# < when='+lustre') -# 67,71d59 -# < -# < if '+lustre' in spec: -# < config_args.append('--with-lustre') -# < else: -# < config_args.append('--without-lustre') -# CONTRIBUTE Lustre additions -from spack.package import * - - -class Ior(AutotoolsPackage): - """The IOR software is used for benchmarking parallel file systems - using POSIX, MPI-IO, or HDF5 interfaces.""" - - homepage = "https://github.com/hpc/ior" - url = "https://github.com/hpc/ior/archive/3.2.1.tar.gz" - - version('develop', git='https://github.com/hpc/ior.git', branch='main') - version('3.3.0', sha256='701f2167f81ef963e227d4c036c4a947a98b5642b7c14c87c8ae657849891528', preferred=True) - version('3.3.0rc1', sha256='0e42ebf5b5adae60625bf97989c8e2519d41ea2e3d18561d7d5b945625317aa5') - version('3.2.1', sha256='ebcf2495aecb357370a91a2d5852cfd83bba72765e586bcfaf15fb79ca46d00e') - version('3.2.0', sha256='91a766fb9c34b5780705d0997b71b236a1120da46652763ba11d9a8c44251852') - version('3.0.1', sha256='0cbefbcdb02fb13ba364e102f9e7cc2dcf761698533dac25de446a3a3e81390d') - - variant('hdf5', default=False, description='support IO with HDF5 backend') - variant('ncmpi', default=False, description='support IO with NCMPI backend') - variant('lustre', default=False, description='support configurable Lustre striping values') - - depends_on('autoconf', type='build') - depends_on('automake', type='build') - depends_on('libtool', type='build') - depends_on('m4', type='build') - depends_on('mpi') - depends_on('hdf5+mpi', when='+hdf5') - depends_on('parallel-netcdf', when='+ncmpi') - depends_on('lustre', when='+lustre') - - # The build for 3.2.0 fails if hdf5 is enabled - # See https://github.com/hpc/ior/pull/124 - patch('https://github.com/hpc/ior/commit/1dbca5c293f95074f9887ddb2043fa984670fb4d.patch?full_index=1', - sha256='ce7fa0eabf408f9b712c478a08aa62d68737d213901707ef8cbfc3aec02e2713', - when='@3.2.0 +hdf5') - # Needs patch to make Lustre variant work - # See https://github.com/hpc/ior/issues/353 - patch('https://github.com/glennklockwood/ior/commit/e49476be64d4100c2da662ea415f327348b3d11d.patch?full_index=1', - sha256='ee3527023ef70ea9aee2e6208f8be7126d5a48f26c587deed3d6238b4f848a06', - when='+lustre') - - @run_before('autoreconf') - def bootstrap(self): - Executable('./bootstrap')() - - def configure_args(self): - spec = self.spec - config_args = [] - - env['CC'] = spec['mpi'].mpicc - - if '+hdf5' in spec: - config_args.append('--with-hdf5') - config_args.append('CFLAGS=-D H5_USE_16_API') - else: - config_args.append('--without-hdf5') - - if '+ncmpi' in spec: - config_args.append('--with-ncmpi') - else: - config_args.append('--without-ncmpi') - - if '+lustre' in spec: - config_args.append('--with-lustre') - else: - config_args.append('--without-lustre') - - return config_args From 9aa4c7558398d0f233a72309818ae80852a8b289 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 14:53:15 +0800 Subject: [PATCH 13/21] Removed lammps - just version additions. --- repo/packages/lammps/660.patch | 24 - repo/packages/lammps/Makefile.inc | 49 -- repo/packages/lammps/gtest_fix.patch | 18 - repo/packages/lammps/lib.patch | 13 - repo/packages/lammps/package.py | 830 --------------------------- 5 files changed, 934 deletions(-) delete mode 100644 repo/packages/lammps/660.patch delete mode 100644 repo/packages/lammps/Makefile.inc delete mode 100644 repo/packages/lammps/gtest_fix.patch delete mode 100644 repo/packages/lammps/lib.patch delete mode 100644 repo/packages/lammps/package.py diff --git a/repo/packages/lammps/660.patch b/repo/packages/lammps/660.patch deleted file mode 100644 index 9d1d11af..00000000 --- a/repo/packages/lammps/660.patch +++ /dev/null @@ -1,24 +0,0 @@ -From b46cc6a6a7410108af84a854818c154a17e0ef42 Mon Sep 17 00:00:00 2001 -From: Christoph Junghans -Date: Fri, 22 Sep 2017 15:17:44 -0600 -Subject: [PATCH] cmake: fix build with system cmake - ---- - cmake/CMakeLists.txt | 4 +++- - 1 file changed, 3 insertions(+), 1 deletion(-) - -diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt -index bc33da60de..666b77ae3d 100644 ---- a/cmake/CMakeLists.txt -+++ b/cmake/CMakeLists.txt -@@ -665,7 +665,9 @@ include_directories(${LAMMPS_STYLE_HEADERS_DIR}) - ############################################ - add_library(lammps ${LIB_SOURCES}) - target_link_libraries(lammps ${LAMMPS_LINK_LIBS}) --add_dependencies(lammps ${LAMMPS_DEPS}) -+if(LAMMPS_DEPS) -+ add_dependencies(lammps ${LAMMPS_DEPS}) -+endif() - set_target_properties(lammps PROPERTIES OUTPUT_NAME lammps${LAMMPS_MACHINE}) - if(BUILD_SHARED_LIBS) - set_target_properties(lammps PROPERTIES SOVERSION ${SOVERSION}) diff --git a/repo/packages/lammps/Makefile.inc b/repo/packages/lammps/Makefile.inc deleted file mode 100644 index 6986a255..00000000 --- a/repo/packages/lammps/Makefile.inc +++ /dev/null @@ -1,49 +0,0 @@ -SHELL = /bin/sh - -# --------------------------------------------------------------------- -# build rules and dependencies -# do not edit this section - -include Makefile.package.settings -include Makefile.package - -EXTRA_INC = $(LMP_INC) $(PKG_INC) $(MPI_INC) $(FFT_INC) $(JPG_INC) $(PKG_SYSINC) -EXTRA_PATH = $(PKG_PATH) $(MPI_PATH) $(FFT_PATH) $(JPG_PATH) $(PKG_SYSPATH) -EXTRA_LIB = $(PKG_LIB) $(MPI_LIB) $(FFT_LIB) $(JPG_LIB) $(PKG_SYSLIB) -EXTRA_CPP_DEPENDS = $(PKG_CPP_DEPENDS) -EXTRA_LINK_DEPENDS = $(PKG_LINK_DEPENDS) - -# Path to src files - -vpath %.cpp .. -vpath %.h .. - -# Link target - -$(EXE): $(OBJ) $(EXTRA_LINK_DEPENDS) - $(LINK) $(LINKFLAGS) $(EXTRA_PATH) $(OBJ) $(EXTRA_LIB) $(LIB) -o $(EXE) - $(SIZE) $(EXE) - -# Library targets - -lib: $(OBJ) $(EXTRA_LINK_DEPENDS) - $(ARCHIVE) $(ARFLAGS) $(EXE) $(OBJ) - -shlib: $(OBJ) $(EXTRA_LINK_DEPENDS) - $(CC) $(CCFLAGS) $(SHFLAGS) $(SHLIBFLAGS) $(EXTRA_PATH) -o $(EXE) \ - $(OBJ) $(EXTRA_LIB) $(LIB) - -# Compilation rules - -%.o:%.cpp - $(CC) $(CCFLAGS) $(SHFLAGS) $(EXTRA_INC) -c $< - -# Individual dependencies - -depend : fastdep.exe $(SRC) - @./fastdep.exe $(EXTRA_INC) -- $^ > .depend || exit 1 - -fastdep.exe: ../DEPEND/fastdep.c - cc -O -o $@ $< - -sinclude .depend diff --git a/repo/packages/lammps/gtest_fix.patch b/repo/packages/lammps/gtest_fix.patch deleted file mode 100644 index 1f14fb4e..00000000 --- a/repo/packages/lammps/gtest_fix.patch +++ /dev/null @@ -1,18 +0,0 @@ -diff --git a/cmake/Modules/GTest.cmake b/cmake/Modules/GTest1.cmake -index 0c62291..e42137b 100644 ---- a/cmake/Modules/GTest.cmake -+++ b/cmake/Modules/GTest1.cmake -@@ -7,11 +7,11 @@ else() - endif() - - include(ExternalProject) --set(GTEST_URL "https://github.com/google/googletest/archive/release-1.10.0.tar.gz" CACHE STRING "URL for GTest tarball") -+set(GTEST_URL "https://github.com/google/googletest/archive/release-1.11.0.tar.gz" CACHE STRING "URL for GTest tarball") - mark_as_advanced(GTEST_URL) - ExternalProject_Add(googletest - URL ${GTEST_URL} -- URL_MD5 ecd1fa65e7de707cd5c00bdac56022cd -+ URL_MD5 e8a8df240b6938bb6384155d4c37d937 - SOURCE_DIR "${CMAKE_BINARY_DIR}/gtest-src" - BINARY_DIR "${CMAKE_BINARY_DIR}/gtest-build" - CMAKE_ARGS ${CMAKE_REQUEST_PIC} ${CMAKE_EXTRA_GTEST_OPTS} diff --git a/repo/packages/lammps/lib.patch b/repo/packages/lammps/lib.patch deleted file mode 100644 index 5a55aafa..00000000 --- a/repo/packages/lammps/lib.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt -index 6d35db75a..5987869b8 100644 ---- a/cmake/CMakeLists.txt -+++ b/cmake/CMakeLists.txt -@@ -530,7 +530,7 @@ target_link_libraries(lammps ${LAMMPS_LINK_LIBS}) - set_target_properties(lammps PROPERTIES SOVERSION ${SOVERSION}) - if(INSTALL_LIB) - install(TARGETS lammps LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}) -- install(FILES ${LAMMPS_SOURCE_DIR}/lammps.h DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) -+ install(FILES ${LAMMPS_SOURCE_DIR}/library.h DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/lammps) - elseif(BUILD_SHARED_LIBS) - message(FATAL_ERROR "Shared library has to be installed, use -DINSTALL_LIB=ON to install lammps with a library") - endif() diff --git a/repo/packages/lammps/package.py b/repo/packages/lammps/package.py deleted file mode 100644 index e687e8ba..00000000 --- a/repo/packages/lammps/package.py +++ /dev/null @@ -1,830 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# ======================================================================= -# PAWSEY ADDITIONS -# ======================================================================= -# This is a version of the recipe coming from the later 0.19.0-dev Spack -# version. It adds a new version. -import datetime as dt - -import archspec - -from spack.package import * - - -class Lammps(CMakePackage, CudaPackage): - """LAMMPS stands for Large-scale Atomic/Molecular Massively - Parallel Simulator. This package uses patch releases, not - stable release. - See https://github.com/spack/spack/pull/5342 for a detailed - discussion. - """ - - homepage = "https://lammps.sandia.gov/" - url = "https://github.com/lammps/lammps/archive/patch_1Sep2017.tar.gz" - git = "https://github.com/lammps/lammps.git" - - tags = ["ecp", "ecp-apps"] - - version("develop", branch="develop") - version("20230615", sha256="8470ed7b26ccd3728f4b44a7f1c520f1af23a648af685fd30b42b840fdfae2ff") - version("20220623", sha256="21533ce6f174c80815a48c99e5f3dd109e69d55c4cad47312d88a7190a35927f") - version("20220602", sha256="3e8f54453e53b3b387a68317277f832b8cf64a981e64b21e98bb37ea36ac4a60") - version("20220504", sha256="fe05bae8090fd0177b3c1b987cd32a9cb7cd05d790828ba954c764eb52e10b52") - version("20220324", sha256="d791cc93eedfc345fdf87bfa5b6f7e17e461f86ba197f9e9c3d477ce8657a7ef") - version("20220217", sha256="e5bd2bf325835fa98d1b95f0667c83076580916027df5b8109d5470d1b97da98") - version("20220107", sha256="fbf6c6814968ae0d772d7b6783079ff4f249a8faeceb39992c344969e9f1edbb") - version("20211214", sha256="9f7b1ee2394678c1a6baa2c158a62345680a952eee251783e3c246b3f12db4c9") - version("20211027", sha256="c06f682fcf9d5921ca90c857a104e90fba0fe65decaac9732745e4da49281938") - version( - "20210929.3", sha256="d7df30f7ce0bd8b7c21949cf5bdf1877858815379cddb8a264da7a8cbf699639" - ) - version( - "20210929.2", sha256="26586c1e82356b60e40359ee474818003c7788214bfe2bfe9128a3dbe5200b4d" - ) - version( - "20210929.1", sha256="3b792e20864bf88b855332486996f2c540deabb4e3507e48fa4ee96ad79615ec" - ) - version("20210929", sha256="5132f332b582be3006510562ef10bac9ef76d760f34fc08a2af556416c57cf4c") - version("20210920", sha256="e3eba96933c1dd3177143c7ac837cae69faceba196948fbad2970425db414d8c") - version("20210831", sha256="532c42576a79d72682deaf43225ca773ed9f9e35deb484a82f91905b6cba23ec") - version("20210730", sha256="c5e998c8282a835d2bcba4fceffe3cecdf9aed9bdf79fa9c945af573e632f6e7") - version("20210728", sha256="6b844d2c3f7170a59d36fbf761483aa0c63d95eda254d00fe4d10542403abe36") - version("20210702", sha256="4fdd8ca2dbde8809c0048716650b73ae1f840e22ebe24b25f6f7a499377fea57") - version("20210514", sha256="74d9c4386f2181b15a024314c42b7a0b0aaefd3b4b947aeca00fe07e5b2f3317") - version("20210408", sha256="1645147b7777de4f616b8232edf0b597868084f969c777fa0a757949c3f71f56") - version("20210310", sha256="25708378dbeccf794bc5045aceb84380bf4a3ca03fc8e5d150a26ca88d371474") - version("20201029", sha256="3d347f6b512bc360505019d1c6183c969a2e1da402e31a1e26577daf5e419d95") - version("20200721", sha256="845bfeddb7b667799a1a5dbc166b397d714c3d2720316604a979d3465b4190a9") - version("20200630", sha256="413cbfabcc1541a339c7a4ab5693fbeb768f46bb1250640ba94686c6e90922fc") - version("20200505", sha256="c49d77fd602d28ebd8cf10f7359b9fc4d14668c72039028ed7792453d416de73") - version("20200303", sha256="9aa56dfb8673a06e6c88588505ec1dfc01dd94f9d60e719ed0c605e48cc06c58") - version("20200227", sha256="1aabcf38bc72285797c710b648e906151a912c36b634a9c88ac383aacf85516e") - version("20200218", sha256="73bcf146660804ced954f6a0a8dce937482677778d46018ca5a688127bf97211") - version("20200204", sha256="3bf3de546ede34ffcd89f1fca5fd66aa78c662e7c8a76e30ce593e44a00d23ce") - version("20200124", sha256="443829560d760690e1ae21ad54922f56f34f640a81e817f5cc65d2a4af3a6a5d") - version("20200109", sha256="f2fd24f6c10837801f490913d73f672ec7c6becda08465d7e834a2bfbe3d7cd6") - version("20191120", sha256="fd146bf517a6c2fb8a69ecb3749dc352eef94414739cd7855c668c690af85d27") - version("20191030", sha256="5279567f731386ffdb87800b448903a63de2591064e13b4d5216acae25b7e541") - version("20190919", sha256="0f693203afe86bc70c084c55f29330bdeea3e3ad6791f81c727f7a34a7f6caf3") - version("20190807", sha256="895d71914057e070fdf0ae5ccf9d6552b932355056690bdb8e86d96549218cc0") - version("20190605", sha256="c7b35090aef7b114d2b47a7298c1e8237dd811da87995c997bf7639cca743152") - version("20181212", sha256="ccc5d2c21c4b62ce4afe7b3a0fe2f37b83e5a5e43819b7c2e2e255cce2ce0f24") - version("20181207", sha256="d92104d008a7f1d0b6071011decc5c6dc8b936a3418b20bd34b055371302557f") - version("20181127", sha256="c076b633eda5506f895de4c73103df8b995d9fec01be82c67c7608efcc345179") - version("20181115", sha256="3bc9c166e465cac625c4a8e4060e597003f4619dadd57d3bc8d25bcd930f286e") - version("20181109", sha256="dd30fe492fa147fb6f39bfcc79d8c786b9689f7fbe86d56de58cace53b6198c9") - version("20181024", sha256="a171dff5aff7aaa2c9606ab2abc9260f2b685a5c7f6d650e7f2b59cf4aa149d6") - version("20181010", sha256="bda762ee2d2dcefe0b4e36fb689c6b9f7ede49324444ccde6c59cba727b4b02d") - version("20180918", sha256="02f143d518d8647b77137adc527faa9725c7afbc538d670253169e2a9b3fa0e6") - version("20180905", sha256="ee0df649e33a9bf4fe62e062452978731548a56b7487e8e1ce9403676217958d") - version("20180831", sha256="6c604b3ebd0cef1a5b18730d2c2eb1e659b2db65c5b1ae6240b8a0b150e4dff3") - version("20180822", sha256="9f8942ca3f8e81377ae88ccfd075da4e27d0dd677526085e1a807777c8324074") - version("20180629", sha256="1acf7d9b37b99f17563cd4c8bb00ec57bb2e29eb77c0603fd6871898de74763b") - version("20180316", sha256="a81f88c93e417ecb87cd5f5464c9a2570384a48ff13764051c5e846c3d1258c1") - version("20180222", sha256="374254d5131b7118b9ab0f0e27d20c3d13d96b03ed2b5224057f0c1065828694") - version("20170922", sha256="f0bf6eb530d528f4d261d0a261e5616cbb6e990156808b721e73234e463849d3") - version("20170901", sha256="5d88d4e92f4e0bb57c8ab30e0d20de556830af820223778b9967bec2184efd46") - - def url_for_version(self, version): - split_ver = str(version).split(".") - vdate = dt.datetime.strptime(split_ver[0], "%Y%m%d") - if len(split_ver) < 2: - update = "" - else: - update = "_update{0}".format(split_ver[1]) - return "https://github.com/lammps/lammps/archive/patch_{0}{1}.tar.gz".format( - vdate.strftime("%d%b%Y").lstrip("0"), update - ) - - # List of supported optional packages - # Note: package `openmp` in this recipe is called `openmp-package`, to avoid clash - # with the pre-existing `openmp` variant - supported_packages = [ - "asphere", - "body", - "bpm", - "class2", - "colloid", - "compress", - "coreshell", - "dielectric", - "dipole", - "electrode", - "granular", - "intel", - "kspace", - "kokkos", - "latte", - "manybody", - "mc", - "meam", - "misc", - "mliap", - "ml-iap", - "ml-snap", - "molecule", - "mpiio", - "opt", - "peri", - "plugin", - "poems", - "python", - "qeq", - "replica", - "rigid", - "shock", - "snap", - "spin", - "srd", - "voronoi", - "user-atc", - "user-adios", - "user-awpmd", - "user-bocs", - "user-brownian", - "user-cgsdk", - "user-colvars", - "user-diffraction", - "user-dpd", - "user-drude", - "user-eff", - "user-fep", - "user-h5md", - "user-intel", - "user-lb", - "user-manifold", - "user-meamc", - "user-mesodpd", - "user-mesont", - "user-mgpt", - "user-misc", - "user-mofff", - "user-molfile", - "user-netcdf", - "user-omp", - "user-phonon", - "user-plumed", - "user-ptm", - "user-qtb", - "user-reaction", - "user-reaxc", - "user-sdpd", - "user-smd", - "user-smtbq", - "user-sph", - "user-tally", - "user-uef", - "user-yaff", - "atc", - "adios", - "awpmd", - "bocs", - "brownian", - "cg-sdk", - "colvars", - "diffraction", - "dpd-basic", - "dpd-meso", - "dpd-react", - "dpd-smooth", - "drude", - "eff", - "extra-compute", - "extra-dump", - "extra-fix", - "extra-molecule", - "extra-pair", - "fep", - "h5md", - "interlayer", - "latboltz", - "machdyn", - "manifold", - "mesont", - "mgpt", - "mofff", - "molfile", - "netcdf", - "openmp-package", - "orient", - "phonon", - "plumed", - "ptm", - "qtb", - "reaction", - "reaxff", - "smtbq", - "sph", - "tally", - "uef", - "yaff", - ] - - for pkg in supported_packages: - variant( - pkg, - default=False, - description="Activate the {0} package".format(pkg.replace("-package", "")), - ) - variant("lib", default=True, description="Build the liblammps in addition to the executable") - variant("mpi", default=True, description="Build with mpi") - variant("jpeg", default=True, description="Build with jpeg support") - variant("png", default=True, description="Build with png support") - variant("ffmpeg", default=True, description="Build with ffmpeg support") - variant("kim", default=True, description="Build with KIM support") - variant("openmp", default=True, description="Build with OpenMP") - variant("opencl", default=False, description="Build with OpenCL") - variant("exceptions", default=False, description="Build with lammps exceptions") - variant( - "cuda_mps", - default=False, - description="(CUDA only) Enable tweaks for running " - + "with Nvidia CUDA Multi-process services daemon", - ) - - variant( - "lammps_sizes", - default="smallbig", - description="LAMMPS integer sizes (smallsmall: all 32-bit, smallbig:" - + "64-bit #atoms #timesteps, bigbig: also 64-bit imageint, 64-bit atom ids)", - values=("smallbig", "bigbig", "smallsmall"), - multi=False, - ) - variant( - "fftw_precision", - default="double", - when="+kspace", - description="Select FFTW precision (used by Kspace)", - values=("single", "double"), - multi=False, - ) - - depends_on("mpi", when="+mpi") - depends_on("mpi", when="+mpiio") - depends_on("fftw-api@3", when="+kspace") - depends_on("voropp+pic", when="+voronoi") - depends_on("netcdf-c+mpi", when="+user-netcdf") - depends_on("netcdf-c+mpi", when="+netcdf") - depends_on("blas", when="+user-atc") - depends_on("blas", when="+atc") - depends_on("lapack", when="+user-atc") - depends_on("lapack", when="+atc") - depends_on("opencl", when="+opencl") - depends_on("latte@1.0.1", when="@:20180222+latte") - depends_on("latte@1.1.1:", when="@20180316:20180628+latte") - depends_on("latte@1.2.1:", when="@20180629:20200505+latte") - depends_on("latte@1.2.2:", when="@20200602:+latte") - depends_on("blas", when="+latte") - depends_on("lapack", when="+latte") - depends_on("python", when="+python") - depends_on("mpi", when="+user-lb") - depends_on("mpi", when="+latboltz") - depends_on("mpi", when="+user-h5md") - depends_on("mpi", when="+h5md") - depends_on("hdf5", when="+user-h5md") - depends_on("hdf5", when="+h5md") - depends_on("jpeg", when="+jpeg") - depends_on("kim-api", when="+kim") - depends_on("libpng", when="+png") - depends_on("ffmpeg", when="+ffmpeg") - depends_on("kokkos+deprecated_code+shared@3.0.00", when="@20200303+kokkos") - depends_on("kokkos+shared@3.1:", when="@20200505:+kokkos") - depends_on("adios2", when="+user-adios") - depends_on("adios2", when="+adios") - depends_on("plumed", when="+user-plumed") - depends_on("plumed", when="+plumed") - depends_on("eigen@3:", when="+user-smd") - depends_on("eigen@3:", when="+machdyn") - depends_on("py-cython", when="+mliap+python") - depends_on("py-cython", when="+ml-iap+python") - depends_on("py-numpy", when="+mliap+python") - depends_on("py-numpy", when="+ml-iap+python") - depends_on("py-setuptools", when="@20220217:+python", type="build") - - conflicts("+cuda", when="+opencl") - conflicts("+body", when="+poems@:20180628") - conflicts("+latte", when="@:20170921") - conflicts("+python", when="~lib") - conflicts("+qeq", when="~manybody") - conflicts("+user-atc", when="~manybody") - conflicts("+atc", when="~manybody") - conflicts("+user-misc", when="~manybody") - conflicts("+user-phonon", when="~kspace") - conflicts("+phonon", when="~kspace") - conflicts("%gcc@9:", when="@:20200303+openmp") - conflicts("+kokkos", when="@:20200227") - conflicts("+dielectric", when="~kspace") - conflicts("+dielectric", when="@:20210702~user-misc") - conflicts("+dielectric", when="@20210728:~extra-pair") - conflicts( - "+meam", - when="@20181212:20210527", - msg="+meam is removed between @20181212 and @20210527, use +user-meamc instead", - ) - conflicts( - "+user-meamc", when="@:20181212", msg="+user-meamc only added @20181212, use +meam instead" - ) - conflicts( - "+user-reaction", - when="@:20200303", - msg="+user-reaction only supported for version 20200505 and later", - ) - conflicts( - "+plugin", when="@:20210310", msg="+plugin only supported for version 20210408 and later" - ) - conflicts( - "+user-brownian", - when="@:20210408", - msg="+user-brownian only supported for version 20210514 and later", - ) - conflicts( - "+dielectric", - when="@:20210527", - msg="+dielectric only supported for version 20210702 and later", - ) - conflicts( - "+dpd-basic", - when="@:20210527", - msg="+dpd-basic only supported for version 20210702 and later", - ) - conflicts("+bpm", when="@:20220324", msg="+bpm only supported for version 20220504 and later") - conflicts( - "+electrode", - when="@:20220324", - msg="+electrode only supported for version 20220504 and later", - ) - conflicts("+electrode", when="~kspace") - conflicts("+mliap", when="~snap") - conflicts("+ml-iap", when="~ml-snap") - conflicts( - "+user-adios +mpi", - when="^adios2~mpi", - msg="With +user-adios, mpi setting for adios2 and lammps must be the same", - ) - conflicts( - "+user-adios ~mpi", - when="^adios2+mpi", - msg="With +user-adios, mpi setting for adios2 and lammps must be the same", - ) - conflicts( - "+adios +mpi", - when="^adios2~mpi", - msg="With +adios, mpi setting for adios2 and lammps must be the same", - ) - conflicts( - "+adios ~mpi", - when="^adios2+mpi", - msg="With +adios, mpi setting for adios2 and lammps must be the same", - ) - - # In the following, package refactoring at 2 July 2021 - conflicts( - "+mliap", when="@20210702:", msg="+mliap was removed after @20210527, use +ml-iap instead" - ) - conflicts("+ml-iap", when="@:20210527", msg="+ml-iap only added @20210702, use +mliap instead") - conflicts( - "+snap", when="@20210702:", msg="+snap was removed after @20210527, use +ml-snap instead" - ) - conflicts( - "+ml-snap", when="@:20210527", msg="+ml-snap only added @20210702, use +snap instead" - ) - # - conflicts( - "+user-atc", - when="@20210702:", - msg="+user-atc was removed after @20210527, use +atc instead", - ) - conflicts("+atc", when="@:20210527", msg="+atc only added @20210702, use +user-atc instead") - conflicts( - "+user-adios", - when="@20210702:", - msg="+user-adios was removed after @20210527, use +adios instead", - ) - conflicts( - "+adios", when="@:20210527", msg="+adios only added @20210702, use +user-adios instead" - ) - conflicts( - "+user-awpmd", - when="@20210702:", - msg="+user-awpmd was removed after @20210527, use +awpmd instead", - ) - conflicts( - "+awpmd", when="@:20210527", msg="+awpmd only added @20210702, use +user-awpmd instead" - ) - conflicts( - "+user-bocs", - when="@20210702:", - msg="+user-bocs was removed after @20210527, use +bocs instead", - ) - conflicts("+bocs", when="@:20210527", msg="+bocs only added @20210702, use +user-bocs instead") - conflicts( - "+user-brownian", - when="@20210702:", - msg="+user-brownian was removed after @20210527, use +brownian instead", - ) - conflicts( - "+brownian", - when="@:20210527", - msg="+brownian only added @20210702, use +user-brownian instead", - ) - conflicts( - "+user-cgsdk", - when="@20210702:", - msg="+user-cgsdk was removed after @20210527, use +cg-sdk instead", - ) - conflicts( - "+cg-sdk", when="@:20210527", msg="+cg-sdk only added @20210702, use +user-cgsdk instead" - ) - conflicts( - "+user-colvars", - when="@20210702:", - msg="+user-colvars was removed after @20210527, use +colvars instead", - ) - conflicts( - "+colvars", - when="@:20210527", - msg="+colvars only added @20210702, use +user-colvars instead", - ) - conflicts( - "+user-diffraction", - when="@20210702:", - msg="+user-diffraction was removed after @20210527, use +diffraction instead", - ) - conflicts( - "+diffraction", - when="@:20210527", - msg="+diffraction only added @20210702, use +user-diffraction instead", - ) - conflicts( - "+user-dpd", - when="@20210702:", - msg="+user-dpd was removed after @20210527, use +dpd-react instead", - ) - conflicts( - "+dpd-react", - when="@:20210527", - msg="+dpd-react only added @20210702, use +user-dpd instead", - ) - conflicts( - "+user-drude", - when="@20210702:", - msg="+user-drude was removed after @20210527, use +drude instead", - ) - conflicts( - "+drude", when="@:20210527", msg="+drude only added @20210702, use +user-drude instead" - ) - conflicts( - "+user-eff", - when="@20210702:", - msg="+user-eff was removed after @20210527, use +eff instead", - ) - conflicts("+eff", when="@:20210527", msg="+eff only added @20210702, use +user-eff instead") - conflicts( - "+user-fep", - when="@20210702:", - msg="+user-fep was removed after @20210527, use +fep instead", - ) - conflicts("+fep", when="@:20210527", msg="+fep only added @20210702, use +user-fep instead") - conflicts( - "+user-h5md", - when="@20210702:", - msg="+user-h5md was removed after @20210527, use +h5md instead", - ) - conflicts("+h5md", when="@:20210527", msg="+h5md only added @20210702, use +user-h5md instead") - conflicts( - "+user-intel", - when="@20210702:", - msg="+user-intel was removed after @20210527, use +intel instead", - ) - conflicts( - "+intel", when="@:20210527", msg="+intel only added @20210702, use +user-intel instead" - ) - conflicts( - "+user-lb", - when="@20210702:", - msg="+user-lb was removed after @20210527, use +latboltz instead", - ) - conflicts( - "+latboltz", when="@:20210527", msg="+latboltz only added @20210702, use +user-lb instead" - ) - conflicts( - "+user-manifold", - when="@20210702:", - msg="+user-manifold was removed after @20210527, use +manifold instead", - ) - conflicts( - "+manifold", - when="@:20210527", - msg="+manifold only added @20210702, use +user-manifold instead", - ) - conflicts( - "+user-meamc", - when="@20210702:", - msg="+user-meamc was removed after @20210527, use +meam instead", - ) - conflicts( - "+user-mesodpd", - when="@20210702:", - msg="+user-mesodpd was removed after @20210527, use +dpd-meso instead", - ) - conflicts( - "+dpd-meso", - when="@:20210527", - msg="+dpd-meso only added @20210702, use +user-mesodpd instead", - ) - conflicts( - "+user-mesont", - when="@20210702:", - msg="+user-mesont was removed after @20210527, use +mesont instead", - ) - conflicts( - "+mesont", when="@:20210527", msg="+mesont only added @20210702, use +user-mesont instead" - ) - conflicts( - "+user-mgpt", - when="@20210702:", - msg="+user-mgpt was removed after @20210527, use +mgpt instead", - ) - conflicts("+mgpt", when="@:20210527", msg="+mgpt only added @20210702, use +user-mgpt instead") - conflicts( - "+user-mofff", - when="@20210702:", - msg="+user-mofff was removed after @20210527, use +mofff instead", - ) - conflicts( - "+mofff", when="@:20210527", msg="+mofff only added @20210702, use +user-mofff instead" - ) - conflicts( - "+user-molfile", - when="@20210702:", - msg="+user-molfile was removed after @20210527, use +molfile instead", - ) - conflicts( - "+molfile", - when="@:20210527", - msg="+molfile only added @20210702, use +user-molfile instead", - ) - conflicts( - "+user-netcdf", - when="@20210702:", - msg="+user-netcdf was removed after @20210527, use +netcdf instead", - ) - conflicts( - "+netcdf", when="@:20210527", msg="+netcdf only added @20210702, use +user-netcdf instead" - ) - conflicts( - "+user-omp", - when="@20210702:", - msg="+user-omp was removed after @20210527, use +openmp-package instead", - ) - conflicts( - "+openmp-package", - when="@:20210527", - msg="+openmp-package only added @20210702, use +user-omp instead", - ) - conflicts( - "+user-phonon", - when="@20210702:", - msg="+user-phonon was removed after @20210527, use +phonon instead", - ) - conflicts( - "+phonon", when="@:20210527", msg="+phonon only added @20210702, use +user-phonon instead" - ) - conflicts( - "+user-plumed", - when="@20210702:", - msg="+user-plumed was removed after @20210527, use +plumed instead", - ) - conflicts( - "+plumed", when="@:20210527", msg="+plumed only added @20210702, use +user-plumed instead" - ) - conflicts( - "+user-ptm", - when="@20210702:", - msg="+user-ptm was removed after @20210527, use +ptm instead", - ) - conflicts("+ptm", when="@:20210527", msg="+ptm only added @20210702, use +user-ptm instead") - conflicts( - "+user-qtb", - when="@20210702:", - msg="+user-qtb was removed after @20210527, use +qtb instead", - ) - conflicts("+qtb", when="@:20210527", msg="+qtb only added @20210702, use +user-qtb instead") - conflicts( - "+user-reaction", - when="@20210702:", - msg="+user-reaction was removed after @20210527, use +reaction instead", - ) - conflicts( - "+reaction", - when="@:20210527", - msg="+reaction only added @20210702, use +user-reaction instead", - ) - conflicts( - "+user-reaxc", - when="@20210702:", - msg="+user-reaxc was removed after @20210527, use +reaxff instead", - ) - conflicts( - "+reaxff", when="@:20210527", msg="+reaxff only added @20210702, use +user-reaxc instead" - ) - conflicts( - "+user-sdpd", - when="@20210702:", - msg="+user-sdpd was removed after @20210527, use +dpd-smooth instead", - ) - conflicts( - "+dpd-smooth", - when="@:20210527", - msg="+dpd-smooth only added @20210702, use +user-sdpd instead", - ) - conflicts( - "+user-smd", - when="@20210702:", - msg="+user-smd was removed after @20210527, use +machdyn instead", - ) - conflicts( - "+machdyn", when="@:20210527", msg="+machdyn only added @20210702, use +user-smd instead" - ) - conflicts( - "+user-smtbq", - when="@20210702:", - msg="+user-smtbq was removed after @20210527, use +smtbq instead", - ) - conflicts( - "+smtbq", when="@:20210527", msg="+smtbq only added @20210702, use +user-smtbq instead" - ) - conflicts( - "+user-sph", - when="@20210702:", - msg="+user-sph was removed after @20210527, use +sph instead", - ) - conflicts("+sph", when="@:20210527", msg="+sph only added @20210702, use +user-sph instead") - conflicts( - "+user-tally", - when="@20210702:", - msg="+user-tally was removed after @20210527, use +tally instead", - ) - conflicts( - "+tally", when="@:20210527", msg="+tally only added @20210702, use +user-tally instead" - ) - conflicts( - "+user-uef", - when="@20210702:", - msg="+user-uef was removed after @20210527, use +uef instead", - ) - conflicts("+uef", when="@:20210527", msg="+uef only added @20210702, use +user-uef instead") - conflicts( - "+user-yaff", - when="@20210702:", - msg="+user-yaff was removed after @20210527, use +yaff instead", - ) - conflicts("+yaff", when="@:20210527", msg="+yaff only added @20210702, use +user-yaff instead") - # In the following, package refactoring at 28 July 2021 - conflicts( - "+user-misc", - when="@20210728:", - msg="+user-misc was removed after @20210702, and split over multiple packages", - ) - conflicts( - "+extra-compute", - when="@:20210702", - msg="+extra-compute only added @20210728, use +user-misc instead", - ) - conflicts( - "+extra-dump", - when="@:20210702", - msg="+extra-dump only added @20210728, use +user-misc instead", - ) - conflicts( - "+extra-fix", - when="@:20210702", - msg="+extra-fix only added @20210728, use +user-misc instead", - ) - conflicts( - "+extra-molecule", - when="@:20210702", - msg="+extra-molecule only added @20210728, use +user-misc instead", - ) - conflicts( - "+extra-pair", - when="@:20210702", - msg="+extra-pair only added @20210728, use +user-misc instead", - ) - conflicts( - "+interlayer", - when="@:20210702", - msg="+interlayer only added @20210728, use +user-misc instead", - ) - conflicts( - "+orient", when="@:20210702", msg="+orient only added @20210728, use +user-misc instead" - ) - - patch("lib.patch", when="@20170901") - patch("660.patch", when="@20170922") - patch("gtest_fix.patch", when="@:20210310 %aocc@3.2.0") - patch( - "https://github.com/lammps/lammps/commit/562300996285fdec4ef74542383276898555af06.patch?full_index=1", - sha256="e6f1b62bbfdc79d632f4cea98019202d0dd25aa4ae61a70df1164cb4f290df79", - when="@20200721 +cuda", - ) - - root_cmakelists_dir = "cmake" - - def cmake_args(self): - spec = self.spec - - mpi_prefix = "ENABLE" - pkg_prefix = "ENABLE" - if spec.satisfies("@20180629:"): - mpi_prefix = "BUILD" - pkg_prefix = "PKG" - - args = [ - self.define_from_variant("BUILD_SHARED_LIBS", "lib"), - self.define_from_variant("LAMMPS_EXCEPTIONS", "exceptions"), - "-D{0}_MPI={1}".format(mpi_prefix, "ON" if "+mpi" in spec else "OFF"), - self.define_from_variant("BUILD_OMP", "openmp"), - "-DENABLE_TESTING=ON", - ] - if spec.satisfies("+cuda"): - args.append("-DPKG_GPU=ON") - args.append("-DGPU_API=cuda") - cuda_arch = spec.variants["cuda_arch"].value - if cuda_arch != "none": - args.append("-DGPU_ARCH=sm_{0}".format(cuda_arch[0])) - args.append(self.define_from_variant("CUDA_MPS_SUPPORT", "cuda_mps")) - elif spec.satisfies("+opencl"): - args.append("-DPKG_GPU=ON") - args.append("-DGPU_API=opencl") - else: - args.append("-DPKG_GPU=OFF") - - if spec.satisfies("@20180629:+lib"): - args.append("-DBUILD_LIB=ON") - - if spec.satisfies("%aocc"): - cxx_flags = "-Ofast -mfma -fvectorize -funroll-loops" - args.append(self.define("CMAKE_CXX_FLAGS_RELEASE", cxx_flags)) - - # Overwrite generic cpu tune option - cmake_tune_flags = archspec.cpu.TARGETS[spec.target.name].optimization_flags( - spec.compiler.name, spec.compiler.version - ) - args.append(self.define("CMAKE_TUNE_FLAGS", cmake_tune_flags)) - - lammps_sizes = self.spec.variants["lammps_sizes"].value - args.append(self.define("LAMMPS_SIZES", lammps_sizes)) - - args.append(self.define_from_variant("WITH_JPEG", "jpeg")) - args.append(self.define_from_variant("WITH_PNG", "png")) - args.append(self.define_from_variant("WITH_FFMPEG", "ffmpeg")) - - for pkg in self.supported_packages: - opt = "-D{0}_{1}".format(pkg_prefix, pkg.replace("-package", "").upper()) - if "+{0}".format(pkg) in spec: - args.append("{0}=ON".format(opt)) - else: - args.append("{0}=OFF".format(opt)) - if "+kim" in spec: - args.append("-DPKG_KIM=ON") - if "+kspace" in spec: - # If FFTW3 is selected, then CMake will try to detect, if threaded - # FFTW libraries are available and enable them by default. - if "^fftw" in spec: - args.append("-DFFT=FFTW3") - if "^mkl" in spec: - args.append("-DFFT=MKL") - if "^amdfftw" in spec: - args.append(self.define("FFT", "FFTW3")) - if "^cray-fftw" in spec: - args.append("-DFFT=FFTW3") - # Using the -DFFT_SINGLE setting trades off a little accuracy - # for reduced memory use and parallel communication costs - # for transposing 3d FFT data. - if spec.satisfies("fftw_precision=single"): - args.append("-DFFT_SINGLE=True") - else: - args.append("-DFFT_SINGLE=False") - - if "+kokkos" in spec: - args.append("-DEXTERNAL_KOKKOS=ON") - if "+user-adios" in spec or "+adios" in spec: - args.append("-DADIOS2_DIR={0}".format(self.spec["adios2"].prefix)) - if "+user-plumed" in spec or "+plumed" in spec: - args.append("-DDOWNLOAD_PLUMED=no") - if "+shared" in self.spec["plumed"]: - args.append("-DPLUMED_MODE=shared") - else: - args.append("-DPLUMED_MODE=static") - if "+user-smd" in spec or "+machdyn" in spec: - args.append("-DDOWNLOAD_EIGEN3=no") - args.append("-DEIGEN3_INCLUDE_DIR={0}".format(self.spec["eigen"].prefix.include)) - - return args - - def setup_run_environment(self, env): - env.set("LAMMPS_POTENTIALS", self.prefix.share.lammps.potentials) From 1ebde3ba4ac278da432956b24e73703c41dbd131 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Tue, 8 Aug 2023 16:59:39 +0800 Subject: [PATCH 14/21] Contributed more recipes. --- repo/packages/ncview/package.py | 36 ----- repo/packages/py-mpi4py/package.py | 44 ----- repo/packages/py-pip/package.py | 113 ------------- repo/packages/py-setuptools/package.py | 212 ------------------------- 4 files changed, 405 deletions(-) delete mode 100644 repo/packages/ncview/package.py delete mode 100644 repo/packages/py-mpi4py/package.py delete mode 100644 repo/packages/py-pip/package.py delete mode 100644 repo/packages/py-setuptools/package.py diff --git a/repo/packages/ncview/package.py b/repo/packages/ncview/package.py deleted file mode 100644 index 7be7a1ed..00000000 --- a/repo/packages/ncview/package.py +++ /dev/null @@ -1,36 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -#13c13 -#< url = "ftp://cirrus.ucsd.edu/pub/ncview/ncview-2.1.7.tar.gz" -#--- -#> url = "https://cirrus.ucsd.edu/~pierce/ncview/ncview-2.1.9.tar.gz" - -from spack.package import * - - -class Ncview(AutotoolsPackage): - """Simple viewer for NetCDF files.""" - - homepage = "https://cirrus.ucsd.edu/ncview/" - url = "https://cirrus.ucsd.edu/~pierce/ncview/ncview-2.1.9.tar.gz" - - version("2.1.8", sha256="e8badc507b9b774801288d1c2d59eb79ab31b004df4858d0674ed0d87dfc91be") - version("2.1.7", sha256="a14c2dddac0fc78dad9e4e7e35e2119562589738f4ded55ff6e0eca04d682c82") - - depends_on("netcdf-c") - depends_on("udunits") - depends_on("libpng") - depends_on("libxaw") - - def configure_args(self): - spec = self.spec - - config_args = [] - - if spec.satisfies("^netcdf-c+mpi"): - config_args.append("CC={0}".format(spec["mpi"].mpicc)) - - return config_args diff --git a/repo/packages/py-mpi4py/package.py b/repo/packages/py-mpi4py/package.py deleted file mode 100644 index ee5ee4ad..00000000 --- a/repo/packages/py-mpi4py/package.py +++ /dev/null @@ -1,44 +0,0 @@ -# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# PAWSEY MOD: changes the way MPICC is set. This should be contributed to the main repo as their way does not work. -from spack.package import * - - -class PyMpi4py(PythonPackage): - """This package provides Python bindings for the Message Passing - Interface (MPI) standard. It is implemented on top of the - MPI-1/MPI-2 specification and exposes an API which grounds on the - standard MPI-2 C++ bindings. - """ - - pypi = "mpi4py/mpi4py-3.0.3.tar.gz" - git = "https://github.com/mpi4py/mpi4py.git" - - version("master", branch="master") - version("3.1.4", sha256="17858f2ebc623220d0120d1fa8d428d033dde749c4bc35b33d81a66ad7f93480") - version("3.1.3", sha256="f1e9fae1079f43eafdd9f817cdb3fd30d709edc093b5d5dada57a461b2db3008") - version("3.1.2", sha256="40dd546bece8f63e1131c3ceaa7c18f8e8e93191a762cd446a8cfcf7f9cce770") - version("3.1.1", sha256="e11f8587a3b93bb24c8526addec664b586b965d83c0882b884c14dc3fd6b9f5c") - version("3.1.0", sha256="134fa2b2fe6d8f91bcfcc2824cfd74b55ca3dcbff4d185b1bda009beea9232ec") - version("3.0.3", sha256="012d716c8b9ed1e513fcc4b18e5af16a8791f51e6d1716baccf988ad355c5a1f") - version("3.0.1", sha256="6549a5b81931303baf6600fa2e3bc04d8bd1d5c82f3c21379d0d64a9abcca851") - version("3.0.0", sha256="b457b02d85bdd9a4775a097fac5234a20397b43e073f14d9e29b6cd78c68efd7") - version("2.0.0", sha256="6543a05851a7aa1e6d165e673d422ba24e45c41e4221f0993fe1e5924a00cb81") - version("1.3.1", sha256="e7bd2044aaac5a6ea87a87b2ecc73b310bb6efe5026031e33067ea3c2efc3507") - - depends_on("python@2.6:2.7,3.2:") - depends_on("python@2.7:2.8,3.5:", when="@3.1:") - depends_on("py-setuptools@40.9:", type="build") - depends_on("mpi") - depends_on("py-cython@0.27.0:", type="build") - - @when("@3.1:") - def setup_build_environment(self, env): - env.set('MPICC', f"{self.spec['mpi'].mpicc} -shared") - - @run_before("install") - def cythonize(self): - with working_dir(self.build_directory): - python(join_path("conf", "cythonize.py")) diff --git a/repo/packages/py-pip/package.py b/repo/packages/py-pip/package.py deleted file mode 100644 index aaa08b1a..00000000 --- a/repo/packages/py-pip/package.py +++ /dev/null @@ -1,113 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -# ADDS A NEW VERSION - -import os - -from spack.package import * - - -class PyPip(Package): - """The PyPA recommended tool for installing Python packages.""" - - homepage = "https://pip.pypa.io/" - url = "https://files.pythonhosted.org/packages/py3/p/pip/pip-20.2-py3-none-any.whl" - list_url = "https://pypi.org/simple/pip/" - - maintainers = ["adamjstewart", "pradyunsg"] - - version( - "23.1.2", - sha256="3ef6ac33239e4027d9a5598a381b9d30880a1477e50039db2eac6e8a8f6d1b18", - expand=False, - ) - - version( - "22.2.2", - sha256="b61a374b5bc40a6e982426aede40c9b5a08ff20e640f5b56977f4f91fed1e39a", - expand=False, - ) - version( - "22.1.2", - sha256="a3edacb89022ef5258bf61852728bf866632a394da837ca49eb4303635835f17", - expand=False, - ) - version( - "21.3.1", - sha256="deaf32dcd9ab821e359cd8330786bcd077604b5c5730c0b096eda46f95c24a2d", - expand=False, - ) - version( - "21.1.2", - sha256="f8ea1baa693b61c8ad1c1d8715e59ab2b93cd3c4769bacab84afcc4279e7a70e", - expand=False, - ) - version( - "20.2", - sha256="d75f1fc98262dabf74656245c509213a5d0f52137e40e8f8ed5cc256ddd02923", - expand=False, - ) - version( - "19.3", - sha256="e100a7eccf085f0720b4478d3bb838e1c179b1e128ec01c0403f84e86e0e2dfb", - expand=False, - ) - version( - "19.1.1", - sha256="993134f0475471b91452ca029d4390dc8f298ac63a712814f101cd1b6db46676", - expand=False, - ) - version( - "19.0.3", - sha256="bd812612bbd8ba84159d9ddc0266b7fbce712fc9bc98c82dee5750546ec8ec64", - expand=False, - ) - version( - "18.1", - sha256="7909d0a0932e88ea53a7014dfd14522ffef91a464daaaf5c573343852ef98550", - expand=False, - ) - version( - "10.0.1", - sha256="717cdffb2833be8409433a93746744b59505f42146e8d37de6c62b430e25d6d7", - expand=False, - ) - version( - "9.0.1", - sha256="690b762c0a8460c303c089d5d0be034fb15a5ea2b75bdf565f40421f542fefb0", - expand=False, - ) - - extends("python") - depends_on("python@3.7:", when="@22:", type=("build", "run")) - depends_on("python@3.6:", when="@21:", type=("build", "run")) - depends_on("python@2.7:2.8,3.5:", when="@19.2:", type=("build", "run")) - depends_on("python@2.7:2.8,3.4:", when="@18:", type=("build", "run")) - depends_on("python@2.7:2.8,3.3:", when="@10:", type=("build", "run")) - depends_on("python@2.6:2.8,3.3:", type=("build", "run")) - - def url_for_version(self, version): - url = "https://files.pythonhosted.org/packages/{0}/p/pip/pip-{1}-{0}-none-any.whl" - if version >= Version("21"): - python_tag = "py3" - else: - python_tag = "py2.py3" - return url.format(python_tag, version) - - def install(self, spec, prefix): - # To build and install pip from source, you need setuptools, wheel, and pip - # already installed. We get around this by using a pre-built wheel to install - # itself, see: - # https://discuss.python.org/t/bootstrapping-a-specific-version-of-pip/12306 - whl = self.stage.archive_file - args = [os.path.join(whl, "pip")] + std_pip_args + ["--prefix=" + prefix, whl] - python(*args) - - def setup_dependent_package(self, module, dependent_spec): - pip = dependent_spec["python"].command - pip.add_default_arg("-m") - pip.add_default_arg("pip") - setattr(module, "pip", pip) diff --git a/repo/packages/py-setuptools/package.py b/repo/packages/py-setuptools/package.py deleted file mode 100644 index 33d96097..00000000 --- a/repo/packages/py-setuptools/package.py +++ /dev/null @@ -1,212 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -# ADDS a new version -from spack.package import * - - -class PySetuptools(Package): - """A Python utility that aids in the process of downloading, building, - upgrading, installing, and uninstalling Python packages.""" - - homepage = "https://github.com/pypa/setuptools" - url = "https://files.pythonhosted.org/packages/py3/s/setuptools/setuptools-62.3.2-py3-none-any.whl" - list_url = "https://pypi.org/simple/setuptools/" - - maintainers = ["adamjstewart"] - - version( - "68.0.0", - sha256="11e52c67415a381d10d6b462ced9cfb97066179f0e871399e006c4ab101fc85f", - expand=False - ) - version( - "65.5.0", - sha256="f62ea9da9ed6289bfe868cd6845968a2c854d1427f8548d52cae02a42b4f0356", - expand=False, - ) - version( - "65.0.0", - sha256="fe9a97f68b064a6ddd4bacfb0b4b93a4c65a556d97ce906255540439d0c35cef", - expand=False, - ) - version( - "64.0.0", - sha256="63f463b90ff5e0a1422010100268fd688e15c44ae0798659013c8412963e15e4", - expand=False, - ) - version( - "63.0.0", - sha256="045aec56a3eee5c82373a70e02db8b6da9a10f7faf61ff89a14ab66c738ed370", - expand=False, - ) - version( - "62.6.0", - sha256="c1848f654aea2e3526d17fc3ce6aeaa5e7e24e66e645b5be2171f3f6b4e5a178", - expand=False, - ) - version( - "62.4.0", - sha256="5a844ad6e190dccc67d6d7411d119c5152ce01f7c76be4d8a1eaa314501bba77", - expand=False, - ) - version( - "62.3.2", - sha256="68e45d17c9281ba25dc0104eadd2647172b3472d9e01f911efa57965e8d51a36", - expand=False, - ) - version( - "59.4.0", - sha256="feb5ff19b354cde9efd2344ef6d5e79880ce4be643037641b49508bbb850d060", - expand=False, - ) - version( - "58.2.0", - sha256="2551203ae6955b9876741a26ab3e767bb3242dafe86a32a749ea0d78b6792f11", - expand=False, - ) - version( - "57.4.0", - sha256="a49230977aa6cfb9d933614d2f7b79036e9945c4cdd7583163f4e920b83418d6", - expand=False, - ) - version( - "57.1.0", - sha256="ddae4c1b9220daf1e32ba9d4e3714df6019c5b583755559be84ff8199f7e1fe3", - expand=False, - ) - version( - "51.0.0", - sha256="8c177936215945c9a37ef809ada0fab365191952f7a123618432bbfac353c529", - expand=False, - ) - version( - "50.3.2", - sha256="2c242a0856fbad7efbe560df4a7add9324f340cf48df43651e9604924466794a", - expand=False, - ) - version( - "50.1.0", - sha256="4537c77e6e7dc170081f8547564551d4ff4e4999717434e1257600bbd3a23296", - expand=False, - ) - version( - "49.6.0", - sha256="4dd5bb0a0a0cff77b46ca5dd3a84857ee48c83e8223886b556613c724994073f", - expand=False, - ) - version( - "49.2.0", - sha256="272c7f48f5cddc5af5901f4265274c421c7eede5c8bc454ac2903d3f8fc365e9", - expand=False, - ) - version( - "46.1.3", - sha256="4fe404eec2738c20ab5841fa2d791902d2a645f32318a7850ef26f8d7215a8ee", - expand=False, - ) - version( - "44.1.1", - sha256="27a714c09253134e60a6fa68130f78c7037e5562c4f21f8f318f2ae900d152d5", - expand=False, - ) - version( - "44.1.0", - sha256="992728077ca19db6598072414fb83e0a284aca1253aaf2e24bb1e55ee6db1a30", - expand=False, - ) - version( - "43.0.0", - sha256="a67faa51519ef28cd8261aff0e221b6e4c370f8fb8bada8aa3e7ad8945199963", - expand=False, - ) - version( - "41.4.0", - sha256="8d01f7ee4191d9fdcd9cc5796f75199deccb25b154eba82d44d6a042cf873670", - expand=False, - ) - version( - "41.3.0", - sha256="e9832acd9be6f3174f4c34b40e7d913a146727920cbef6465c1c1bd2d21a4ec4", - expand=False, - ) - version( - "41.0.1", - sha256="c7769ce668c7a333d84e17fe8b524b1c45e7ee9f7908ad0a73e1eda7e6a5aebf", - expand=False, - ) - version( - "41.0.0", - sha256="e67486071cd5cdeba783bd0b64f5f30784ff855b35071c8670551fd7fc52d4a1", - expand=False, - ) - version( - "40.8.0", - sha256="e8496c0079f3ac30052ffe69b679bd876c5265686127a3159cfa415669b7f9ab", - expand=False, - ) - version( - "40.4.3", - sha256="ce4137d58b444bac11a31d4e0c1805c69d89e8ed4e91fde1999674ecc2f6f9ff", - expand=False, - ) - version( - "40.2.0", - sha256="ea3796a48a207b46ea36a9d26de4d0cc87c953a683a7b314ea65d666930ea8e6", - expand=False, - ) - version( - "39.2.0", - sha256="8fca9275c89964f13da985c3656cb00ba029d7f3916b37990927ffdf264e7926", - expand=False, - ) - version( - "39.0.1", - sha256="8010754433e3211b9cdbbf784b50f30e80bf40fc6b05eb5f865fab83300599b8", - expand=False, - ) - version( - "25.2.0", - sha256="2845247c359bb91097ccf8f6be8a69edfa44847f3d2d5def39aa43c3d7f615ca", - expand=False, - ) - version( - "20.7.0", - sha256="8917a52aa3a389893221b173a89dae0471022d32bff3ebc31a1072988aa8039d", - expand=False, - ) - version( - "20.6.7", - sha256="9982ee4d279a2541dc1a7efee994ff9c535cfc05315e121e09df7f93da48c442", - expand=False, - ) - - extends("python") - depends_on("python@3.7:", when="@59.7:", type=("build", "run")) - depends_on("python@3.6:", when="@51:", type=("build", "run")) - depends_on("python@3.5:", when="@45:50", type=("build", "run")) - depends_on("python@2.7:2.8,3.5:", when="@44", type=("build", "run")) - depends_on("python@2.7:2.8,3.4:", when="@:43", type=("build", "run")) - depends_on("py-pip", type="build") - - def url_for_version(self, version): - url = "https://files.pythonhosted.org/packages/{0}/s/setuptools/setuptools-{1}-{0}-none-any.whl" - - if version >= Version("45.1.0"): - python_tag = "py3" - else: - python_tag = "py2.py3" - return url.format(python_tag, version) - - def install(self, spec, prefix): - # When setuptools changes its entry point we might get weird - # incompatibilities if building from sources in a non-isolated environment. - # - # https://github.com/pypa/setuptools/issues/980#issuecomment-1154471423 - # - # We work around this issue by installing setuptools from wheels - whl = self.stage.archive_file - args = ["-m", "pip"] + std_pip_args + ["--prefix=" + prefix, whl] - python(*args) From 0b13cee2b61865f92096c3fde152461582c468f3 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Thu, 10 Aug 2023 14:00:21 +0800 Subject: [PATCH 15/21] Removed more recipes. --- repo/packages/libzmq/package.py | 85 ---- repo/packages/nwchem/fftw_splans.patch | 643 ------------------------- repo/packages/nwchem/fj.patch | 147 ------ repo/packages/nwchem/package.py | 167 ------- repo/packages/plumed/package.py | 299 ------------ repo/packages/py-botocore/package.py | 49 -- repo/packages/py-docutils/package.py | 53 -- 7 files changed, 1443 deletions(-) delete mode 100644 repo/packages/libzmq/package.py delete mode 100644 repo/packages/nwchem/fftw_splans.patch delete mode 100644 repo/packages/nwchem/fj.patch delete mode 100644 repo/packages/nwchem/package.py delete mode 100644 repo/packages/plumed/package.py delete mode 100644 repo/packages/py-botocore/package.py delete mode 100644 repo/packages/py-docutils/package.py diff --git a/repo/packages/libzmq/package.py b/repo/packages/libzmq/package.py deleted file mode 100644 index 969932c9..00000000 --- a/repo/packages/libzmq/package.py +++ /dev/null @@ -1,85 +0,0 @@ -# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -# Differences for the 'libzmq' package -# 6c6 -# < from spack.package import * -# --- -# > from spack import * -# 68,69d67 -# < # disable warnings to errors -# < config_args.append('--disable-Werror') -# Contribute: on new compilers it won't compile because warnings are converted to errors. -from spack.package import * - - -class Libzmq(AutotoolsPackage): - """The ZMQ networking/concurrency library and core API""" - - homepage = "https://zguide.zeromq.org/" - url = "https://github.com/zeromq/libzmq/releases/download/v4.3.2/zeromq-4.3.2.tar.gz" - git = "https://github.com/zeromq/libzmq.git" - - version('master', branch='master') - version('4.3.3', sha256='9d9285db37ae942ed0780c016da87060497877af45094ff9e1a1ca736e3875a2') - version('4.3.2', sha256='ebd7b5c830d6428956b67a0454a7f8cbed1de74b3b01e5c33c5378e22740f763') - version('4.3.1', sha256='bcbabe1e2c7d0eec4ed612e10b94b112dd5f06fcefa994a0c79a45d835cd21eb') - version('4.3.0', sha256='8e9c3af6dc5a8540b356697081303be392ade3f014615028b3c896d0148397fd') - version('4.2.5', sha256='cc9090ba35713d59bb2f7d7965f877036c49c5558ea0c290b0dcc6f2a17e489f') - version('4.2.2', sha256='5b23f4ca9ef545d5bd3af55d305765e3ee06b986263b31967435d285a3e6df6b') - version('4.1.4', sha256='e99f44fde25c2e4cb84ce440f87ca7d3fe3271c2b8cfbc67d55e4de25e6fe378') - version('4.1.2', sha256='f9162ead6d68521e5154d871bac304f88857308bb02366b81bb588497a345927') - version('4.1.1', sha256='43d61e5706b43946aad4a661400627bcde9c63cc25816d4749c67b64c3dab8db') - version('4.0.7', sha256='e00b2967e074990d0538361cc79084a0a92892df2c6e7585da34e4c61ee47b03') - version('4.0.6', sha256='28a2a9c9b77014c39087a498942449df18bb9885cdb63334833525a1d19f2894') - version('4.0.5', sha256='3bc93c5f67370341428364ce007d448f4bb58a0eaabd0a60697d8086bc43342b') - - variant("libsodium", default=True, - description="Build with message encryption support via libsodium") - - variant("drafts", default=False, - description="Build and install draft classes and methods") - - depends_on("libsodium", when='+libsodium') - depends_on("libsodium@:1.0.3", when='+libsodium@:4.1.2') - - depends_on('autoconf', type='build', when='@develop') - depends_on('automake', type='build', when='@develop') - depends_on('libtool', type='build', when='@develop') - depends_on('pkgconfig', type='build') - - depends_on('libbsd', type='link', when='@4.3.3: platform=linux') - depends_on('libbsd', type='link', when='@4.3.3: platform=cray') - - conflicts('%gcc@8:', when='@:4.2.2') - - # Fix aggressive compiler warning false positive - patch('https://github.com/zeromq/libzmq/commit/92b2c38a2c51a1942a380c7ee08147f7b1ca6845.patch', sha256='8ebde83ee148989f9118d36ebaf256532627b8a6e7a486842110623331972edb', when='@4.2.3:4.3.4 %gcc@11:') - - def url_for_version(self, version): - if version <= Version('4.1.4'): - url = "http://download.zeromq.org/zeromq-{0}.tar.gz" - else: - url = "https://github.com/zeromq/libzmq/releases/download/v{0}/zeromq-{0}.tar.gz" - return url.format(version) - - @when('@develop') - def autoreconf(self, spec, prefix): - bash = which('bash') - bash('./autogen.sh') - - def configure_args(self): - config_args = [] - - config_args.extend(self.enable_or_disable("drafts")) - # disable warnings to errors - config_args.append('--disable-Werror') - - if '+libsodium' in self.spec: - config_args.append('--with-libsodium') - if 'clang' in self.compiler.cc: - config_args.append("CFLAGS=-Wno-gnu") - config_args.append("CXXFLAGS=-Wno-gnu") - return config_args diff --git a/repo/packages/nwchem/fftw_splans.patch b/repo/packages/nwchem/fftw_splans.patch deleted file mode 100644 index 3eed13b8..00000000 --- a/repo/packages/nwchem/fftw_splans.patch +++ /dev/null @@ -1,643 +0,0 @@ -From b4ec4ade1af434bc80470d6874aebf6fdcd12489 Mon Sep 17 00:00:00 2001 -From: Eric Bylaska -Date: Thu, 8 Jun 2023 14:21:43 -0700 -Subject: [PATCH] changing old fortran interface for fftw to be sfftw for - single precision...EJB - ---- - src/nwpw/nwpwlib/D3dB/D3dB-new.F | 3 +- - src/nwpw/nwpwlib/D3dB/D3dBs-new.F | 69 +++++++++++++++--------------- - src/nwpw/nwpwlib/D3dB/D3dBs_pfft.F | 64 +++++++++++++-------------- - src/nwpw/nwpwlib/D3dB/GNUmakefile | 4 +- - 4 files changed, 72 insertions(+), 68 deletions(-) - -diff --git a/src/nwpw/nwpwlib/D3dB/D3dB-new.F b/src/nwpw/nwpwlib/D3dB/D3dB-new.F -index fb00838d2c..2159707831 100644 ---- a/src/nwpw/nwpwlib/D3dB/D3dB-new.F -+++ b/src/nwpw/nwpwlib/D3dB/D3dB-new.F -@@ -1183,7 +1183,8 @@ subroutine D3dB_fft_init(nb) - common / D3dB_fft / tmpx,tmpy,tmpz - - #ifdef FFTW3 --#include "fftw3.fh" -+!#include "fftw3.fh" -+#include "fftw3.f" - integer Atest(2),nxh,nxhz,nxhy - #endif - -diff --git a/src/nwpw/nwpwlib/D3dB/D3dBs-new.F b/src/nwpw/nwpwlib/D3dB/D3dBs-new.F -index 90127b7ff1..8ddfddad34 100644 ---- a/src/nwpw/nwpwlib/D3dB/D3dBs-new.F -+++ b/src/nwpw/nwpwlib/D3dB/D3dBs-new.F -@@ -195,7 +195,8 @@ subroutine D3dBs_fft_init(nb) - common / D3dBs_fft / tmpx,tmpy,tmpz - - #ifdef FFTW3 --#include "fftw3.fh" -+!#include "fftw3.fh" -+#include "fftw3.f" - integer Atest(2),nxh,nxhz,nxhy - #endif - -@@ -248,48 +249,48 @@ subroutine D3dBs_fft_init(nb) - > 'Atest',Atest(2),Atest(1))) - > call errquit('D3dBs_fft_init:out of heap memory',0,MA_ERR) - -- call fftw_plan_many_dft(splans(1,nb),1,nz(nb),nxh, -+ call sfftw_plan_many_dft(splans(1,nb),1,nz(nb),nxh, - > scpl_mb(Atest(1)),nxhz,nxh,1, - > scpl_mb(Atest(1)),nxhz,nxh,1, - > ibackward,FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft(splans(2,nb),1,ny(nb),nxh, -+ call sfftw_plan_many_dft(splans(2,nb),1,ny(nb),nxh, - > scpl_mb(Atest(1)),nxhy,nxh,1, - > scpl_mb(Atest(1)),nxhy,nxh,1, - > ibackward,FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft_c2r(splans(3,nb),1,nx(nb), -+ call sfftw_plan_many_dft_c2r(splans(3,nb),1,nx(nb), - > ny(nb)*nq(nb), - > scpl_mb(Atest(1)),nxh *ny(nb)*nq(nb),1,nxh, - > scpl_mb(Atest(1)),(nx(nb)+2)*ny(nb)*nq(nb),1,nx(nb)+2, - > FFTW_EXHAUSTIVE) - -- call fftw_plan_many_dft_r2c(splans(4,nb),1,nx(nb), -+ call sfftw_plan_many_dft_r2c(splans(4,nb),1,nx(nb), - > ny(nb)*nq(nb), - > scpl_mb(Atest(1)),(nx(nb)+2)*ny(nb)*nq(nb),1,nx(nb)+2, - > scpl_mb(Atest(1)),nxh *ny(nb)*nq(nb),1,nxh, - > FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft(splans(5,nb),1,ny(nb),nxh, -+ call sfftw_plan_many_dft(splans(5,nb),1,ny(nb),nxh, - > scpl_mb(Atest(1)),nxhy,nxh,1, - > scpl_mb(Atest(1)),nxhy,nxh,1, - > iforward,FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft(splans(6,nb),1,nz(nb),nxh, -+ call sfftw_plan_many_dft(splans(6,nb),1,nz(nb),nxh, - > scpl_mb(Atest(1)),nxhz,nxh,1, - > scpl_mb(Atest(1)),nxhz,nxh,1, - > iforward,FFTW_EXHAUSTIVE) - -- call fftw_plan_many_dft(splans(7,nb),1,nz(nb),1, -+ call sfftw_plan_many_dft(splans(7,nb),1,nz(nb),1, - > scpl_mb(Atest(1)),nxhz,nxh,1, - > scpl_mb(Atest(1)),nxhz,nxh,1, - > ibackward,FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft(splans(8,nb),1,ny(nb),1, -+ call sfftw_plan_many_dft(splans(8,nb),1,ny(nb),1, - > scpl_mb(Atest(1)),nxhy,nxh,1, - > scpl_mb(Atest(1)),nxhy,nxh,1, - > ibackward,FFTW_EXHAUSTIVE) - -- call fftw_plan_many_dft(splans(9,nb),1,ny(nb),1, -+ call sfftw_plan_many_dft(splans(9,nb),1,ny(nb),1, - > scpl_mb(Atest(1)),nxhy,nxh,1, - > scpl_mb(Atest(1)),nxhy,nxh,1, - > iforward,FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft(splans(10,nb),1,nz(nb),1, -+ call sfftw_plan_many_dft(splans(10,nb),1,nz(nb),1, - > scpl_mb(Atest(1)),nxhz,nxh,1, - > scpl_mb(Atest(1)),nxhz,nxh,1, - > iforward,FFTW_EXHAUSTIVE) -@@ -305,48 +306,48 @@ subroutine D3dBs_fft_init(nb) - > Atest(2),Atest(1))) - > call errquit('D3dBs_fft_init:out of heap memory',0,MA_ERR) - -- call fftw_plan_many_dft(splans(11,nb),1,nz(nb),nq3(nb), -+ call sfftw_plan_many_dft(splans(11,nb),1,nz(nb),nq3(nb), - > scpl_mb(Atest(1)),nz(nb)*nq3(nb),1,nz(nb), - > scpl_mb(Atest(1)),nz(nb)*nq3(nb),1,nz(nb), - > ibackward,FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft(splans(12,nb),1,ny(nb),nq2(nb), -+ call sfftw_plan_many_dft(splans(12,nb),1,ny(nb),nq2(nb), - > scpl_mb(Atest(1)),ny(nb)*nq2(nb),1,ny(nb), - > scpl_mb(Atest(1)),ny(nb)*nq2(nb),1,ny(nb), - > ibackward,FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft_c2r(splans(13,nb),1,nx(nb), -+ call sfftw_plan_many_dft_c2r(splans(13,nb),1,nx(nb), - > nq1(nb), - > scpl_mb(Atest(1)),nfft3d(nb),1,nxh, - > scpl_mb(Atest(1)),n2ft3d(nb),1,(nx(nb)+2), - > FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft_r2c(splans(14,nb),1,nx(nb), -+ call sfftw_plan_many_dft_r2c(splans(14,nb),1,nx(nb), - > nq1(nb), - > scpl_mb(Atest(1)),n2ft3d(nb),1,nx(nb)+2, - > scpl_mb(Atest(1)),nfft3d(nb),1,nxh, - > FFTW_EXHAUSTIVE) - -- call fftw_plan_many_dft(splans(15,nb),1,ny(nb),nq2(nb), -+ call sfftw_plan_many_dft(splans(15,nb),1,ny(nb),nq2(nb), - > scpl_mb(Atest(1)),ny(nb)*nq2(nb),1,ny(nb), - > scpl_mb(Atest(1)),ny(nb)*nq2(nb),1,ny(nb), - > iforward,FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft(splans(16,nb),1,nz(nb),nq3(nb), -+ call sfftw_plan_many_dft(splans(16,nb),1,nz(nb),nq3(nb), - > scpl_mb(Atest(1)),nz(nb)*nq3(nb),1,nz(nb), - > scpl_mb(Atest(1)),nz(nb)*nq3(nb),1,nz(nb), - > iforward,FFTW_EXHAUSTIVE) - -- call fftw_plan_many_dft(splans(17,nb),1,nz(nb),1, -+ call sfftw_plan_many_dft(splans(17,nb),1,nz(nb),1, - > scpl_mb(Atest(1)),nz(nb),1,1, - > scpl_mb(Atest(1)),nz(nb),1,1, - > ibackward,FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft(splans(18,nb),1,ny(nb),1, -+ call sfftw_plan_many_dft(splans(18,nb),1,ny(nb),1, - > scpl_mb(Atest(1)),ny(nb),1,1, - > scpl_mb(Atest(1)),ny(nb),1,1, - > ibackward,FFTW_EXHAUSTIVE) - -- call fftw_plan_many_dft(splans(19,nb),1,ny(nb),1, -+ call sfftw_plan_many_dft(splans(19,nb),1,ny(nb),1, - > scpl_mb(Atest(1)),ny(nb),1,1, - > scpl_mb(Atest(1)),ny(nb),1,1, - > iforward,FFTW_EXHAUSTIVE) -- call fftw_plan_many_dft(splans(20,nb),1,nz(nb),1, -+ call sfftw_plan_many_dft(splans(20,nb),1,nz(nb),1, - > scpl_mb(Atest(1)),nz(nb),1,1, - > scpl_mb(Atest(1)),nz(nb),1,1, - > iforward,FFTW_EXHAUSTIVE) -@@ -388,7 +389,7 @@ subroutine D3dBs_fft_end(nb) - - #ifdef FFTW3 - do i=1,nplans -- if (splans(i,nb).ne.0) call fftw_destroy_plan(splans(i,nb)) -+ if (splans(i,nb).ne.0) call sfftw_destroy_plan(splans(i,nb)) - end do - #endif - -@@ -497,7 +498,7 @@ subroutine D3dBs_cr_fft3b(nb,A) - #ifdef FFTW3 - do q=1,nq(nb) - indx = 1+(q-1)*nxhz -- call fftw_execute_dft(pslans(1,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(1,nb),A(indx),A(indx)) - end do - #else - indx0 = 0 -@@ -536,7 +537,7 @@ subroutine D3dBs_cr_fft3b(nb,A) - #ifdef FFTW3 - do q=1,nq(nb) - indx = 1+(q-1)*nxhy -- call fftw_execute_dft(splans(2,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(2,nb),A(indx),A(indx)) - end do - #else - indx0 = 0 -@@ -566,7 +567,7 @@ subroutine D3dBs_cr_fft3b(nb,A) - * ********************************************************************* - - #ifdef FFTW3 -- call fftw_execute_dft_c2r(splans(3,nb),A,A) -+ call sfftw_execute_dft_c2r(splans(3,nb),A,A) - - #else - -@@ -595,7 +596,7 @@ subroutine D3dBs_cr_fft3b(nb,A) - * ***************************************************** - - #ifdef FFTW3 -- call fftw_execute_dft(splans(11,nb),A,A) -+ call sfftw_execute_dft(splans(11,nb),A,A) - - #else - -@@ -615,7 +616,7 @@ subroutine D3dBs_cr_fft3b(nb,A) - * *** A(ny(nb),nz(nb),kx) <- fft1d^(-1)[A(ky,nz(nb),kx)] *** - * ************************************************************* - #ifdef FFTW3 -- call fftw_execute_dft(splans(12,nb),A,A) -+ call sfftw_execute_dft(splans(12,nb),A,A) - - #else - offset=tid*(2*ny(nb)+15) -@@ -634,7 +635,7 @@ subroutine D3dBs_cr_fft3b(nb,A) - * ********************************************************************* - - #ifdef FFTW3 -- call dfftw_execute_dft_c2r(splans(13,nb),A,A) -+ call sfftw_execute_dft_c2r(splans(13,nb),A,A) - - #else - offset=tid*(2*nx(nb)+15) -@@ -842,7 +843,7 @@ subroutine D3dBs_rc_fft3f(nb,A) - * *** A(kx,ny(nb),nz(nb)) <- fft1d[A(nx(nb),ny(nb),nz(nb))] *** - * **************************************************************** - #ifdef FFTW3 -- call dfftw_execute_dft_r2c(splans(4,nb),A,A) -+ call sfftw_execute_dft_r2c(splans(4,nb),A,A) - - #else - offset=tid*(2*nx(nb)+15) -@@ -860,7 +861,7 @@ subroutine D3dBs_rc_fft3f(nb,A) - #ifdef FFTW3 - do q=1,nq(nb) - indx = 1+(q-1)*nxhy -- call fftw_execute_dft(splans(5,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(5,nb),A(indx),A(indx)) - end do - - #else -@@ -902,7 +903,7 @@ subroutine D3dBs_rc_fft3f(nb,A) - #ifdef FFTW3 - do q=1,nq(nb) - indx = 1+(q-1)*nxhz -- call fftw_execute_dft(splans(6,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(6,nb),A(indx),A(indx)) - end do - - #else -@@ -947,7 +948,7 @@ subroutine D3dBs_rc_fft3f(nb,A) - * *** A(kx,ny(nb),nz(nb)) <- fft1d[A(nx(nb),ny(nb),nz(nb))] *** - * **************************************************************** - #ifdef FFTW3 -- call fftw_execute_dft_r2c(splans(14,nb),A,A) -+ call sfftw_execute_dft_r2c(splans(14,nb),A,A) - #else - offset=tid*(2*nx(nb)+15) - do i=tid+1,nq1(nb),nthr -@@ -964,7 +965,7 @@ subroutine D3dBs_rc_fft3f(nb,A) - * *** A(ky,nz(nb),kx) <- fft1d[A(ny(nb),nz(nb),kx)] *** - * ******************************************** - #ifdef FFTW3 -- call fftw_execute_dft(splans(15,nb),A,A) -+ call sfftw_execute_dft(splans(15,nb),A,A) - - #else - offset=tid*(2*ny(nb)+15) -@@ -982,7 +983,7 @@ subroutine D3dBs_rc_fft3f(nb,A) - * *** A(kz,kx,ky) <- fft1d[A(nz(nb),kx,ky)] *** - * ************************************************ - #ifdef FFTW3 -- call fftw_execute_dft(splans(16,nb),A,A) -+ call sfftw_execute_dft(splans(16,nb),A,A) - #else - offset=tid*(2*nz(nb)+15) - do i=tid+1,nq3(nb),nthr -diff --git a/src/nwpw/nwpwlib/D3dB/D3dBs_pfft.F b/src/nwpw/nwpwlib/D3dB/D3dBs_pfft.F -index f8fbd77bf6..bdbc5c91ba 100644 ---- a/src/nwpw/nwpwlib/D3dB/D3dBs_pfft.F -+++ b/src/nwpw/nwpwlib/D3dB/D3dBs_pfft.F -@@ -97,7 +97,7 @@ subroutine D3dBs_cr_pfft3b(nb,nbb,A) - - #ifdef FFTW3 - indx = i + indx0 -- call fftw_execute_dft(splans(7,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(7,nb),A(indx),A(indx)) - - #else - indx = i + indx0 -@@ -140,7 +140,7 @@ subroutine D3dBs_cr_pfft3b(nb,nbb,A) - - #ifdef FFTW3 - indx = i + indx0 -- call fftw_execute_dft(splans(8,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(8,nb),A(indx),A(indx)) - #else - indx = i + indx0 - indx1 = indx -@@ -166,7 +166,7 @@ subroutine D3dBs_cr_pfft3b(nb,nbb,A) - * ************************************************* - - #ifdef FFTW3 -- call fftw_execute_dft_c2r(splans(3,nb),A,A) -+ call sfftw_execute_dft_c2r(splans(3,nb),A,A) - - #else - call cshift1_sfftb(nx(nb),ny(nb),nq(nb),1,A) -@@ -197,7 +197,7 @@ subroutine D3dBs_cr_pfft3b(nb,nbb,A) - indx = 1 - do q=1,nq3(nb) - if (.not.log_mb(zero_row3(1,nbb)+q-1)) then -- call fftw_execute_dft(splans(17,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(17,nb),A(indx),A(indx)) - end if - indx = indx + nz(nb) - end do -@@ -229,7 +229,7 @@ subroutine D3dBs_cr_pfft3b(nb,nbb,A) - indx = 1 - do q=1,nq2(nb) - if (.not.log_mb(zero_row2(1,nbb)+q-1)) then -- call fftw_execute_dft(splans(18,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(18,nb),A(indx),A(indx)) - end if - indx = indx + ny(nb) - end do -@@ -258,7 +258,7 @@ subroutine D3dBs_cr_pfft3b(nb,nbb,A) - * ********************************************************************* - - #ifdef FFTW3 -- call fftw_execute_dft_c2r(splans(13,nb),A,A) -+ call sfftw_execute_dft_c2r(splans(13,nb),A,A) - #else - - !indx = 1 -@@ -368,7 +368,7 @@ subroutine D3dBs_rc_pfft3f(nb,nbb,A) - - - #ifdef FFTW3 -- call dfftw_execute_dft_r2c(splans(4,nb),A,A) -+ call sfftw_execute_dft_r2c(splans(4,nb),A,A) - - #else - indx = 1 -@@ -396,7 +396,7 @@ subroutine D3dBs_rc_pfft3f(nb,nbb,A) - - #ifdef FFTW3 - indx = i + indx0 -- call fftw_execute_dft(splans(9,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(9,nb),A(indx),A(indx)) - - #else - indx = i + indx0 -@@ -440,7 +440,7 @@ subroutine D3dBs_rc_pfft3f(nb,nbb,A) - - #ifdef FFTW3 - indx = i + indx0 -- call fftw_execute_dft(splans(10,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(10,nb),A(indx),A(indx)) - - #else - indx = i + indx0 -@@ -480,7 +480,7 @@ subroutine D3dBs_rc_pfft3f(nb,nbb,A) - * ******************************************** - - #ifdef FFTW3 -- call fftw_execute_dft_r2c(splans(14,nb),A,A) -+ call sfftw_execute_dft_r2c(splans(14,nb),A,A) - - #else - !indx = 1 -@@ -506,7 +506,7 @@ subroutine D3dBs_rc_pfft3f(nb,nbb,A) - indx = 1 - do q=1,nq2(nb) - if (.not.log_mb(zero_row2(1,nbb)+q-1)) then -- call fftw_execute_dft(splans(19,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(19,nb),A(indx),A(indx)) - end if - indx = indx + ny(nb) - end do -@@ -538,7 +538,7 @@ subroutine D3dBs_rc_pfft3f(nb,nbb,A) - indx = 1 - do q=1,nq3(nb) - if (.not.log_mb(zero_row3(1,nbb)+q-1)) then -- call fftw_execute_dft(splans(20,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(20,nb),A(indx),A(indx)) - end if - indx = indx + nz(nb) - end do -@@ -660,7 +660,7 @@ subroutine D3dBs_cr_mpfft3b(nb,nbb,m,A) - - #ifdef FFTW3 - indx = i+indx0+shift0 -- call fftw_execute_dft(splans(7,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(7,nb),A(indx),A(indx)) - - #else - indx = i + indx0 -@@ -710,7 +710,7 @@ subroutine D3dBs_cr_mpfft3b(nb,nbb,m,A) - - #ifdef FFTW3 - indx = i+indx0+shift0 -- call fftw_execute_dft(splans(8,nb),A(indx),A(indx)) -+ call sfftw_execute_dft(splans(8,nb),A(indx),A(indx)) - #else - indx = i + indx0 - indx1 = indx -@@ -736,7 +736,7 @@ subroutine D3dBs_cr_mpfft3b(nb,nbb,m,A) - * ********************************************************************* - - #ifdef FFTW3 -- call fftw_execute_dft_c2r(splans(3,nb),A(shift0),A(shift0)) -+ call sfftw_execute_dft_c2r(splans(3,nb),A(shift0),A(shift0)) - - #else - call cshift1_sfftb(nx(nb),ny(nb),nq(nb),1,A(shift)) -@@ -774,7 +774,7 @@ subroutine D3dBs_cr_mpfft3b(nb,nbb,m,A) - if (.not.log_mb(zero_row3(1,nbb)+q-1)) then - - #ifdef FFTW3 -- call fftw_execute_dft(splans(17,nb), -+ call sfftw_execute_dft(splans(17,nb), - > A(indx+shift0),A(indx+shift0)) - #else - call scfftb(nz(nb),A(shift0+indx),scpl_mb(tmpz(1,nb))) -@@ -798,7 +798,7 @@ subroutine D3dBs_cr_mpfft3b(nb,nbb,m,A) - if (.not.log_mb(zero_row2(1,nbb)+q-1)) then - - #ifdef FFTW3 -- call fftw_execute_dft(splans(18,nb), -+ call sfftw_execute_dft(splans(18,nb), - > A(indx+shift0),A(indx+shift0)) - #else - call scfftb(ny(nb),A(shift0+indx),scpl_mb(tmpy(1,nb))) -@@ -818,7 +818,7 @@ subroutine D3dBs_cr_mpfft3b(nb,nbb,m,A) - * ********************************************************************* - - #ifdef FFTW3 -- call fftw_execute_dft_c2r(splans(13,nb),A(shift0),A(shift0)) -+ call sfftw_execute_dft_c2r(splans(13,nb),A(shift0),A(shift0)) - - #else - call cshift1_sfftb(nx(nb),nq1(nb),1,1,A(shift)) -@@ -903,7 +903,7 @@ subroutine D3dBs_pfftfx(nbb,A,tmp1,tmp2,request,reqcnt) - call nwpw_timing_start(31) - - #ifdef FFTW3 -- call dfftw_execute_dft_r2c(splans(4,id),A,A) -+ call sfftw_execute_dft_r2c(splans(4,id),A,A) - - #else - -@@ -937,7 +937,7 @@ subroutine D3dBs_pfftfx(nbb,A,tmp1,tmp2,request,reqcnt) - - - #ifdef FFTW3 -- call fftw_execute_dft_r2c(splans(14,id),A,A) -+ call sfftw_execute_dft_r2c(splans(14,id),A,A) - - #else - -@@ -1030,7 +1030,7 @@ subroutine D3dBs_pfftfx0(nbb,tmp1,tmp2,request,reqcnt) - call nwpw_timing_start(31) - - #ifdef FFTW3 -- call fftw_execute_dft_r2c(splans(4,id),tmp1,tmp1) -+ call sfftw_execute_dft_r2c(splans(4,id),tmp1,tmp1) - - #else - -@@ -1059,7 +1059,7 @@ subroutine D3dBs_pfftfx0(nbb,tmp1,tmp2,request,reqcnt) - call nwpw_timing_start(31) - - #ifdef FFTW3 -- call fftw_execute_dft_r2c(splans(14,id),tmp1,tmp1) -+ call sfftw_execute_dft_r2c(splans(14,id),tmp1,tmp1) - - #else - -@@ -1154,7 +1154,7 @@ subroutine D3dBs_pfftfy(nbb,tmp1,tmp2,request,reqcnt) - indx2 = indx2 + 1 - if (.not.log_mb(zero_row2(1,nbb)+indx2-1)) then - indx = i + indx0 -- call fftw_execute_dft(splans(9,1),tmp1(indx),tmp1(indx)) -+ call sfftw_execute_dft(splans(9,1),tmp1(indx),tmp1(indx)) - end if - end do - indx0 = indx0 + nxhy -@@ -1214,7 +1214,7 @@ subroutine D3dBs_pfftfy(nbb,tmp1,tmp2,request,reqcnt) - indx = 1 - do q=1,nq2(id) - if (.not.log_mb(zero_row2(1,nbb)+q-1)) then -- call fftw_execute_dft(splans(19,1),tmp1(indx),tmp1(indx)) -+ call sfftw_execute_dft(splans(19,1),tmp1(indx),tmp1(indx)) - end if - indx = indx + ny(id) - end do -@@ -1333,7 +1333,7 @@ subroutine D3dBs_pfftfz(nbb,tmp1,tmp2,request,reqcnt) - - #ifdef FFTW3 - indx = i + indx0 -- call fftw_execute_dft(splans(10,1),tmp2(indx),tmp2(indx)) -+ call sfftw_execute_dft(splans(10,1),tmp2(indx),tmp2(indx)) - - #else - indx = i + indx0 -@@ -1374,7 +1374,7 @@ subroutine D3dBs_pfftfz(nbb,tmp1,tmp2,request,reqcnt) - indx = 1 - do q=1,nq3(id) - if (.not.log_mb(zero_row3(1,nbb)+q-1)) then -- call fftw_execute_dft(splans(20,1),tmp2(indx),tmp2(indx)) -+ call sfftw_execute_dft(splans(20,1),tmp2(indx),tmp2(indx)) - end if - indx = indx + nz(id) - end do -@@ -1605,7 +1605,7 @@ subroutine D3dBs_pfftbz(nbb,tmp1,tmp2,request,reqcnt) - - #ifdef FFTW3 - indx = i + indx0 -- call fftw_execute_dft(splans(7,1),tmp1(indx),tmp1(indx)) -+ call sfftw_execute_dft(splans(7,1),tmp1(indx),tmp1(indx)) - #else - - indx = i + indx0 -@@ -1652,7 +1652,7 @@ subroutine D3dBs_pfftbz(nbb,tmp1,tmp2,request,reqcnt) - indx = 1 - do q=1,nq3(id) - if (.not.log_mb(zero_row3(1,nbb)+q-1)) then -- call fftw_execute_dft(splans(17,1),tmp1(indx),tmp1(indx)) -+ call sfftw_execute_dft(splans(17,1),tmp1(indx),tmp1(indx)) - end if - indx = indx + nz(id) - end do -@@ -1768,7 +1768,7 @@ subroutine D3dBs_pfftby(nbb,tmp1,tmp2,request,reqcnt) - - #ifdef FFTW3 - indx = i + indx0 -- call fftw_execute_dft(splans(8,id),tmp2(indx),tmp2(indx)) -+ call sfftw_execute_dft(splans(8,id),tmp2(indx),tmp2(indx)) - - #else - indx = i + indx0 -@@ -1811,7 +1811,7 @@ subroutine D3dBs_pfftby(nbb,tmp1,tmp2,request,reqcnt) - indx = 1 - do q=1,nq2(id) - if (.not.log_mb(zero_row2(1,nbb)+q-1)) then -- call fftw_execute_dft(splans(18,id),tmp2(indx),tmp2(indx)) -+ call sfftw_execute_dft(splans(18,id),tmp2(indx),tmp2(indx)) - end if - indx = indx + ny(id) - end do -@@ -1912,7 +1912,7 @@ subroutine D3dBs_pfftbx(nbb,tmp1,tmp2,request,reqcnt) - - - #ifdef FFTW3 -- call fftw_execute_dft_c2r(splans(3,id),tmp2,tmp2) -+ call sfftw_execute_dft_c2r(splans(3,id),tmp2,tmp2) - - #else - #ifdef NUSE_OPENMP -@@ -1956,7 +1956,7 @@ subroutine D3dBs_pfftbx(nbb,tmp1,tmp2,request,reqcnt) - * ********************************************************************* - - #ifdef FFTW3 -- call fftw_execute_dft_c2r(splans(13,id),tmp1,tmp1) -+ call sfftw_execute_dft_c2r(splans(13,id),tmp1,tmp1) - - #else - indx = 1 -diff --git a/src/nwpw/nwpwlib/D3dB/GNUmakefile b/src/nwpw/nwpwlib/D3dB/GNUmakefile -index df7b8b7068..ec1fa61c42 100644 ---- a/src/nwpw/nwpwlib/D3dB/GNUmakefile -+++ b/src/nwpw/nwpwlib/D3dB/GNUmakefile -@@ -52,5 +52,7 @@ endif - - ifeq ($(USE_FFTW3),y) - LIB_DEFINES += -DFFTW3 -- LIB_INCLUDES += -I$(FFTW3_INCLUDE) -+ ifdef FFTW3_INCLUDE -+ LIB_INCLUDES += -I$(FFTW3_INCLUDE) -+ endif - endif -From 376f86f96eb982e83f10514e9dcd994564f973b4 Mon Sep 17 00:00:00 2001 -From: Eric Bylaska -Date: Thu, 8 Jun 2023 15:41:50 -0700 -Subject: [PATCH] Fixed singlet precision fftw3 linking. In general, fftw3 - should not be used by most users, but it is included for perfmance testing - and cross checking...EJB - ---- - src/config/makefile.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/config/makefile.h b/src/config/makefile.h -index 1f2ff5c472..8b2b667bd9 100644 ---- a/src/config/makefile.h -+++ b/src/config/makefile.h -@@ -3622,7 +3622,7 @@ endif - # FFTW3 library inclusion - ifdef USE_FFTW3 - ifndef LIBFFTW3 -- LIBFFTW3 = -lfftw3 -+ LIBFFTW3 = -lfftw3 -lfftw3f - endif - ifdef FFTW3_LIB - CORE_LIBS += -L$(FFTW3_LIB) -From c89fc9d1eca6689bce12564a63fdea95d962a123 Mon Sep 17 00:00:00 2001 -From: edoapra -Date: Thu, 8 Jun 2023 17:37:13 -0700 -Subject: [PATCH] fix for including system header fftw3.f - ---- - src/nwpw/nwpwlib/D3dB/D3dB-new.F | 3 +-- - src/nwpw/nwpwlib/D3dB/D3dBs-new.F | 3 +-- - 2 files changed, 2 insertions(+), 4 deletions(-) - -diff --git a/src/nwpw/nwpwlib/D3dB/D3dB-new.F b/src/nwpw/nwpwlib/D3dB/D3dB-new.F -index 2159707831..6249f91710 100644 ---- a/src/nwpw/nwpwlib/D3dB/D3dB-new.F -+++ b/src/nwpw/nwpwlib/D3dB/D3dB-new.F -@@ -1183,8 +1183,7 @@ subroutine D3dB_fft_init(nb) - common / D3dB_fft / tmpx,tmpy,tmpz - - #ifdef FFTW3 --!#include "fftw3.fh" --#include "fftw3.f" -+#include - integer Atest(2),nxh,nxhz,nxhy - #endif - -diff --git a/src/nwpw/nwpwlib/D3dB/D3dBs-new.F b/src/nwpw/nwpwlib/D3dB/D3dBs-new.F -index 8ddfddad34..4b71e4cf29 100644 ---- a/src/nwpw/nwpwlib/D3dB/D3dBs-new.F -+++ b/src/nwpw/nwpwlib/D3dB/D3dBs-new.F -@@ -195,8 +195,7 @@ subroutine D3dBs_fft_init(nb) - common / D3dBs_fft / tmpx,tmpy,tmpz - - #ifdef FFTW3 --!#include "fftw3.fh" --#include "fftw3.f" -+#include - integer Atest(2),nxh,nxhz,nxhy - #endif - diff --git a/repo/packages/nwchem/fj.patch b/repo/packages/nwchem/fj.patch deleted file mode 100644 index 376845b2..00000000 --- a/repo/packages/nwchem/fj.patch +++ /dev/null @@ -1,147 +0,0 @@ -diff -u -r nwchem-7.0.2/src/basis/bas_input.F nwchem-7.0.2-patched/src/basis/bas_input.F ---- nwchem-7.0.2/src/basis/bas_input.F 2020-10-13 13:16:25.000000000 +0900 -+++ nwchem-7.0.2-patched/src/basis/bas_input.F 2022-02-08 14:10:28.000000000 +0900 -@@ -1321,7 +1321,9 @@ - endif - libname = compiled_name - does_it_exist = .false. -+#ifndef FUJITSU - inquire(file=libname,exist=does_it_exist) -+#endif - c - c check if it is a directory - c -Only in nwchem-7.0.2-patched/src/basis: bas_input.F.orig -diff -u -r nwchem-7.0.2/src/config/makefile.h nwchem-7.0.2-patched/src/config/makefile.h ---- nwchem-7.0.2/src/config/makefile.h 2020-10-13 13:16:30.000000000 +0900 -+++ nwchem-7.0.2-patched/src/config/makefile.h 2022-02-08 14:10:28.000000000 +0900 -@@ -1867,6 +1867,12 @@ - else - FOPTIONS += -s integer64 - endif -+ else ifeq ($(_FC),frt) -+ ifdef USE_I4FLAGS -+ FOPTIONS += -CcdLL8 -+ else -+ FOPTIONS += -CcdLL8 -CcdII8 -+ endif - else - ifdef USE_I4FLAGS - FOPTIONS += -i4 -@@ -2319,6 +2325,13 @@ - endif - endif - -+ ifeq ($(_CC),gcc) -+ COPTIONS += -O3 -+ ifdef USE_OPENMP -+ COPTIONS += -Kopenmp -+ endif -+ endif -+ - ifeq ($(_FC),gfortran) - ifdef USE_GPROF - FOPTIONS += -pg -@@ -2353,6 +2366,29 @@ - endif - endif # end of gfortran - -+ # A64fx -+ ifeq ($(FC),frt) -+ -+ FOPTIONS += -DFUJITSU -+ FOPTIONS += -fs -+ -+ ifdef USE_SHARED -+ FOPTIONS+= -+ endif -+ -+ DEFINES += -+ LINK.f = $(FC) $(LDFLAGS) -+ FOPTIMIZE = -O3 -+ -+ ifeq ($(V),1) -+ $(info FUJITSU FOPTIMIZE = ${FOPTIMIZE}) -+ endif -+ -+ FDEBUG += -g -O -+ FOPTIMIZE += -+ -+ endif -+ - ifeq ($(FC),armflang) - - ifdef USE_SHARED -Only in nwchem-7.0.2/src/config: makefile.h.orig -diff -u -r nwchem-7.0.2/src/inp/inp.F nwchem-7.0.2-patched/src/inp/inp.F ---- nwchem-7.0.2/src/inp/inp.F 2020-10-13 13:16:26.000000000 +0900 -+++ nwchem-7.0.2-patched/src/inp/inp.F 2022-02-08 14:21:11.000000000 +0900 -@@ -15,7 +15,7 @@ - data errmsg /' '/ - data input_line /0/ - data xblnk /' '/ --#if defined(SGITFP) || defined(SGI_N32) || defined(CRAY) || defined(HPUX) || defined(WIN32) || defined(PSCALE) || defined(__FLANG) || ( __GNUC__ >= 4) -+#if defined(SGITFP) || defined(SGI_N32) || defined(CRAY) || defined(HPUX) || defined(WIN32) || defined(PSCALE) || defined(__FLANG) || ( __GNUC__ >= 4) || defined(FUJITSU) - data xtab /' '/ ! Tab ... no backslash necessary - #elif (defined(LINUX) || defined(MACX)) && !defined(PGLINUX) && !defined(XLFLINUX) &&!( __GNUC__ >= 4) - data xtab /9/ ! Tab ... g77 has trouble with escape sequence -diff -u -r nwchem-7.0.2/src/nwdft/rt_tddft/rtutils/rt_tddft_spatial_potential.F nwchem-7.0.2-patched/src/nwdft/rt_tddft/rtutils/rt_tddft_spatial_potential.F ---- nwchem-7.0.2/src/nwdft/rt_tddft/rtutils/rt_tddft_spatial_potential.F 2020-10-13 13:16:26.000000000 +0900 -+++ nwchem-7.0.2-patched/src/nwdft/rt_tddft/rtutils/rt_tddft_spatial_potential.F 2022-02-09 11:33:37.000000000 +0900 -@@ -854,7 +854,8 @@ - integer, intent(in) :: rtdb - C type(rt_params_t), intent(in) :: params - integer, intent(in) :: nao, nq -- double precision, intent(out) :: pot_ao(nao,nao), ovl_ao(nao,nao) -+ double precision, intent(inout) :: pot_ao(nao,nao) -+ double precision, intent(inout) :: ovl_ao(nao,nao) - - character(len=*), parameter :: pname = - $ "rt_tddft_spatial_potential_print: " -diff -u -r nwchem-7.0.2/src/nwpw/nwpwlib/nwpwxc/nwpwxc_vdw3a.F nwchem-7.0.2-patched/src/nwpw/nwpwlib/nwpwxc/nwpwxc_vdw3a.F ---- nwchem-7.0.2/src/nwpw/nwpwlib/nwpwxc/nwpwxc_vdw3a.F 2020-10-13 13:24:47.000000000 +0900 -+++ nwchem-7.0.2-patched/src/nwpw/nwpwlib/nwpwxc/nwpwxc_vdw3a.F 2022-02-09 18:51:07.000000000 +0900 -@@ -26,6 +26,7 @@ - C For the GNU General Public License, see - - subroutine nwpwxc_vdw3_dftd3(options,n,iz,xyz,lat,eout,g,g_lat) -+ use, intrinsic :: ieee_arithmetic - implicit none - character*(*) options - c number of atoms -@@ -826,7 +827,7 @@ - if (util_isnan(dum)) call - c nwpwxc_stoprun('internal NaN-error') - #else -- if (ISNAN(dum)) call nwpwxc_stoprun('internal NaN-error') -+ if (ieee_is_nan(dum)) call nwpwxc_stoprun('internal NaN-error') - #endif - ! if (dum/=dum) call nwpwxc_stoprun('internal NaN-error') - if(dum.gt.1.d-8) then -diff -u -r nwchem-7.0.2/src/selci/conf.F nwchem-7.0.2-patched/src/selci/conf.F ---- nwchem-7.0.2/src/selci/conf.F 2020-10-13 13:16:27.000000000 +0900 -+++ nwchem-7.0.2-patched/src/selci/conf.F 2022-02-09 16:09:46.000000000 +0900 -@@ -10,7 +10,6 @@ - * - * $Id$ - * --*include "implicit.fh" - #include "cconf.fh" - #include "mptr.fh" - #include "cselcifiles.fh" -diff -u -r nwchem-7.0.2/src/tools/guess-mpidefs nwchem-7.0.2-patched/src/tools/guess-mpidefs ---- nwchem-7.0.2/src/tools/guess-mpidefs 2020-10-13 13:16:27.000000000 +0900 -+++ nwchem-7.0.2-patched/src/tools/guess-mpidefs 2022-02-08 14:21:52.000000000 +0900 -@@ -1,10 +1,10 @@ - #!/usr/bin/env bash - # - declare -a LIST_MPIFWRAP --LIST_MPIFWRAP=( 'mpif90' 'mpiifort' 'mpifc' 'mpixlf_r' 'mpixlf' 'mpif77' ) -+LIST_MPIFWRAP=( 'mpif90' 'mpiifort' 'mpifc' 'mpixlf_r' 'mpixlf' 'mpif77' 'mpifrt') - export LIST_MPIFWRAP - declare -a LIST_MPICWRAP --LIST_MPICWRAP=( 'mpicc' 'mpixlc_r' 'mpixlc' 'mpigcc' 'mpiicc' ) -+LIST_MPICWRAP=( 'mpicc' 'mpixlc_r' 'mpixlc' 'mpigcc' 'mpiicc' 'mpifcc') - export LIST_MPICWRAP - function usage() - { diff --git a/repo/packages/nwchem/package.py b/repo/packages/nwchem/package.py deleted file mode 100644 index cfa77394..00000000 --- a/repo/packages/nwchem/package.py +++ /dev/null @@ -1,167 +0,0 @@ -# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -# PAWSEY MODIFICATIONS -# Added `-lfftw3f` to line 118. -import os -import sys - -from spack.package import * - - -class Nwchem(Package): - """High-performance computational chemistry software""" - - homepage = "https://nwchemgit.github.io" - url = "https://github.com/nwchemgit/nwchem/releases/download/v7.2.0-release/nwchem-7.2.0-release.revision-d0d141fd-srconly.2023-03-10.tar.bz2" - - tags = ["ecp", "ecp-apps"] - - version( - "7.2.0", - sha256="28ea70947e77886337c84e6fae3bdf88f25f0acfdeaf95e722615779c19f7a7e", - url="https://github.com/nwchemgit/nwchem/releases/download/v7.2.0-release/nwchem-7.2.0-release.revision-d0d141fd-srconly.2023-03-10.tar.bz2", - ) - version( - "7.0.2", - sha256="9bf913b811b97c8ed51bc5a02bf1c8e18456d0719c0a82b2e71223a596d945a7", - url="https://github.com/nwchemgit/nwchem/releases/download/v7.0.2-release/nwchem-7.0.2-release.revision-b9985dfa-srconly.2020-10-12.tar.bz2", - ) - - variant("openmp", default=False, description="Enables OpenMP support") - variant("mpipr", default=False, description="Enables ARMCI with progress rank") - variant("fftw3", default=False, description="Link against the FFTW library") - - # This patch is for the modification of the build system (e.g. compiler flags) and - # Fortran syntax to enable the compilation with Fujitsu compilers. The modification - # will be merged to the next release of NWChem (see https://github.com/nwchemgit/nwchem/issues/347 - # for more detail. - patch("fj.patch", when="@7.0.2 %fj") - # This patch is for linking the FFTW library in NWChem. - # It applys only to the 7.2.0 source code. - # will be merged to the next release of NWChem (see https://github.com/nwchemgit/nwchem/issues/792 - # for more detail. - # This patch is the combination of the following commits - # https://github.com/nwchemgit/nwchem/commit/b4ec4ade1af434bc80470d6874aebf6fdcd12489 - # https://github.com/nwchemgit/nwchem/commit/376f86f96eb982e83f10514e9dcd994564f973b4 - # https://github.com/nwchemgit/nwchem/commit/c89fc9d1eca6689bce12564a63fdea95d962a123 - # Prior versions of NWChem, including 7.0.2, were not able to link with FFTW - patch("fftw_splans.patch", when="@7.2.0") - - depends_on("blas") - depends_on("lapack") - depends_on("mpi") - depends_on("scalapack") - depends_on("fftw-api") - depends_on("python@3", type=("build", "link", "run")) - - def install(self, spec, prefix): - scalapack = spec["scalapack"].libs - lapack = spec["lapack"].libs - blas = spec["blas"].libs - fftw = spec["fftw-api"].libs - # see https://nwchemgit.github.io/Compiling-NWChem.html - args = [] - args.extend( - [ - "NWCHEM_TOP=%s" % self.stage.source_path, - # NWCHEM is picky about FC and CC. They should NOT be full path. - # see https://nwchemgit.github.io/Special_AWCforum/sp/id7524 - "CC=%s" % os.path.basename(spack_cc), - "FC=%s" % os.path.basename(spack_fc), - "USE_MPI=y", - "PYTHONVERSION=%s" % spec["python"].version.up_to(2), - "BLASOPT=%s" % ((lapack + blas).ld_flags), - "LAPACK_LIB=%s" % lapack.ld_flags, - "SCALAPACK_LIB=%s" % scalapack.ld_flags, - "USE_NOIO=Y", # skip I/O algorithms - "MRCC_METHODS=y", # TCE extra module - "IPCCSD=y", # TCE extra module - "EACCSD=y", # TCE extra module - "V=1", # verbose build - ] - ) - if self.spec.satisfies("@7.2.0:"): - args.extend(["NWCHEM_MODULES=all python gwmol"]) - args.extend(["USE_HWOPT=n"]) - else: - args.extend(["NWCHEM_MODULES=all python"]) - # archspec flags are injected through the compiler wrapper - filter_file("(-mtune=native|-mcpu=native|-xHost)", "", "src/config/makefile.h") - - # TODO: query if blas/lapack/scalapack uses 64bit Ints - # A flag to distinguish between 32bit and 64bit integers in linear - # algebra (Blas, Lapack, Scalapack) - use_32_bit_lin_alg = True - - if use_32_bit_lin_alg: - args.extend(["USE_64TO32=y", "BLAS_SIZE=4", "SCALAPACK_SIZE=4"]) - else: - args.extend(["BLAS_SIZE=8", "SCALAPACK_SIZE=8"]) - - if sys.platform == "darwin": - target = "MACX64" - args.extend(["CFLAGS_FORGA=-DMPICH_NO_ATTR_TYPE_TAGS"]) - else: - target = "LINUX64" - - args.extend(["NWCHEM_TARGET=%s" % target]) - - if "+openmp" in spec: - args.extend(["USE_OPENMP=y"]) - - if "+mpipr" in spec: - args.extend(["ARMCI_NETWORK=MPI-PR"]) - - if "+fftw3" in spec: - args.extend(["USE_FFTW3=y"]) - args.extend(["LIBFFTW3=%s -lfftw3f" % fftw.ld_flags]) - args.extend(["FFTW3_INCLUDE={0}".format(spec["fftw-api"].prefix.include)]) - - with working_dir("src"): - make("nwchem_config", *args) - if use_32_bit_lin_alg: - make("64_to_32", *args) - make(*args) - - # need to install by hand. Follow Ubuntu: - # https://packages.ubuntu.com/trusty/all/nwchem-data/filelist - # https://packages.ubuntu.com/trusty/amd64/nwchem/filelist - share_path = join_path(prefix, "share", "nwchem") - mkdirp(prefix.bin) - - install_tree("data", share_path) - install_tree(join_path("basis", "libraries"), join_path(share_path, "libraries")) - install_tree(join_path("basis", "libraries.bse"), join_path(share_path, "libraries")) - install_tree(join_path("nwpw", "libraryps"), join_path(share_path, "libraryps")) - - b_path = join_path(self.stage.source_path, "bin", target, "nwchem") - chmod = which("chmod") - chmod("+x", b_path) - install(b_path, prefix.bin) - - # Finally, make user's life easier by creating a .nwchemrc file - # to point to the required data files. - nwchemrc = """\ - nwchem_basis_library {data}/libraries/ - nwchem_nwpw_library {data}/libraryps/ - ffield amber - amber_1 {data}/amber_s/ - amber_2 {data}/amber_q/ - amber_3 {data}/amber_x/ - amber_4 {data}/amber_u/ - spce {data}/solvents/spce.rst - charmm_s {data}/charmm_s/ - charmm_x {data}/charmm_x/ -""".format( - data=share_path - ) - with open(".nwchemrc", "w") as f: - f.write(nwchemrc) - install(".nwchemrc", share_path) - - def setup_run_environment(self, env): - env.set("NWCHEM_BASIS_LIBRARY", join_path(self.prefix, "share/nwchem/libraries/")) - env.set("NWCHEM_NWPW_LIBRARY", join_path(self.prefix, "share/nwchem/libraryps/")) diff --git a/repo/packages/plumed/package.py b/repo/packages/plumed/package.py deleted file mode 100644 index 30f126d0..00000000 --- a/repo/packages/plumed/package.py +++ /dev/null @@ -1,299 +0,0 @@ -# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# ======================================================================= -# PAWSEY ADDITIONS -# ======================================================================= -# This is a version of the recipe coming from the later 0.21.0-dev Spack -# version. It will allow us to have the latest versions. -# Also, we add the 2.8.3, 2.9 versions - -import collections -import os.path - -from spack.package import * - - -class Plumed(AutotoolsPackage): - """PLUMED is an open source library for free energy calculations in - molecular systems which works together with some of the most popular - molecular dynamics engines. - - Free energy calculations can be performed as a function of many order - parameters with a particular focus on biological problems, using state - of the art methods such as metadynamics, umbrella sampling and - Jarzynski-equation based steered MD. - - The software, written in C++, can be easily interfaced with both fortran - and C/C++ codes. - """ - - homepage = "https://www.plumed.org/" - url = "https://github.com/plumed/plumed2/archive/v2.7.4.tar.gz" - git = "https://github.com/plumed/plumed2.git" - # maintainers("marcodelapierre") - - version("master", branch="master") - version("2.9.0", sha256="612d2387416b5f82dd8545709921440370e144fd46cef633654cf0ee43bac5f8") - version("2.8.3", sha256="e98da486e252cdf290b0b5b2f3f021409ea0d2d775ab609a6ad68fc1ab143a3b") - version("2.8.2", sha256="a2064bacba1dde36b05aaf351ba4b7e6d30a165b332b0a83b7a6db04b477be9f") - version("2.8.1", sha256="f56bc9266c8a47241385c595717c2734a9b67148a7f4122b808bc0733710173e") - version("2.8.0", sha256="8357eca6f280125037ad4e7c427f96f2af2f60ddfedce1a2e36e1e1cc3bff32b") - - version("2.7.6", sha256="9ca7b1e84bf2343a09a5b604222dd04aa0fc8b62a7cb82d1d68b795b6b189c06") - version("2.7.5", sha256="39cb01108706df7ef71c7c315ddfc4306137f62ac72222b8582ab892221f7972") - version("2.7.4", sha256="6f5dc16a753c71ed719f17f9cbb61642ab8e716fb7f77e22960dfa145c3b8211") - version("2.7.3", sha256="aa1f6200c2ed351e40ce4391a9590f171532474b30f384feddfab10e36d7e08e") - version("2.7.2", sha256="c9a31e68d6440828cf186ca43c9e11a5e5c7ad1c96b2b66ed5a5a141fc954373") - version("2.7.1", sha256="cb8b5735d8dd61980fa6441f3dde3f33544240ae4177da0f529fb5abb355cd4a") - version("2.7.0", sha256="14450ea566c25ac9bf71fd77bb9c0c95e9038462b5739c73a515be82e2011cd6") - - version("2.6.6", sha256="43a7bb410280141c020363671c685a759d4497b3db3eb3c04899264b51a26859") - version("2.6.5", sha256="3b72587ba6fe72def46bcc7d917974123279879de7f8335acf542bba57865eed") - version("2.6.4", sha256="53e49c0db6cc769d238834bea884e856f4e7bb8f71c9929e5584bd977113f03b") - version("2.6.3", sha256="d05b9e4a4c1329fc932d5bdd04f20419be230f98159bdc012a91716461ab4a2f") - version("2.6.2", sha256="bbc2ef0cb08d404513b8b737c72333b6656389e15effd6a0f9ace2a5758c9a4a") - version("2.6.1", sha256="c1b3c397b2d971140aa240dde50e48a04ce78e3dedb02b6dca80fa53f8026e4e") - version("2.6.0", sha256="3d57ae460607a49547ef38a52c4ac93493a3966857c352280a9c05f5dcdb1820") - - version("2.5.7", sha256="aa10d2879c3edeaef9d5a530fe8b05f67ecfbec2e9423e0f95701d0bc54826c7") - version("2.5.6", sha256="1bc29b0274196fb553cdf7ba8ecb7a93a91d60a920d99863edbcd536d618ce8c") - version("2.5.5", sha256="70faa9ff1938e286dc388cb793b39840953e5646855b684f48df1bc864b737e8") - version("2.5.4", sha256="a1647e598191f261e75d06351e607475d395af481315052a4c28563ac9989a7f") - version("2.5.3", sha256="543288be667dc4201fc461ecd2dd4878ddfbeac682d0c021c99ea8e501c7c9dc") - version("2.5.2", sha256="85d10cc46e2e37c7719cf51c0931278f56c2c8f8a9d86188b2bf97c2535a2ab4") - version("2.5.1", sha256="de309980dcfd6f6e0e70e138856f4bd9eb4d8a513906a5e6389f18a5af7f2eba") - version("2.5.0", sha256="53e08187ec9f8af2326fa84407e34644a7c51d2af93034309fb70675eee5e4f7") - version("2.4.6", sha256="c22ad19f5cd36ce9fe4ba0b53158fc2a3d985c48fc04606e3f3b3e835b994cb3") - - version("2.4.4", sha256="1e5c24109314481fad404da97d61c7339b219e27e120c9c80bacc79c9f6a51a8") - version("2.4.2", sha256="528ce57f1f5330480bcd403140166a4580efd2acaea39c85dfeca5e2cd649321") - version("2.4.1", sha256="f00410ebdd739c2ddf55fcd714ff4bd88a1029e02d2fc9cea0b5fca34e0fc4eb") - - version("2.3.5", sha256="a6a66ca4582c1aecc6138c96be015e13cd06a718e8446b2f13e610fe34602e4f") - version("2.3.3", sha256="ac058ff529f207d5b4169fb5a87bdb3c77307dfef1ac543ad8b6c74c5de7fc91") - version("2.3.0", sha256="b1c8a54a313a0569e27e36420770074f35406453f73de70e55c424652abeddf1") - - version("2.2.4", sha256="d7a1dba34a7fe03f23e8d39ab6e15b230c4851373fdceb3602e2de26ea53ce37") - version("2.2.3", sha256="2db19c5f6a2918833941d0bf47b5431d0865529d786df797ccc966d763ed7b0c") - - # Variants. PLUMED by default builds a number of optional modules. - # The ones listed here are not built by default for various reasons, - # such as stability, lack of testing, or lack of demand. - # - # From 'configure --help' @2.3: - # all/none/reset or : separated list such as - # +crystallization:-bias default: reset - # - # Optional modules can be provided in two ways, via the `optional_modules` variant: - # 1. Use a reference set of optional modules via `optional_modules` (recommended). - # Allowed values are: `all`[default], `reset`. - # 2. Pick any combination of specific optional modules (advanced). - # Only the requested optional modules will be activated. - # See list in variable `single_optional_modules` below. - # This list comes from the Plumed manual, eg for 2.8: - # https://www.plumed.org/doc-v2.8/user-doc/html/mymodules.html - # These are implemented using multi-valued variants (`disjoint_sets`), - # and the `conditional` option to handle version conflicts. - single_optional_modules = ( - conditional("adjmat", when="@2.3:"), - "analysis", - conditional("annfunc", when="@2.6:"), - "bias", - "cltools", - "colvar", - "crystallization", - conditional("dimred", when="@2.5:"), - conditional("drr", when="@2.4:"), - conditional("eds", when="@2.4:"), - conditional("fisst", when="@2.7:"), - "function", - conditional("funnel", when="@2.7:"), - "generic", - conditional("imd", when="@:2.2.99"), - conditional("isdb", when="@2.4:"), - conditional("logmfd", when="@2.5:"), - "manyrestraints", - "mapping", - conditional("maze", when="@2.6:"), - "molfile", - "multicolvar", - conditional("opes", when="@2.7:"), - conditional("pamm", when="@2.5: optional_modules=adjmat"), - conditional("piv", when="@2.5:"), - conditional("reference", when="@:2.2.99"), - conditional("s2cm", when="@2.8:"), - conditional("sasa", when="@2.8:"), - "secondarystructure", - "setup", - "vatom", - conditional("ves", when="@2.4:"), - conditional("vesselbase", when="@:2.2.99"), - conditional("xdrfile", when="@2.8:"), - ) - - variant( - "optional_modules", - values=disjoint_sets(("all",), ("reset",), single_optional_modules) - .prohibit_empty_set() - .with_default("all"), - description="Activates optional modules: all, reset, or custom list (advanced)", - ) - - variant("shared", default=True, description="Builds shared libraries") - variant("mpi", default=True, description="Activates MPI support") - variant("gsl", default=True, description="Activates GSL support") - variant( - "arrayfire", - default="none", - values=("none", "cpu", "cuda", "opencl"), - description="Activates FireArray support", - ) - - # Dependencies. LAPACK and BLAS are recommended but not essential. - depends_on("zlib") - depends_on("blas") - depends_on("lapack") - # For libmatheval support through the 'function' module - # which is enabled by default (or when optional_modules=all) - depends_on("libmatheval", when="@:2.4") - depends_on("arrayfire", when="arrayfire=cpu") - depends_on("arrayfire+cuda", when="arrayfire=cuda") - depends_on("arrayfire+opencl", when="arrayfire=opencl") - - depends_on("mpi", when="+mpi") - depends_on("gsl", when="+gsl") - - depends_on("autoconf", type="build") - depends_on("automake", type="build") - depends_on("libtool", type="build") - depends_on("m4", type="build") - depends_on("py-cython", type="build", when="@2.5:") - - force_autoreconf = True - - parallel = False - - def apply_patch(self, other): - # The name of MD engines differ slightly from the ones used in Spack - format_strings = collections.defaultdict(lambda: "{0.name}-{0.version}") - format_strings["espresso"] = "q{0.name}-{0.version}" - format_strings["amber"] = "{0.name}{0.version}" - - get_md = lambda x: format_strings[x.name].format(x) - - # Get available patches - plumed_patch = Executable(os.path.join(self.spec.prefix.bin, "plumed-patch")) - - out = plumed_patch("-q", "-l", output=str) - available = out.split(":")[-1].split() - - # Check that `other` is among the patchable applications - if get_md(other) not in available: - msg = "{0.name}@{0.version} is not among the MD engine" - msg += " that can be patched by {1.name}@{1.version}.\n" - msg += "Supported engines are:\n" - for x in available: - msg += x + "\n" - raise RuntimeError(msg.format(other, self.spec)) - - # Call plumed-patch to patch executables - target = format_strings[other.name].format(other) - plumed_patch("-p", "-e", target, "-f") - - def setup_dependent_package(self, module, dependent_spec): - # Make plumed visible from dependent packages - module.plumed = dependent_spec["plumed"].command - - @property - def plumed_inc(self): - return os.path.join(self.prefix.lib, "plumed", "src", "lib", "Plumed.inc") - - @run_before("autoreconf") - def filter_gslcblas(self): - # This part is needed to avoid linking with gsl cblas - # interface which will mask the cblas interface - # provided by optimized libraries due to linking order - filter_file("-lgslcblas", "", "configure.ac") - - def patch(self): - # Ensure Spack's wrappers are used to compile the Python interface - env = ( - 'CXX={0} LDSHARED="{0} -pthread -shared" ' - 'LDCXXSHARED="{0} -pthread -shared"'.format(spack_cxx) - ) - filter_file( - "plumed_program_name=plumed", - "{0} plumed_program_name=plumed".format(env), - "src/lib/Makefile", - "python/Makefile", - ) - - def configure_args(self): - spec = self.spec - - # From plumed docs : - # Also consider that this is different with respect to what some other - # configure script does in that variables such as MPICXX are - # completely ignored here. In case you work on a machine where CXX is - # set to a serial compiler and MPICXX to a MPI compiler, to compile - # with MPI you should use: - # - # > ./configure CXX="$MPICXX" - - # The configure.ac script may detect the wrong linker for - # LD_RO which causes issues at link time. Here we work around - # the issue saying we have no LD_RO executable. - configure_opts = ["--disable-ld-r"] - - # If using MPI then ensure the correct compiler wrapper is used. - if "+mpi" in spec: - configure_opts.extend(["--enable-mpi", "CXX={0}".format(spec["mpi"].mpicxx)]) - - # If the MPI dependency is provided by the intel-mpi package then - # the following additional argument is required to allow it to - # build. - if "intel-mpi" in spec: - configure_opts.extend(["STATIC_LIBS=-mt_mpi"]) - - extra_libs = [] - # Set flags to help find gsl - if "+gsl" in spec: - gsl_libs = spec["gsl"].libs - blas_libs = spec["blas"].libs - extra_libs.append((gsl_libs + blas_libs).ld_flags) - # Set flags to help with ArrayFire - if "arrayfire=none" not in spec: - libaf = "arrayfire:{0}".format(spec.variants["arrayfire"].value) - extra_libs.append(spec[libaf].libs.search_flags) - - if extra_libs: - configure_opts.append("LDFLAGS={0}".format(" ".join(extra_libs))) - - # Additional arguments - configure_opts.extend( - [ - "--enable-shared={0}".format("yes" if "+shared" in spec else "no"), - "--enable-gsl={0}".format("yes" if "+gsl" in spec else "no"), - "--enable-af_cpu={0}".format("yes" if "arrayfire=cpu" in spec else "no"), - "--enable-af_cuda={0}".format("yes" if "arrayfire=cuda" in spec else "no"), - "--enable-af_ocl={0}".format("yes" if "arrayfire=ocl" in spec else "no"), - ] - ) - - # Construct list of optional modules - optional_modules = self.spec.variants["optional_modules"].value - # Predefined set of modules - if "all" in optional_modules: - selected_modules = "all" - elif "reset" in optional_modules: - selected_modules = "reset" - # Custom set of modules - else: - selected_modules = "none" - for mod in optional_modules: - selected_modules += ":+{0}".format(mod) - configure_opts.append("--enable-modules={0}".format(selected_modules)) - - return configure_opts diff --git a/repo/packages/py-botocore/package.py b/repo/packages/py-botocore/package.py deleted file mode 100644 index fa0a47bd..00000000 --- a/repo/packages/py-botocore/package.py +++ /dev/null @@ -1,49 +0,0 @@ -#updating py-docutils version -#- depends_on("py-docutils@0.10:0.15", type=("build", "run"), when="@:1.17") -#+ depends_on("py-docutils@0.10:0.19", type=("build", "run"), when="@:1.17") - -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -from spack.package import * - - -class PyBotocore(PythonPackage): - """Low-level, data-driven core of boto 3.""" - - homepage = "https://github.com/boto/botocore" - pypi = "botocore/botocore-1.13.44.tar.gz" - - version("1.21.12", sha256="8710d03b9de3e3d94ed410f3e83809ca02050b091100d68c22ff7bf986f29fb6") - version("1.20.27", sha256="4477803f07649f4d80b17d054820e7a09bb2cb0792d0decc2812108bc3759c4a") - version("1.19.52", sha256="dc5ec23deadbe9327d3c81d03fddf80805c549059baabd80dea605941fe6a221") - version("1.13.44", sha256="a4409008c32a3305b9c469c5cc92edb5b79d6fcbf6f56fe126886b545f0a4f3f") - version("1.13.38", sha256="15766a367f39dba9de3c6296aaa7da31030f08a0117fd12685e7df682d8acee2") - version("1.12.169", sha256="25b44c3253b5ed1c9093efb57ffca440c5099a2d62fa793e8b6c52e72f54b01e") - - depends_on("python@2.6:", when="@1.12:1.13", type=("build", "run")) - depends_on("python@2.7:", when="@1.19", type=("build", "run")) - depends_on("python@2.7:2.8,3.6:", when="@1.20", type=("build", "run")) - depends_on("python@3.6:", when="@1.21:", type=("build", "run")) - - depends_on("py-setuptools", type="build") - depends_on("py-jmespath@0.7.1:0", type=("build", "run")) - depends_on("py-docutils@0.10:0.19", type=("build", "run"), when="@:1.17") - depends_on("py-ordereddict@1.1", type=("build", "run"), when="^python@2.6.0:2.6") - depends_on("py-simplejson@3.3.0", type=("build", "run"), when="^python@2.6.0:2.6") - depends_on("py-python-dateutil@2.1:2", type=("build", "run")) - depends_on("py-python-dateutil@2.1:2.6", type=("build", "run"), when="^python@2.6.0:2.6") - depends_on("py-urllib3@1.20:1.25", type=("build", "run"), when="@:1.14.11") - depends_on("py-urllib3@1.20:1.23", type=("build", "run"), when="@:1.13 ^python@2.6.0:2.6") - depends_on("py-urllib3@1.20:1.22", type=("build", "run"), when="@:1.13 ^python@3.3.0:3.3") - depends_on( - "py-urllib3@1.20:1.25.7", type=("build", "run"), when="@1.14.12:1.18 ^python@3.4.0:3.4" - ) - depends_on("py-urllib3@1.20:1.25", type=("build", "run"), when="@1.14.12:1.18") - depends_on( - "py-urllib3@1.25.4:1.25.7", type=("build", "run"), when="@1.19.0: ^python@3.4.0:3.4" - ) - depends_on("py-urllib3@1.25.4:1.25", type=("build", "run"), when="@1.19.0:1.19.15") - depends_on("py-urllib3@1.25.4:1.26", type=("build", "run"), when="@1.19.16:") diff --git a/repo/packages/py-docutils/package.py b/repo/packages/py-docutils/package.py deleted file mode 100644 index 87c27baa..00000000 --- a/repo/packages/py-docutils/package.py +++ /dev/null @@ -1,53 +0,0 @@ -#url change - -#- homepage = "http://docutils.sourceforge.net/" -#- pypi = "docutils/docutils-0.15.2.tar.gz" -#+ homepage = "https://files.pythonhosted.org/packages/6b/5c/330ea8d383eb2ce973df34d1239b3b21e91cd8c865d21ff82902d952f91f/" -#+ pypi = "docutils-0.19.tar.gz" - -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -import os - -from spack.package import * - - -class PyDocutils(PythonPackage): - """Docutils is an open-source text processing system for processing - plaintext documentation into useful formats, such as HTML, LaTeX, - man-pages, open-document or XML. It includes reStructuredText, the - easy to read, easy to use, what-you-see-is-what-you-get plaintext - markup language.""" - - homepage = "https://files.pythonhosted.org/packages/6b/5c/330ea8d383eb2ce973df34d1239b3b21e91cd8c865d21ff82902d952f91f/" - pypi = "docutils-0.19.tar.gz" - - version("0.19", sha256="33995a6753c30b7f577febfc2c50411fec6aac7f7ffeb7c4cfe5991072dcf9e6") - version("0.18.1", sha256="679987caf361a7539d76e584cbeddc311e3aee937877c87346f31debc63e9d06") - version("0.18", sha256="c1d5dab2b11d16397406a282e53953fe495a46d69ae329f55aa98a5c4e3c5fbb") - version("0.17.1", sha256="686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125") - version("0.17", sha256="e2ffeea817964356ba4470efba7c2f42b6b0de0b04e66378507e3e2504bbff4c") - version("0.16", sha256="c2de3a60e9e7d07be26b7f2b00ca0309c207e06c100f9cc2a94931fc75a478fc") - version("0.15.2", sha256="a2aeea129088da402665e92e0b25b04b073c04b2dce4ab65caaa38b7ce2e1a99") - version("0.14", sha256="51e64ef2ebfb29cae1faa133b3710143496eca21c530f3f71424d77687764274") - version("0.13.1", sha256="718c0f5fb677be0f34b781e04241c4067cbd9327b66bdd8e763201130f5175be") - version("0.12", sha256="c7db717810ab6965f66c8cf0398a98c9d8df982da39b4cd7f162911eb89596fa") - - depends_on("python@3.7:", when="@0.19:", type=("build", "run")) - depends_on("python@2.7:2.8,3.5:", when="@0.16:", type=("build", "run")) - depends_on("python@2.6:2.8,3.3:", when="@0.14:0.15", type=("build", "run")) - depends_on("python@2.4:", when="@:0.13", type=("build", "run")) - depends_on("py-setuptools", when="@0.15:", type="build") - - # NOTE: This creates symbolic links to be able to run docutils scripts - # without .py file extension similarly to various linux distributions to - # increase compatibility with other packages - @run_after("install") - def post_install(self): - bin_path = self.prefix.bin - for file in os.listdir(bin_path): - if file.endswith(".py"): - os.symlink(os.path.join(bin_path, file), os.path.join(bin_path, file[:-3])) From 05bfe265988456888f1df6bd04b123a0881a9c35 Mon Sep 17 00:00:00 2001 From: Dr Marco De La Pierre Date: Mon, 21 Aug 2023 10:36:44 +0800 Subject: [PATCH 16/21] removed py-hatchet: key diff is version addition Signed-off-by: Dr Marco De La Pierre --- repo/packages/py-hatchet/package.py | 84 ----------------------------- 1 file changed, 84 deletions(-) delete mode 100644 repo/packages/py-hatchet/package.py diff --git a/repo/packages/py-hatchet/package.py b/repo/packages/py-hatchet/package.py deleted file mode 100644 index 4bb53057..00000000 --- a/repo/packages/py-hatchet/package.py +++ /dev/null @@ -1,84 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# Differences for the 'py-hatchet' package -# 1c1 -# < # Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# --- -# > # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other -# 6c6 -# < from spack.package import * -# --- -# > from spack import * -# 14,15c14,15 -# < url = "https://files.pythonhosted.org/packages/be/75/904c27e3d96d73d5743257caaf820564b0ac3be3497ec2765200ed5241f9/hatchet-1.3.1.tar.gz" -# < tags = ["radiuss"] -# --- -# > url = "https://github.com/hatchet/hatchet/archive/v1.0.0.tar.gz" -# > tags = ['radiuss'] -# 19,35c19,32 -# < version("1.3.1", sha256="17b36abd4bc8c6d5fed452267634170159062ca3c2534199b1c8378f2f3f1f28") -# < version("1.3.0", sha256="d77d071fc37863fdc9abc3fd9ea1088904cd98c6980a014a31e44595d2deac5e") -# < version("1.2.0", sha256="1d5f80abfa69d1a379dff7263908c5c915023f18f26d50b639556e2f43ac755e") -# < version("1.1.0", sha256="71bfa2881ef295294e5b4493acb8cce98d14c354e9ae59b42fb56a76d8ec7056") -# < version("1.0.1", sha256="e5a4b455ab6bfbccbce3260673d9af8d1e4b21e19a2b6d0b6c1e1d7727613b7a") -# < version("1.0.0", sha256="efd218bc9152abde0a8006489a2c432742f00283a114c1eeb6d25abc10f5862d") -# < -# < # https://github.com/hatchet/hatchet/issues/428 -# < depends_on("python@2.7:3.10.15", when="@:1.3.0", type=("build", "run")) -# < depends_on("python@2.7:", when="@1.3.1:", type=("build", "run")) -# < -# < depends_on("py-setuptools", type="build") -# < depends_on("py-matplotlib", type=("build", "run")) -# < depends_on("py-numpy", type=("build", "run")) -# < depends_on("py-pandas", type=("build", "run")) -# < depends_on("py-pydot", type=("build", "run")) -# < depends_on("py-pyyaml", type=("build", "run")) -# --- -# > version('1.3.0', sha256='d77d071fc37863fdc9abc3fd9ea1088904cd98c6980a014a31e44595d2deac5e') -# > version('1.2.0', sha256='1d5f80abfa69d1a379dff7263908c5c915023f18f26d50b639556e2f43ac755e') -# > version('1.1.0', sha256='71bfa2881ef295294e5b4493acb8cce98d14c354e9ae59b42fb56a76d8ec7056') -# > version('1.0.1', sha256='e5a4b455ab6bfbccbce3260673d9af8d1e4b21e19a2b6d0b6c1e1d7727613b7a') -# > version('1.0.0', sha256='efd218bc9152abde0a8006489a2c432742f00283a114c1eeb6d25abc10f5862d') -# > -# > depends_on('python@2.7,3:', type=('build', 'run')) -# > -# > depends_on('py-setuptools', type='build') -# > depends_on('py-matplotlib', type=('build', 'run')) -# > depends_on('py-numpy', type=('build', 'run')) -# > depends_on('py-pandas', type=('build', 'run')) -# > depends_on('py-pydot', type=('build', 'run')) -# > depends_on('py-pyyaml', type=('build', 'run')) - -# Check if it works -from spack.package import * - - -class PyHatchet(PythonPackage): - """Hatchet is a performance tool for analyzing hierarchical performance data - using a graph-indexed Pandas dataframe.""" - - homepage = "https://github.com/hatchet/hatchet" - url = "https://files.pythonhosted.org/packages/be/75/904c27e3d96d73d5743257caaf820564b0ac3be3497ec2765200ed5241f9/hatchet-1.3.1.tar.gz" - tags = ["radiuss"] - - maintainers = ["slabasan", "bhatele", "tgamblin"] - - version("1.3.1", sha256="17b36abd4bc8c6d5fed452267634170159062ca3c2534199b1c8378f2f3f1f28") - version("1.3.0", sha256="d77d071fc37863fdc9abc3fd9ea1088904cd98c6980a014a31e44595d2deac5e") - version("1.2.0", sha256="1d5f80abfa69d1a379dff7263908c5c915023f18f26d50b639556e2f43ac755e") - version("1.1.0", sha256="71bfa2881ef295294e5b4493acb8cce98d14c354e9ae59b42fb56a76d8ec7056") - version("1.0.1", sha256="e5a4b455ab6bfbccbce3260673d9af8d1e4b21e19a2b6d0b6c1e1d7727613b7a") - version("1.0.0", sha256="efd218bc9152abde0a8006489a2c432742f00283a114c1eeb6d25abc10f5862d") - - # https://github.com/hatchet/hatchet/issues/428 - depends_on("python@2.7:3.10.15", when="@:1.3.0", type=("build", "run")) - depends_on("python@2.7:", when="@1.3.1:", type=("build", "run")) - - depends_on("py-setuptools", type="build") - depends_on("py-matplotlib", type=("build", "run")) - depends_on("py-numpy", type=("build", "run")) - depends_on("py-pandas", type=("build", "run")) - depends_on("py-pydot", type=("build", "run")) - depends_on("py-pyyaml", type=("build", "run")) From 0d27431ea0c889e8d24cb77c7e47c67352302a3c Mon Sep 17 00:00:00 2001 From: Dr Marco De La Pierre Date: Mon, 21 Aug 2023 10:43:53 +0800 Subject: [PATCH 17/21] removing hcptoolkit recipe Signed-off-by: Dr Marco De La Pierre --- repo/packages/hpctoolkit/gcc10-enum.patch | 15 -- repo/packages/hpctoolkit/package.py | 263 ---------------------- repo/packages/hpctoolkit/python3.patch | 12 - 3 files changed, 290 deletions(-) delete mode 100644 repo/packages/hpctoolkit/gcc10-enum.patch delete mode 100644 repo/packages/hpctoolkit/package.py delete mode 100644 repo/packages/hpctoolkit/python3.patch diff --git a/repo/packages/hpctoolkit/gcc10-enum.patch b/repo/packages/hpctoolkit/gcc10-enum.patch deleted file mode 100644 index c2ae786c..00000000 --- a/repo/packages/hpctoolkit/gcc10-enum.patch +++ /dev/null @@ -1,15 +0,0 @@ -See: https://github.com/HPCToolkit/hpctoolkit/issues/309 - -diff --git a/src/tool/hpcrun/gpu/gpu-metrics.h b/src/tool/hpcrun/gpu/gpu-metrics.h -index ea0958156..fa3bceab1 100644 ---- a/src/tool/hpcrun/gpu/gpu-metrics.h -+++ b/src/tool/hpcrun/gpu/gpu-metrics.h -@@ -61,7 +61,7 @@ - //***************************************************************************** - - --enum { -+typedef enum { - GPU_INST_STALL_ANY = 0 - } gpu_inst_stall_all_t; - diff --git a/repo/packages/hpctoolkit/package.py b/repo/packages/hpctoolkit/package.py deleted file mode 100644 index dce3e85a..00000000 --- a/repo/packages/hpctoolkit/package.py +++ /dev/null @@ -1,263 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# Modifications have to do with avoiding using python2. Try a new version of the recipe. -import llnl.util.tty as tty - -from spack.package import * - - -class Hpctoolkit(AutotoolsPackage): - """HPCToolkit is an integrated suite of tools for measurement and analysis - of program performance on computers ranging from multicore desktop systems - to the nation's largest supercomputers. By using statistical sampling of - timers and hardware performance counters, HPCToolkit collects accurate - measurements of a program's work, resource consumption, and inefficiency - and attributes them to the full calling context in which they occur.""" - - homepage = "http://hpctoolkit.org" - git = "https://github.com/HPCToolkit/hpctoolkit.git" - maintainers = ['mwkrentel'] - - tags = ['e4s'] - - test_requires_compiler = True - - version('develop', branch='develop') - version('master', branch='master') - - version('2022.04.15', commit='a92fdad29fc180cc522a9087bba9554a829ee002') - version('2022.01.15', commit='0238e9a052a696707e4e65b2269f342baad728ae') - version('2021.10.15', commit='a8f289e4dc87ff98e05cfc105978c09eb2f5ea16') - version('2021.05.15', commit='004ea0c2aea6a261e7d5d216c24f8a703fc6c408') - version('2021.03.01', commit='68a051044c952f0f4dac459d9941875c700039e7') - version('2020.08.03', commit='d9d13c705d81e5de38e624254cf0875cce6add9a') - version('2020.07.21', commit='4e56c780cffc53875aca67d6472a2fb3678970eb') - version('2020.06.12', commit='ac6ae1156e77d35596fea743ed8ae768f7222f19') - version('2020.03.01', commit='94ede4e6fa1e05e6f080be8dc388240ea027f769') - version('2019.12.28', commit='b4e1877ff96069fd8ed0fdf0e36283a5b4b62240') - version('2019.08.14', commit='6ea44ed3f93ede2d0a48937f288a2d41188a277c', deprecated=True) - version('2018.12.28', commit='8dbf0d543171ffa9885344f32f23cc6f7f6e39bc', deprecated=True) - version('2018.11.05', commit='d0c43e39020e67095b1f1d8bb89b75f22b12aee9', deprecated=True) - - # Options for MPI and hpcprof-mpi. We always support profiling - # MPI applications. These options add hpcprof-mpi, the MPI - # version of hpcprof. Cray and Blue Gene need separate options - # because an MPI module in packages.yaml doesn't work on these - # systems. - variant('cray', default=False, - description='Build for Cray compute nodes, including ' - 'hpcprof-mpi.') - - variant('mpi', default=False, - description='Build hpcprof-mpi, the MPI version of hpcprof.') - - # We can't build with both PAPI and perfmon for risk of segfault - # from mismatched header files (unless PAPI installs the perfmon - # headers). - variant('papi', default=True, - description='Use PAPI instead of perfmon for access to ' - 'the hardware performance counters.') - - variant('all-static', default=False, - description='Needed when MPICXX builds static binaries ' - 'for the compute nodes.') - -# variant('level_zero', default=False, -# description='Support Level Zero on Intel GPUs (2022.04.15 or later).') - - variant('cuda', default=False, - description='Support CUDA on NVIDIA GPUs (2020.03.01 or later).') - - variant('rocm', default=False, - description='Support ROCM on AMD GPUs (2022.04.15 or later).') - - variant('debug', default=False, - description='Build in debug (develop) mode.') - - variant('viewer', default=True, description='Include hpcviewer.') - - boost_libs = ( - '+atomic +chrono +date_time +filesystem +system +thread +timer' - ' +graph +regex +shared +multithreaded visibility=global' - ) - - depends_on('binutils +libiberty', type='link', when='@2021.00:') - depends_on('binutils +libiberty~nls', type='link', when='@2020.04:2020') - depends_on('binutils@:2.33.1 +libiberty~nls', type='link', when='@:2020.03') - depends_on('boost' + boost_libs) - depends_on('bzip2+shared', type='link') - depends_on('dyninst@12.1.0:', when='@2022.0:') - depends_on('dyninst@10.2.0:', when='@2021.0:2021.12') - depends_on('dyninst@9.3.2:', when='@:2020') - depends_on('elfutils+bzip2+xz~nls', type='link') - depends_on('gotcha@1.0.3:', when='@:2020.09') - depends_on('intel-tbb+shared') - depends_on('libdwarf') - depends_on('libmonitor+hpctoolkit~dlopen', when='@2021.00:') - depends_on('libmonitor+hpctoolkit+dlopen', when='@:2020') - depends_on('libmonitor@2021.11.08:', when='@2022.01:') - depends_on('libunwind@1.4: +xz+pic') - depends_on('mbedtls+pic', when='@:2022.03') - depends_on('xerces-c transcoder=iconv') - depends_on('xz+pic', type='link') - depends_on('zlib+shared') - - depends_on('cuda', when='+cuda') -# depends_on('oneapi-level-zero', when='+level_zero') - depends_on('intel-xed', when='target=x86_64:') - depends_on('memkind', type=('build', 'run'), when='@2021.05.01:') - depends_on('papi', when='+papi') - depends_on('libpfm4', when='~papi') - depends_on('mpi', when='+mpi') - depends_on('hpcviewer', type='run', when='+viewer') - - depends_on('hip@4.5:', when='+rocm') - depends_on('hsa-rocr-dev@4.5:', when='+rocm') - depends_on('roctracer-dev@4.5:', when='+rocm') - depends_on('rocprofiler-dev@4.5:', when='+rocm') - - conflicts('%gcc@:4.7', when='^dyninst@10.0.0:', - msg='hpctoolkit requires gnu gcc 4.8.x or later') - - conflicts('%gcc@:4', when='@2020.03:2020', - msg='hpctoolkit requires gnu gcc 5.x or later') - - conflicts('%gcc@:6', when='@2021.00:', - msg='hpctoolkit requires gnu gcc 7.x or later') - - conflicts('+cuda', when='@:2019', - msg='cuda requires 2020.03.01 or later') - - conflicts('+rocm', when='@:2022.03', - msg='rocm requires 2022.04.15 or later') - - conflicts('^binutils@2.35:2.35.1', - msg='avoid binutils 2.35 and 2.35.1 (spews errors)') - - # Fix the build for old revs with gcc 10.x. - patch('gcc10-enum.patch', when='@2020.01.01:2020.08 %gcc@10.0:') - - patch('https://github.com/HPCToolkit/hpctoolkit/commit/511afd95b01d743edc5940c84e0079f462b2c23e.patch?full_index=1', - sha256='c8371b929f45dafae37d2ef17880fcfb86de893beebaec501a282bc04b61ef64', - when='@2019.08.01:2021.03 %gcc@11.0:') - - # Change python to python3 for some old revs that use a script - # with /usr/bin/env python. - depends_on('python@3.4:', type='build', when='@2020.03:2020.08') - patch('python3.patch', when='@2020.03:2020.08') - - flag_handler = AutotoolsPackage.build_system_flags - - def configure_args(self): - spec = self.spec - - args = [ - '--with-binutils=%s' % spec['binutils'].prefix, - '--with-boost=%s' % spec['boost'].prefix, - '--with-bzip=%s' % spec['bzip2'].prefix, - '--with-dyninst=%s' % spec['dyninst'].prefix, - '--with-elfutils=%s' % spec['elfutils'].prefix, - '--with-tbb=%s' % spec['intel-tbb'].prefix, - '--with-libdwarf=%s' % spec['libdwarf'].prefix, - '--with-libmonitor=%s' % spec['libmonitor'].prefix, - '--with-libunwind=%s' % spec['libunwind'].prefix, - '--with-xerces=%s' % spec['xerces-c'].prefix, - '--with-lzma=%s' % spec['xz'].prefix, - '--with-zlib=%s' % spec['zlib'].prefix, - ] - - if '+cuda' in spec: - args.append('--with-cuda=%s' % spec['cuda'].prefix) - -# if '+level_zero' in spec: -# args.append('--with-level0=%s' % spec['oneapi-level-zero'].prefix) - - if spec.satisfies('@:2020.09'): - args.append('--with-gotcha=%s' % spec['gotcha'].prefix) - - if spec.target.family == 'x86_64': - args.append('--with-xed=%s' % spec['intel-xed'].prefix) - - if spec.satisfies('@:2022.03'): - args.append('--with-mbedtls=%s' % spec['mbedtls'].prefix) - - if spec.satisfies('@2021.05.01:'): - args.append('--with-memkind=%s' % spec['memkind'].prefix) - - if spec.satisfies('+papi'): - args.append('--with-papi=%s' % spec['papi'].prefix) - else: - args.append('--with-perfmon=%s' % spec['libpfm4'].prefix) - - if spec.satisfies('+rocm'): - args.extend([ - '--with-rocm-hip=%s' % spec['hip'].prefix, - '--with-rocm-hsa=%s' % spec['hsa-rocr-dev'].prefix, - '--with-rocm-tracer=%s' % spec['roctracer-dev'].prefix, - '--with-rocm-profiler=%s' % spec['rocprofiler-dev'].prefix, - ]) - - # MPI options for hpcprof-mpi. - if '+cray' in spec: - args.extend([ - '--enable-mpi-search=cray', - '--enable-all-static', - ]) - elif '+mpi' in spec: - args.append('MPICXX=%s' % spec['mpi'].mpicxx) - - if '+all-static' in spec: - args.append('--enable-all-static') - - if spec.satisfies('+debug'): - args.append('--enable-develop') - - return args - - # We only want hpctoolkit and hpcviewer paths and man paths in the - # module file. The run dependencies are all curried into hpctoolkit - # and we don't want to risk exposing a package if the application - # uses a different version of the same package. - def setup_run_environment(self, env): - spec = self.spec - env.clear() - env.prepend_path('PATH', spec.prefix.bin) - env.prepend_path('MANPATH', spec.prefix.share.man) - if '+viewer' in spec: - env.prepend_path('PATH', spec['hpcviewer'].prefix.bin) - env.prepend_path('MANPATH', spec['hpcviewer'].prefix.share.man) - - # Build tests (spack install --run-tests). Disable the default - # spack tests and run autotools 'make check', but only from the - # tests directory. - build_time_test_callbacks = [] - install_time_test_callbacks = [] - - @run_after('install') - @on_package_attributes(run_tests=True) - def check_install(self): - if self.spec.satisfies('@2022:'): - with working_dir('tests'): - make('check') - else: - tty.warn('spack test for hpctoolkit requires 2022.01.15 or later') - - # Post-Install tests (spack test run). These are the same tests - # but with a different Makefile that works outside the build - # directory. - @run_after('install') - def copy_test_files(self): - if self.spec.satisfies('@2022:'): - self.cache_extra_test_sources(['tests']) - - def test(self): - test_dir = join_path(self.test_suite.current_test_cache_dir, 'tests') - if self.spec.satisfies('@2022:'): - with working_dir(test_dir): - make('-f', 'Makefile.spack', 'all') - self.run_test('./run-sort', status=[0], installed=False, - purpose='selection sort unit test') - else: - tty.warn('spack test for hpctoolkit requires 2022.01.15 or later') diff --git a/repo/packages/hpctoolkit/python3.patch b/repo/packages/hpctoolkit/python3.patch deleted file mode 100644 index ac829bda..00000000 --- a/repo/packages/hpctoolkit/python3.patch +++ /dev/null @@ -1,12 +0,0 @@ -Some older revs call python instead of python3. - -diff --git a/src/tool/hpcstruct/stringify.py b/src/tool/hpcstruct/stringify.py -index 954f87593..c31984d21 100755 ---- a/src/tool/hpcstruct/stringify.py -+++ b/src/tool/hpcstruct/stringify.py -@@ -1,4 +1,4 @@ --#!/usr/bin/env python -+#!/usr/bin/env python3 - - import sys - import re From aa18c148c1ea6fb8ebd7742dd1e4a706032e0d76 Mon Sep 17 00:00:00 2001 From: Dr Marco De La Pierre Date: Tue, 22 Aug 2023 09:07:58 +0800 Subject: [PATCH 18/21] removed amdblis: PR merged in global Spack Signed-off-by: Dr Marco De La Pierre --- repo/packages/amdblis/package.py | 94 -------------------------------- 1 file changed, 94 deletions(-) delete mode 100644 repo/packages/amdblis/package.py diff --git a/repo/packages/amdblis/package.py b/repo/packages/amdblis/package.py deleted file mode 100644 index 9c6a6b7b..00000000 --- a/repo/packages/amdblis/package.py +++ /dev/null @@ -1,94 +0,0 @@ -# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# -# ======================================================================= -# PAWSEY ADDITIONS -# ======================================================================= -# Ask marco -# 33c33,37 -# < -# --- -# > variant( -# > 'suphandling', default=True, -# > description='Small Unpacked Kernel handling', -# > ) -# > -# 39a44,48 -# > -# > if spec.satisfies('+suphandling'): -# > args.append("--enable-sup-handling") -# > else: -# > args.append("--disable-sup-handling") - - -from spack.package import * -from spack.pkg.builtin.blis import BlisBase - - -class Amdblis(BlisBase): - """AMD Optimized BLIS. - - BLIS is a portable software framework for instantiating high-performance - BLAS-like dense linear algebra libraries. The framework was designed to - isolate essential kernels of computation that, when optimized, immediately - enable optimized implementations of most of its commonly used and - computationally intensive operations. - """ - - _name = "amdblis" - homepage = "https://developer.amd.com/amd-aocl/blas-library/" - url = "https://github.com/amd/blis/archive/3.0.tar.gz" - git = "https://github.com/amd/blis.git" - - maintainers = ["amd-toolchain-support"] - - version("3.2", sha256="5a400ee4fc324e224e12f73cc37b915a00f92b400443b15ce3350278ad46fff6") - version("3.1", sha256="2891948925b9db99eec02a1917d9887a7bee9ad2afc5421c9ba58602a620f2bf") - version("3.0.1", sha256="dff643e6ef946846e91e8f81b75ff8fe21f1f2d227599aecd654d184d9beff3e") - version("3.0", sha256="ac848c040cd6c3550fe49148dbdf109216cad72d3235763ee7ee8134e1528517") - version("2.2", sha256="e1feb60ac919cf6d233c43c424f6a8a11eab2c62c2c6e3f2652c15ee9063c0c9") - - variant("ilp64", default=False, when="@3.0.1:", description="ILP64 support") - variant( - 'suphandling', default=True, - description='Small Unpacked Kernel handling', - ) - - def configure_args(self): - spec = self.spec - args = super(Amdblis, self).configure_args() - - if spec.satisfies("+ilp64"): - args.append("--blas-int-size=64") - - if spec.satisfies('+suphandling'): - args.append("--enable-sup-handling") - else: - args.append("--disable-sup-handling") - - # To enable Fortran to C calling convention for - # complex types when compiling with aocc flang - if self.spec.satisfies("@3.0 %aocc"): - args.append("CFLAGS={0}".format("-DAOCL_F2C")) - args.append("CXXFLAGS={0}".format("-DAOCL_F2C")) - elif self.spec.satisfies("@3.0.1: %aocc"): - args.append("--complex-return=intel") - - if self.spec.satisfies("@3.1:"): - args.append("--disable-aocl-dynamic") - - return args - - def config_args(self): - config_args = super(Amdblis, self).config_args() - - # "amdzen" - A fat binary or multiarchitecture binary - # support for 3.1 release onwards - if self.spec.satisfies("@3.1:"): - config_args.append("amdzen") - else: - config_args.append("auto") - - return config_args From fb6c59e3579870b3901620aa8685bb5e3cc93e6e Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Wed, 21 Aug 2024 11:42:19 +0800 Subject: [PATCH 19/21] Keeps track of differences. --- repo/packages/diff_all.txt | 7077 ++++++++++++++++++++++++++++++++ repo/packages/not_in_spack.txt | 16 + 2 files changed, 7093 insertions(+) create mode 100644 repo/packages/diff_all.txt create mode 100644 repo/packages/not_in_spack.txt diff --git a/repo/packages/diff_all.txt b/repo/packages/diff_all.txt new file mode 100644 index 00000000..4dc2a5eb --- /dev/null +++ b/repo/packages/diff_all.txt @@ -0,0 +1,7077 @@ +###### DIFF amber +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5c5 +< # CONTRIBUTE - cray patches +--- +> +29c29 +< #maintainers("hseara") +--- +> maintainers("hseara") +41,42c41,42 +< # "20": ("21", "f55fa930598d5a8e9749e8a22d1f25cab7fcf911d98570e35365dd7f262aaafd"), +< '20': ('20', 'b1e1f8f277c54e88abc9f590e788bbb2f7a49bcff5e8d8a6eacfaf332a4890f9'), +--- +> "20": ("21", "f55fa930598d5a8e9749e8a22d1f25cab7fcf911d98570e35365dd7f262aaafd"), +> # '20': ('20', 'b1e1f8f277c54e88abc9f590e788bbb2f7a49bcff5e8d8a6eacfaf332a4890f9'), +128c128 +< depends_on("zlib") +--- +> depends_on("zlib-api") +146d145 +< conflicts("+x11", when="platform=cray", msg="x11 amber applications not available for cray") +###### DIFF amdgromacs +###### DIFF ansys-fluids +###### DIFF ansys-fluidstructures +###### DIFF ansys-structures +###### DIFF aoflagger +1,2c1,4 +< from spack.patch import apply_patch +< import os +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +> # Spack Project Developers. See the top-level COPYRIGHT file for details. +> # +> # SPDX-License-Identifier: (Apache-2.0 OR MIT) +4c6,7 +< PATCHFILE = os.path.join(os.path.dirname(os.path.abspath(__file__)), "as.patch") +--- +> from spack.package import * +> from spack.pkg.builtin.boost import Boost +11c14,15 +< maintainers("dipietrantonio") +--- +> homepage = "https://sourceforge.net/projects/aoflagger/" +> url = "https://downloads.sourceforge.net/project/aoflagger/aoflagger-2.10.0/aoflagger-2.10.0.tar.bz2" +13,14c17 +< version('3.4.0', git='https://gitlab.com/aroffringa/aoflagger.git', tag='v3.4.0', submodules=True) +< version('3.2.0', git='https://gitlab.com/aroffringa/aoflagger.git', tag='v3.2.0', submodules=True) +--- +> license("GPL-3.0-or-later") +16,24c19 +< depends_on('casacore@3.2.1:') +< depends_on('fftw@3.3.8:') +< depends_on('boost@1.80.0: +test +system +date_time') +< depends_on('libxml2') +< depends_on('cfitsio') +< depends_on('libpng') +< depends_on('hdf5@1.10: +cxx ~mpi api=v110') +< depends_on('lua@5.2:') +< depends_on('cmake', type='build') +--- +> version("2.10.0", sha256="3ec1188d37101acf2029575ebc09c50b19c158c88a12b55ac5d25a96bd8fc18d") +26c21,33 +< patch('as.patch', when='@3.2.0') +--- +> depends_on("cxx", type="build") # generated +> +> depends_on("casacore+python~fftpack@1.10:") +> depends_on("fftw~mpi@3.0:") +> depends_on("boost+python@:1.66.99") +> +> # TODO: replace this with an explicit list of components of Boost, +> # for instance depends_on('boost +filesystem') +> # See https://github.com/spack/spack/pull/22303 for reference +> depends_on(Boost.with_default_variants) +> depends_on("libxml2") +> depends_on("lapack") +> depends_on("cfitsio") +###### DIFF autoconf +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,19d4 +< # ======================================================================= +< # PAWSEY ADDITIONS +< # ======================================================================= +< # Marco +< # Differences for the 'autoconf' package +< # 68c68 +< # < filter_file('^#! @PERL@.*', +< # --- +< # > filter_file('^#! @PERL@ -w', +< # 87,88c87,88 +< # < filter_file('^#! /usr/bin/ev perl', +< # < '#! {0}'.format(self.spec['perl'].command.path), +< # --- +< # > filter_file('^#! /usr/bin/env perl', +< # > '#! {0} -w'.format(self.spec['perl'].command.path), +22a8,9 +> from spack.package import * +> +27,28c14,18 +< homepage = 'https://www.gnu.org/software/autoconf/' +< gnu_mirror_path = 'autoconf/autoconf-2.69.tar.gz' +--- +> homepage = "https://www.gnu.org/software/autoconf/" +> gnu_mirror_path = "autoconf/autoconf-2.69.tar.gz" +> +> license("GPL-3.0-or-later WITH Autoconf-exception-3.0", when="@2.62:", checked_by="tgamblin") +> license("GPL-2.0-or-later WITH Autoconf-exception-2.0", when="@:2.59", checked_by="tgamblin") +30,35c20,25 +< version('2.71', sha256='431075ad0bf529ef13cb41e9042c542381103e80015686222b8a9d4abef42a1c') +< version('2.70', sha256='f05f410fda74323ada4bdc4610db37f8dbd556602ba65bc843edb4d4d4a1b2b7') +< version('2.69', sha256='954bd69b391edc12d6a4a51a2dd1476543da5c6bbf05a95b59dc0dd6fd4c2969', +< preferred=True) +< version('2.62', sha256='83aa747e6443def0ebd1882509c53f5a2133f502ddefa21b3de141c433914bdd') +< version('2.59', sha256='9cd05c73c5fcb1f5ccae53dd6cac36bb8cb9c7b3e97ffae5a7c05c72594c88d8') +--- +> version("2.72", sha256="afb181a76e1ee72832f6581c0eddf8df032b83e2e0239ef79ebedc4467d92d6e") +> version("2.71", sha256="431075ad0bf529ef13cb41e9042c542381103e80015686222b8a9d4abef42a1c") +> version("2.70", sha256="f05f410fda74323ada4bdc4610db37f8dbd556602ba65bc843edb4d4d4a1b2b7") +> version("2.69", sha256="954bd69b391edc12d6a4a51a2dd1476543da5c6bbf05a95b59dc0dd6fd4c2969") +> version("2.62", sha256="83aa747e6443def0ebd1882509c53f5a2133f502ddefa21b3de141c433914bdd") +> version("2.59", sha256="9cd05c73c5fcb1f5ccae53dd6cac36bb8cb9c7b3e97ffae5a7c05c72594c88d8") +38,40c28,32 +< patch('https://git.savannah.gnu.org/cgit/autoconf.git/patch/?id=05972f49ee632cd98057a3caf82ebfb9574846da', +< sha256='eaa3f69d927a853313a0b06e2117c51adab6377a2278549b05abc5df93643e16', +< when='@2.70') +--- +> patch( +> "https://git.savannah.gnu.org/cgit/autoconf.git/patch/?id=05972f49ee632cd98057a3caf82ebfb9574846da", +> sha256="eaa3f69d927a853313a0b06e2117c51adab6377a2278549b05abc5df93643e16", +> when="@2.70", +> ) +43,45c35,39 +< patch('http://mirrors.mit.edu/gentoo-portage/sys-devel/autoconf/files/autoconf-2.69-fix-libtool-test.patch', +< sha256='7793209b33013dc0f81208718c68440c5aae80e7a1c4b8d336e382525af791a7', +< when='@2.69') +--- +> patch( +> "https://mirrors.mit.edu/gentoo-portage/dev-build/autoconf/files/autoconf-2.69-fix-libtool-test.patch", +> sha256="7793209b33013dc0f81208718c68440c5aae80e7a1c4b8d336e382525af791a7", +> when="@2.69", +> ) +47,49c41,45 +< patch('http://mirrors.mit.edu/gentoo-portage/sys-devel/autoconf/files/autoconf-2.69-perl-5.26.patch', +< sha256='35c449281546376449766f92d49fc121ca50e330e60fefcfc9be2af3253082c2', +< when='@2.62:2.69 ^perl@5.17:') +--- +> patch( +> "https://mirrors.mit.edu/gentoo-portage/dev-build/autoconf/files/autoconf-2.69-perl-5.26.patch", +> sha256="35c449281546376449766f92d49fc121ca50e330e60fefcfc9be2af3253082c2", +> when="@2.62:2.69 ^perl@5.17:", +> ) +51,53c47,51 +< patch('http://mirrors.mit.edu/gentoo-portage/sys-devel/autoconf/files/autoconf-2.69-perl-5.26-2.patch', +< sha256='a49dd5bac3b62daa0ff688ab4d508d71dbd2f4f8d7e2a02321926346161bf3ee', +< when='@2.62:2.69 ^perl@5.17:') +--- +> patch( +> "https://mirrors.mit.edu/gentoo-portage/dev-build/autoconf/files/autoconf-2.69-perl-5.26-2.patch", +> sha256="a49dd5bac3b62daa0ff688ab4d508d71dbd2f4f8d7e2a02321926346161bf3ee", +> when="@2.62:2.69 ^perl@5.17:", +> ) +57,58c55,57 +< depends_on('m4@1.4.6:', type=('build', 'run')) +< depends_on('perl', type=('build', 'run')) +--- +> depends_on("m4@1.4.8:", type=("build", "run"), when="@2.72:") +> depends_on("m4@1.4.6:", type=("build", "run"), when="@:2.71") +> depends_on("perl", type=("build", "run")) +60c59 +< build_directory = 'spack-build' +--- +> build_directory = "spack-build" +62c61 +< tags = ['build-tools'] +--- +> tags = ["build-tools"] +65,66c64,70 +< '^autoconf$', '^autoheader$', '^autom4te$', '^autoreconf$', +< '^autoscan$', '^autoupdate$', '^ifnames$' +--- +> "^autoconf$", +> "^autoheader$", +> "^autom4te$", +> "^autoreconf$", +> "^autoscan$", +> "^autoupdate$", +> "^ifnames$", +71,72c75,76 +< output = Executable(exe)('--version', output=str, error=str) +< match = re.search(r'\(GNU Autoconf\)\s+(\S+)', output) +--- +> output = Executable(exe)("--version", output=str, error=str) +> match = re.search(r"\(GNU Autoconf\)\s+(\S+)", output) +78c82 +< patched_file = 'bin/autom4te.in' +--- +> patched_file = "bin/autom4te.in" +83,86c87,92 +< filter_file('^#! @PERL@.*', +< '#! /usr/bin/env perl', +< patched_file) +< if self.version == Version('2.62'): +--- +> if self.spec.satisfies("@2.70:"): +> shebang_string = "^#! @PERL@" +> else: +> shebang_string = "^#! @PERL@ -w" +> filter_file(shebang_string, "#! /usr/bin/env perl", patched_file) +> if self.version == Version("2.62"): +88,89c94,95 +< touch('man/autoheader.1') +< touch('man/autoscan.1') +--- +> touch("man/autoheader.1") +> touch("man/autoscan.1") +95c101 +< @run_after('install') +--- +> @run_after("install") +100a107,111 +> if self.spec.satisfies("@2.70:"): +> shebang_string = "#! {0}" +> else: +> shebang_string = "#! {0} -w" +> +102,105c113,118 +< filter_file('^#! /usr/bin/ev perl', +< '#! {0}'.format(self.spec['perl'].command.path), +< self.prefix.bin.autom4te, +< backup=False) +--- +> filter_file( +> "^#! /usr/bin/env perl", +> shebang_string.format(self.spec["perl"].command.path), +> self.prefix.bin.autom4te, +> backup=False, +> ) +113,119c126,134 +< executables = ['autoconf', +< 'autoheader', +< 'autom4te', +< 'autoreconf', +< 'autoscan', +< 'autoupdate', +< 'ifnames'] +--- +> executables = [ +> "autoconf", +> "autoheader", +> "autom4te", +> "autoreconf", +> "autoscan", +> "autoupdate", +> "ifnames", +> ] +###### DIFF birli +###### DIFF blaspp +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,6c5 +< # PAWSEY Additions +< # added 2023.11.05 version +--- +> +22c21,29 +< version("2023.11.05", sha256="62dfc03ec07c0826e0466dc2c204b460caa929d53ad4f050cb132d92670be7ce") +--- +> license("BSD-3-Clause") +> +> version("master", branch="master") +> version( +> "2024.05.31", sha256="24f325d2e1c2cc4275324bd88406555688379480877d19553656a0328287927a" +> ) +> version( +> "2023.11.05", sha256="62dfc03ec07c0826e0466dc2c204b460caa929d53ad4f050cb132d92670be7ce" +> ) +47a55,56 +> depends_on("cxx", type="build") # generated +> +77a87,88 +> patch("0001-fix-blaspp-build-error-with-rocm-6.0.0.patch", when="@2023.06.00: ^hip@6.0 +rocm") +> +83c94 +< if "+cuda" in spec: +--- +> if spec.satisfies("+cuda"): +85c96 +< if "+rocm" in spec: +--- +> if spec.satisfies("+rocm"): +87c98 +< if "+sycl" in spec: +--- +> if spec.satisfies("+sycl"): +###### DIFF boost +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5d4 +< # Pawsey additions to handle cce compiler: if self.spec.satisfies("@1.79.0 %oneapi") or self.spec.satisfies("%cce"): +24c23 +< url = "http://downloads.sourceforge.net/project/boost/boost/1.55.0/boost_1_55_0.tar.bz2" +--- +> url = "https://downloads.sourceforge.net/project/boost/boost/1.55.0/boost_1_55_0.tar.bz2" +29a29,30 +> license("BSL-1.0") +> +30a32,33 +> version("1.85.0", sha256="7009fe1faa1697476bdc7027703a2badb84e849b7b0baad5086b087b971f8617") +> version("1.84.0", sha256="cc4b893acf645c9d4b698e9a0f08ca8846aa5d6c68275c14c3e7949c24109454") +78a82,84 +> depends_on("c", type="build") +> depends_on("cxx", type="build") +> +173c179 +< default="98", +--- +> default="11", +188a195,198 +> +> # 1.84.0 dropped support for 98/03 +> conflicts("cxxstd=98", when="@1.84.0:") +> +240a251,252 +> # https://github.com/boostorg/python/issues/431 +> depends_on("py-numpy@:1", when="@:1.85+numpy", type=("build", "run")) +283a296,302 +> # Boost 1.85.0 stacktrace added a hard compilation error that has to +> # explicitly be suppressed on some platforms: +> # https://github.com/boostorg/stacktrace/pull/150. This conflict could be +> # turned into a variant that allows users to opt-in when they know it is +> # safe to do so on affected platforms. +> conflicts("+clanglibcpp", when="@1.85: +stacktrace") +> +310a330,332 +> # Patch to workaround gcc-8.3 compiler issue https://github.com/boostorg/mpl/issues/44 +> patch("boost_gcc83_cpp17_fix.patch", when="@1.69:%gcc@8.3") +> +328,330d349 +< # Fix the bootstrap/bjam build for Cray +< patch("bootstrap-path.patch", when="@1.39.0: platform=cray") +< +432c451 +< url = "https://boostorg.jfrog.io/artifactory/main/release/{0}/source/boost_{1}.tar.bz2" +--- +> url = "https://archives.boost.io/release/{0}/source/boost_{1}.tar.bz2" +434c453 +< url = "http://downloads.sourceforge.net/project/boost/boost/{0}/boost_{1}.tar.bz2" +--- +> url = "https://downloads.sourceforge.net/project/boost/boost/{0}/boost_{1}.tar.bz2" +440c459 +< if self.spec.satisfies("@1.79.0 %oneapi") or self.spec.satisfies("%cce"): +--- +> if self.spec.satisfies("@1.79.0 %oneapi"): +491c510 +< if "+python" in spec: +--- +> if spec.satisfies("+python"): +494c513 +< if "+icu" in spec: +--- +> if spec.satisfies("+icu"): +506c525 +< if "+mpi" in spec: +--- +> if spec.satisfies("+mpi"): +514,517d532 +< +< if "platform=cray" in spec: +< mpi_line += " : MPICH_SKIP_MPICXX" +< +520c535 +< if "+python" in spec: +--- +> if spec.satisfies("+python"): +524c539 +< if "+debug" in spec: +--- +> if spec.satisfies("+debug"): +529c544 +< if "+icu" in spec: +--- +> if spec.satisfies("+icu"): +534c549 +< if "+iostreams" in spec: +--- +> if spec.satisfies("+iostreams"): +556c571 +< if "platform=darwin" in self.spec: +--- +> if self.spec.satisfies("platform=darwin"): +560c575 +< if "+shared" in spec: +--- +> if spec.satisfies("+shared"): +564c579 +< if "+multithreaded" in spec: +--- +> if spec.satisfies("+multithreaded"): +566c581 +< if "+singlethreaded" in spec: +--- +> if spec.satisfies("+singlethreaded"): +577c592 +< if "+taggedlayout" in spec: +--- +> if spec.satisfies("+taggedlayout"): +579c594 +< elif "+versionedlayout" in spec: +--- +> elif spec.satisfies("+versionedlayout"): +611c626 +< if "+pic" in self.spec: +--- +> if self.spec.satisfies("+pic"): +620c635 +< if "+clanglibcpp" in spec: +--- +> if spec.satisfies("+clanglibcpp"): +629a645,651 +> # See conflict above and +> # https://github.com/boostorg/stacktrace/pull/150. This suppresses a +> # compilation error that must be explicitly suppressed. Because of the +> # conflict we can suppress the error without input from a user. +> if spec.satisfies("@1.85: +stacktrace"): +> cxxflags.append("-DBOOST_STACKTRACE_LIBCXX_RUNTIME_MAY_CAUSE_MEMORY_LEAK") +> +677c699 +< if "+graph" in spec and "+mpi" in spec: +--- +> if spec.satisfies("+graph") and spec.satisfies("+mpi"): +734c756 +< if "@develop" in spec: +--- +> if spec.satisfies("@develop"): +747c769 +< if "+multithreaded" in spec and "~taggedlayout" in spec: +--- +> if spec.satisfies("+multithreaded") and spec.satisfies("~taggedlayout"): +778d799 +< +###### DIFF calceph +###### DIFF casacore +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,7c5 +< # Contribute +< # - Fix fftw dependency to set the fftw-api +< # - Dependency on gsl when @3.5.0: +--- +> +17c15,19 +< url = "https://github.com/casacore/casacore/archive/v2.4.1.tar.gz" +--- +> url = "https://github.com/casacore/casacore/archive/refs/tags/v3.5.0.tar.gz" +> +> maintainers("mpokorny") +> +> license("LGPL-2.0-only") +19c21,47 +< maintainers = ['mpokorny'] +--- +> version("3.5.0", sha256="63f1c8eff932b0fcbd38c598a5811e6e5397b72835b637d6f426105a183b3f91") +> version("3.4.0", sha256="31f02ad2e26f29bab4a47a2a69e049d7bc511084a0b8263360e6157356f92ae1") +> version("3.3.0", sha256="3a714644b908ef6e81489b792cc9b80f6d8267a275e15d38a42a6a5137d39d3d") +> version("3.2.0", sha256="ae5d3786cb6dfdd7ebc5eecc0c724ff02bbf6929720bc23be43a027978e79a5f") +> version("3.1.2", sha256="ac94f4246412eb45d503f1019cabe2bb04e3861e1f3254b832d9b1164ea5f281") +> version("3.1.1", sha256="85d2b17d856592fb206b17e0a344a29330650a4269c80b87f8abb3eaf3dadad4") +> version("3.1.0", sha256="a6adf2d77ad0d6f32995b1e297fd88d31ded9c3e0bb8f28966d7b35a969f7897") +> version("3.0.0", sha256="6f0e68fd77b5c96299f7583a03a53a90980ec347bff9dfb4c0abb0e2933e6bcb") +> version("2.4.1", sha256="58eccc875053b2c6fe44fe53b6463030ef169597ec29926936f18d27b5087d63") +> +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> depends_on("fortran", type="build") # generated +> +> depends_on("cmake@3.7.1:", type="build") +> +> variant("adios2", default=False, description="Build ADIOS2 support") +> variant("dysco", default=True, when="@3.5.0:", description="Build Dysco storage manager") +> variant("fftpack", default=False, description="Build FFTPack") +> variant("hdf5", default=False, description="Build HDF5 support") +> variant("mpi", default=False, description="Use MPI for parallel I/O") +> variant("openmp", default=False, description="Build OpenMP support") +> variant("python", default=False, description="Build python support") +> variant("readline", default=True, description="Build readline support") +> variant("shared", default=True, description="Build shared libraries") +> variant("tablelocking", default=True, description="Enable table locking") +> variant("threads", default=True, description="Use mutex thread synchronization") +21,43d48 +< version('3.5.0', sha256='63f1c8eff932b0fcbd38c598a5811e6e5397b72835b637d6f426105a183b3f91') +< version('3.4.0', sha256='31f02ad2e26f29bab4a47a2a69e049d7bc511084a0b8263360e6157356f92ae1') +< version('3.3.0', sha256='3a714644b908ef6e81489b792cc9b80f6d8267a275e15d38a42a6a5137d39d3d') +< version('3.2.1', sha256='f87ce81d2b42ec5401cff8317baeeb9a3b408b716bb791ef252ad97af6e235ad') +< version('3.2.0', sha256='ae5d3786cb6dfdd7ebc5eecc0c724ff02bbf6929720bc23be43a027978e79a5f') +< version('3.1.2', sha256='ac94f4246412eb45d503f1019cabe2bb04e3861e1f3254b832d9b1164ea5f281') +< version('3.1.1', sha256='85d2b17d856592fb206b17e0a344a29330650a4269c80b87f8abb3eaf3dadad4') +< version('3.1.0', sha256='a6adf2d77ad0d6f32995b1e297fd88d31ded9c3e0bb8f28966d7b35a969f7897') +< version('3.0.0', sha256='6f0e68fd77b5c96299f7583a03a53a90980ec347bff9dfb4c0abb0e2933e6bcb') +< version('2.4.1', sha256='58eccc875053b2c6fe44fe53b6463030ef169597ec29926936f18d27b5087d63') +< +< depends_on('cmake@3.7.1:', type='build') +< +< variant('openmp', default=False, description='Build OpenMP support') +< variant('shared', default=True, description='Build shared libraries') +< variant('readline', default=True, description='Build readline support') +< # see note below about the reason for disabling the "sofa" variant +< # variant('sofa', default=False, description='Build SOFA support') +< variant('adios2', default=False, description='Build ADIOS2 support') +< variant('fftpack', default=False, description='Build FFTPack') +< variant('hdf5', default=False, description='Build HDF5 support') +< variant('python', default=False, description='Build python support') +< variant('tablelocking', default=False, description='Enable table locking.') +49,68c54,76 +< depends_on('readline', when='@:3.2.0') +< depends_on('readline', when='+readline') +< depends_on('flex', type='build') +< depends_on('bison', type='build') +< depends_on('blas') +< depends_on('lapack') +< depends_on('cfitsio') +< depends_on('wcslib@4.20:+cfitsio') +< depends_on('fftw-api@3 precision=float,double', when='@3.4.0:') +< depends_on('fftw-api@3 precision=float,double', when='~fftpack') +< # SOFA dependency suffers the same problem in CMakeLists.txt as readline; +< # force a dependency when building unit tests +< depends_on('sofa-c', type='test') +< depends_on('hdf5', when='+hdf5') +< depends_on('adios2+mpi', when='+adios2') +< depends_on('mpi', when='+adios2') +< depends_on('python@2.6:', when='+python') +< depends_on('boost+python', when='+python') +< depends_on('py-numpy', when='+python') +< depends_on('gsl', when='@3.5.0:') +--- +> depends_on("readline", when="@:3.2.0") +> depends_on("readline", when="+readline") +> depends_on("flex", type="build") +> depends_on("bison", type="build") +> depends_on("blas") +> depends_on("lapack") +> depends_on("cfitsio") +> depends_on("wcslib@4.20:+cfitsio") +> depends_on("fftw@3.0.0: precision=float,double", when="@3.4.0:") +> depends_on("fftw@3.0.0: precision=float,double", when="~fftpack") +> depends_on("sofa-c", type="test") +> depends_on("hdf5", when="+hdf5") +> depends_on("adios2+mpi", when="+adios2") +> depends_on("mpi", when="+mpi") +> depends_on("python@2.6:", when="+python") +> depends_on("boost +python", when="+python") +> depends_on("boost +system +filesystem", when="+dysco") +> depends_on("py-numpy", when="+python") +> depends_on("gsl", when="+dysco") +> +> conflicts("~mpi", when="+adios2") +> conflicts("+tablelocking", when="+mpi") +> conflicts("~threads", when="+openmp") +71c79 +< args = ['-DCMAKE_Fortran_FLAGS=-fallow-argument-mismatch'] +--- +> args = [] +74,80c82,91 +< args.append(self.define_from_variant('ENABLE_SHARED', 'shared')) +< args.append(self.define_from_variant('USE_OPENMP', 'openmp')) +< args.append(self.define_from_variant('USE_READLINE', 'readline')) +< args.append(self.define_from_variant('USE_HDF5', 'hdf5')) +< args.append(self.define_from_variant('USE_ADIOS2', 'adios2')) +< args.append(self.define_from_variant('USE_MPI', 'adios2')) +< args.append(self.define_from_variant('ENABLE_TABLELOCKING', 'tablelocking')) +--- +> args.append(self.define_from_variant("BUILD_DYSCO", "dysco")) +> args.append(self.define_from_variant("ENABLE_TABLELOCKING", "tablelocking")) +> args.append(self.define_from_variant("ENABLE_SHARED", "shared")) +> args.append(self.define_from_variant("USE_THREADS", "threads")) +> args.append(self.define_from_variant("USE_OPENMP", "openmp")) +> args.append(self.define_from_variant("USE_READLINE", "readline")) +> args.append(self.define_from_variant("USE_HDF5", "hdf5")) +> args.append(self.define_from_variant("USE_ADIOS2", "adios2")) +> args.append(self.define_from_variant("USE_MPI", "mpi")) +> args.append("-DPORTABLE=ON") # let Spack determine arch build flags +87,90c98,100 +< if spec.satisfies('@3.4.0:'): +< if spec.satisfies('+fftpack'): +< args.append('-DBUILD_FFTPACK_DEPRECATED=YES') +< args.append(self.define('USE_FFTW3', True)) +--- +> if spec.satisfies("@3.4.0:"): +> if spec.satisfies("+fftpack"): +> args.append("-DBUILD_FFTPACK_DEPRECATED=YES") +92c102 +< args.append(self.define('USE_FFTW3', spec.satisfies('~fftpack'))) +--- +> args.append(self.define("USE_FFTW3", spec.satisfies("~fftpack"))) +95,98c105,108 +< if spec.satisfies('~python'): +< args.extend(['-DBUILD_PYTHON=NO', '-DBUILD_PYTHON3=NO']) +< elif spec.satisfies('^python@3.0.0:'): +< args.extend(['-DBUILD_PYTHON=NO', '-DBUILD_PYTHON3=YES']) +--- +> if spec.satisfies("~python"): +> args.extend(["-DBUILD_PYTHON=NO", "-DBUILD_PYTHON3=NO"]) +> elif spec.satisfies("^python@3.0.0:"): +> args.extend(["-DBUILD_PYTHON=NO", "-DBUILD_PYTHON3=YES"]) +100c110 +< args.extend(['-DBUILD_PYTHON=YES', '-DBUILD_PYTHON3=NO']) +--- +> args.extend(["-DBUILD_PYTHON=YES", "-DBUILD_PYTHON3=NO"]) +102c112 +< args.append('-DBUILD_TESTING=OFF') +--- +> args.append("-DBUILD_TESTING=OFF") +107c117 +< os.remove('cmake/FindHDF5.cmake') +--- +> os.remove("cmake/FindHDF5.cmake") +###### DIFF cpmd +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,6d4 +< # Check if manual_download is set properly +< import os +14,16c12 +< designed for ab-initio molecular dynamics. +< Move to new directory, download CPMD main archive and patch.to.XXXXs +< manually, and run Spack""" +--- +> designed for ab-initio molecular dynamics.""" +19,27c15,25 +< basedir = os.getcwd() +< url = "file://{0}/cpmd-v4.3.tar.gz".format(basedir) +< manual_download = False +< +< version("4.3", sha256="4f31ddf045f1ae5d6f25559d85ddbdab4d7a6200362849df833632976d095df4") +< +< variant('omp', description='Enables the use of OMP instructions', +< default=False) +< variant('mpi', description='Build with MPI support', default=False) +--- +> url = "https://github.com/CPMD-code/CPMD/archive/refs/tags/4.3.tar.gz" +> +> license("MIT") +> +> version("4.3", sha256="e0290f9da0d255f90a612e60662b14a97ca53003f89073c6af84fa7bc8739f65") +> +> depends_on("c", type="build") # generated +> depends_on("fortran", type="build") # generated +> +> variant("omp", description="Enables the use of OMP instructions", default=False) +> variant("mpi", description="Build with MPI support", default=False) +34,39d31 +< +< patch('file://{0}/patch.to.4612'.format(basedir), sha256='3b7d91e04c40418ad958069234ec7253fbf6c4be361a1d5cfd804774eeb44915', level=0, when='@4.3') +< patch('file://{0}/patch.to.4615'.format(basedir), sha256='5ec5790fb6ca64632bcc1b0f5b8f3423c54455766a0979ff4136624bbe8d49eb', level=0, when='@4.3') +< patch('file://{0}/patch.to.4616'.format(basedir), sha256='ac0bc215c4259f55da4dc59803fe636f797e241f8a01974e05730c9778ad44c4', level=0, when='@4.3') +< patch('file://{0}/patch.to.4621'.format(basedir), sha256='2d2bc7e37246032fc354f51da7dbdb5a219dd228867399931b0e94da1265d5ca', level=0, when='@4.3') +< patch('file://{0}/patch.to.4624'.format(basedir), sha256='0a19687528264bf91c9f50ffdc0b920a8511eecf5259b667c8c29350f9dabc53', level=0, when='@4.3') +###### DIFF dftd4 +1c1 +< # Copyright 2013-2022 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5c5 +< # Just grabbed the latest version from spack/develop +--- +> +13c13 +< url = "https://github.com/dftd4/dftd4/releases/download/v3.3.0/dftd4-3.3.0-source.tar.xz" +--- +> url = "https://github.com/dftd4/dftd4/releases/download/v3.5.0/dftd4-3.5.0-source.tar.xz" +16c16,18 +< maintainers = ["awvwgk"] +--- +> maintainers("awvwgk") +> +> license("LGPL-3.0-only") +19,23c21,29 +< version("3.4.0", "24fcb225cdd5c292ac26f7d3204ee3c4024174adb5272eeda9ae7bc57113ec8d") +< version("3.3.0", "408720b8545532d5240dd743c05d57b140af983192dad6d965b0d79393d0a9ef") +< version("3.2.0", "cef505e091469aa9b8f008ee1756545bb87b02760bb2c7ca54854e20ba8c590a") +< version("3.1.0", "b652aa7cbf8d087c91bcf80f2d5801459ecf89c5d4176ebb39e963ee740ed54b") +< version("3.0.0", "a7539d68d48d851bf37b79e37ea907c9da5eee908d0aa58a0a7dc15f04f8bc35") +--- +> version("3.5.0", sha256="d2bab992b5ef999fd13fec8eb1da9e9e8d94b8727a2e624d176086197a00a46f") +> version("3.4.0", sha256="24fcb225cdd5c292ac26f7d3204ee3c4024174adb5272eeda9ae7bc57113ec8d") +> version("3.3.0", sha256="408720b8545532d5240dd743c05d57b140af983192dad6d965b0d79393d0a9ef") +> version("3.2.0", sha256="cef505e091469aa9b8f008ee1756545bb87b02760bb2c7ca54854e20ba8c590a") +> version("3.1.0", sha256="b652aa7cbf8d087c91bcf80f2d5801459ecf89c5d4176ebb39e963ee740ed54b") +> version("3.0.0", sha256="a7539d68d48d851bf37b79e37ea907c9da5eee908d0aa58a0a7dc15f04f8bc35") +> +> depends_on("c", type="build") # generated +> depends_on("fortran", type="build") # generated +29d34 +< depends_on("cmake", type="build") +35a41,42 +> +> extends("python", when="+python") +###### DIFF everybeam +###### DIFF exabayes +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,40c5,9 +< # Differences for the 'exabayes' package +< # 11,12c11,12 +< # < homepage = "https://cme.h-its.org/exelixis/web/software/exabayes/index.html" +< # < url = "https://cme.h-its.org/exelixis/resource/download/software/exabayes-1.5.1.tar.gz" +< # --- +< # > homepage = "https://sco.h-its.org/exelixis/web/software/exabayes/" +< # > url = "https://sco.h-its.org/exelixis/resource/download/software/exabayes-1.5.tar.gz" +< # 14a15 +< # > version('1.5', sha256='e401f1b4645e67e8879d296807131d0ab79bba81a1cd5afea14d7c3838b095a2') +< # 25,33c26,29 +< # < +< # < # gcc 11.x has -std=gnu++17 by default, does not work to build exabayes, at least up to 1.5.1 +< # < def flag_handler(self, name, flags): +< # < if self.spec.satisfies('%gcc@11:') and name == 'cxxflags': +< # < flags.append('-std=gnu++14') +< # < return (flags, None, None) +< # < +< # < # configure updated to better determine if MPI compiler available +< # < patch('configure_mpi.patch', level=0, when='@1.5.1: +mpi', ) +< # --- +< # > conflicts('^intel-mpi', when='+mpi') +< # > conflicts('^intel-parallel-studio+mpi', when='+mpi') +< # > conflicts('^mvapich2', when='+mpi') +< # > conflicts('^spectrum-mpi', when='+mpi') +< # 42,51d37 +< # < +< # < # don't do anything autoreconf as configure +< # < # in exabayes is properly setup and +< # < # the autotools are not +< # < def autoreconf(self, spec, prefix): +< # < return +< # < +< # < +< # < +< # < +< # Contribute recipe and patch +--- +> +> +> from spack.package import * +> +> +43c12 +< particularly suitable for large-scale analyses on computer clusters.""" +--- +> particularly suitable for large-scale analyses on computer clusters.""" +45,46c14,15 +< homepage = "https://cme.h-its.org/exelixis/web/software/exabayes/index.html" +< url = "https://cme.h-its.org/exelixis/resource/download/software/exabayes-1.5.1.tar.gz" +--- +> homepage = "https://sco.h-its.org/exelixis/web/software/exabayes/" +> url = "https://sco.h-its.org/exelixis/resource/download/software/exabayes-1.5.tar.gz" +48c17 +< version('1.5.1', sha256='f75ce8d5cee4d241cadacd0f5f5612d783b9e9babff2a99c7e0c3819a94bbca9') +--- +> license("GPL-3.0-only") +50c19,20 +< variant('mpi', default=True, description='Enable MPI parallel support') +--- +> version("1.5.1", sha256="f75ce8d5cee4d241cadacd0f5f5612d783b9e9babff2a99c7e0c3819a94bbca9") +> version("1.5", sha256="e401f1b4645e67e8879d296807131d0ab79bba81a1cd5afea14d7c3838b095a2") +52c22,27 +< depends_on('mpi', when='+mpi') +--- +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> +> variant("mpi", default=True, description="Enable MPI parallel support") +> +> depends_on("mpi", when="+mpi") +57,67c32,37 +< conflicts('%gcc@:4.5.4, 7.1.0:', when='@:1.5.0') +< conflicts('%clang@:3.1') +< +< # gcc 11.x has -std=gnu++17 by default, does not work to build exabayes, at least up to 1.5.1 +< def flag_handler(self, name, flags): +< if self.spec.satisfies('%gcc@11:') and name == 'cxxflags': +< flags.append('-std=gnu++14') +< return (flags, None, None) +< +< # configure updated to better determine if MPI compiler available +< patch('configure_mpi.patch', level=0, when='@1.5.1: +mpi', ) +--- +> conflicts("%gcc@:4.5.4, 7.1.0:", when="@:1.5.0") +> conflicts("%clang@:3.1") +> conflicts("^intel-mpi", when="+mpi") +> conflicts("^intel-parallel-studio+mpi", when="+mpi") +> conflicts("^mvapich2", when="+mpi") +> conflicts("^spectrum-mpi", when="+mpi") +71,72c41,42 +< if '+mpi' in self.spec: +< args.append('--enable-mpi') +--- +> if "+mpi" in self.spec: +> args.append("--enable-mpi") +74c44 +< args.append('--disable-mpi') +--- +> args.append("--disable-mpi") +77,85c47,51 +< # don't do anything autoreconf as configure +< # in exabayes is properly setup and +< # the autotools are not +< def autoreconf(self, spec, prefix): +< return +< +< +< +< +--- +> def flag_handler(self, name, flags): +> if name.lower() == "cxxflags": +> # manual cites need for c++11 +> flags.append(self.compiler.cxx11_flag) +> return (flags, None, None) +###### DIFF feh +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,11d4 +< #pawsey additions +< # def flag_handler(self, name, flags): +< # if name == "cflags": +< # if self.spec.satisfies("%cce"): +< # iflags.append("-Wno-error=implicit-function-declaration") +< # return (flags, None, None) +< +27a21,22 +> license("MIT-feh") +> +32a28,29 +> depends_on("c", type="build") # generated +> +44,50d40 +< +< def flag_handler(self, name, flags): +< if name == "cflags": +< if self.spec.satisfies("%cce"): +< flags.append("-Wno-error=implicit-function-declaration") +< return (flags, None, None) +< +###### DIFF giant-squid +###### DIFF gromacs +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,10c5 +< # ======================================================================= +< # PAWSEY ADDITIONS +< # ======================================================================= +< # This is a version of the recipe coming from the later 0.21.0-dev Spack +< # version. It will allow us to have the latest versions. +< #variant lapack added +--- +> +34c29,32 +< # maintainers("danielahlin", "eirrgang", "junghans") +--- +> maintainers("mabraham", "eirrgang", "junghans") +> +> license("GPL-2.0-or-later", when="@:4.5") +> license("LGPL-2.1-or-later", when="@4.6:") +37a36,40 +> version("2024.2", sha256="802a7e335f2e895770f57b159e4ec368ebb0ff2ce6daccf706c6e8025c36852b") +> version("2024.1", sha256="937d8f12a36fffbf2af7add71adbb5aa5c5537892d46c9a76afbecab1aa0aac7") +> version("2024", sha256="04d226d52066a8bc3a42e00d6213de737b4ec292e26703065924ff01956801e2") +> version("2023.5", sha256="9cc491d3601a5fe0ec0de727e4432c34877f596fe8a463d4cf0f0f53fb34d08b") +> version("2023.4", sha256="e5d6c4d9e7ccacfaccb0888619bd21b5ea8911f82b410e68d6db5d40f695f231") +41a45 +> version("2022.6", sha256="75d277138475679dd3e334e384a71516570cde767310476687f2a5b72333ea41") +87a92,95 +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> depends_on("fortran", type="build") # generated +> +97c105,116 +< variant("cufftmp", default=False, when="+cuda+mpi", description="Enable Multi GPU FFT support") +--- +> variant( +> "cufftmp", +> default=False, +> when="@2022: +cuda+mpi", +> description="Enable multi-GPU FFT support with cuFFTMp", +> ) +> variant( +> "heffte", +> default=False, +> when="@2021: +sycl+mpi", +> description="Enable multi-GPU FFT support with HeFFTe", +> ) +99c118,124 +< variant("sycl", default=False, description="Enable SYCL support") +--- +> variant("sycl", default=False, when="@2021:", description="Enable SYCL support") +> variant( +> "intel-data-center-gpu-max", +> default=False, +> when="@2022: +sycl", +> description="Enable support for Intel Data Center GPU Max", +> ) +115a141,152 +> "nblib", +> default=True, +> when="@2021:", +> description="Build and install the NB-LIB C++ API for GROMACS", +> ) +> variant( +> "gmxapi", +> default=True, +> when="@2019:", +> description="Build and install the gmxlib python API for GROMACS", +> ) +> variant( +133c170 +< when="target=neoverse_v1", +--- +> when="target=neoverse_v1:,neoverse_v2:", +149,150d185 +< variant("lapack", default=False, description="Enables an external LAPACK library") +< variant("blas", default=False, description="Enables an external BLAS library") +158,167d192 +< conflicts( +< "~lapack", +< when="+cp2k", +< msg="GROMACS and CP2K should use the same lapack, please disable bundled lapack", +< ) +< conflicts( +< "~blas", +< when="+cp2k", +< msg="GROMACS and CP2K should use the same blas, please disable bundled blas", +< ) +171c196 +< "intel-oneapi-mkl@:2021.2", +--- +> "^intel-oneapi-mkl@:2021.2", +178,202c203,229 +< # Plumed 2.8.2 needs Gromacs 2022.5 2021.7, 2020.7, 2019.6 +< # Plumed 2.8.1 needs Gromacs 2022.3 2021.6, 2020.7, 2019.6 +< # Plumed 2.8.0 needs Gromacs 2021.4, 2020.6, 2019.6 +< # Plumed 2.7.6 needs Gromacs 2021.5, 2020.6, 2019.6 +< # Plumed 2.7.5 needs Gromacs 2021.5, 2020.6, 2019.6 +< # Plumed 2.7.4 needs Gromacs 2021.4, 2020.6, 2019.6 +< # Plumed 2.7.3 needs Gromacs 2021.4, 2020.6, 2019.6 +< # Plumed 2.7.2 needs Gromacs 2021, 2020.6, 2019.6 +< # Plumed 2.7.1 needs Gromacs 2021, 2020.5, 2019.6 +< # Plumed 2.7.0 needs Gromacs 2020.4, 2019.6 +< # Plumed 2.6.6 needs Gromacs 2020.4, 2019.6, 2018.8 +< # Plumed 2.6.5 needs Gromacs 2020.4, 2019.6, 2018.8 +< # Plumed 2.6.4 needs Gromacs 2020.4, 2019.6, 2018.8 +< # Plumed 2.6.3 needs Gromacs 2020.4, 2019.6, 2018.8 +< # Plumed 2.6.2 needs Gromacs 2020.4, 2019.6, 2018.8 +< # Plumed 2.6.1 needs Gromacs 2020.2, 2019.6, 2018.8 +< # Plumed 2.6.0 needs Gromacs 2019.4, 2018.8 +< # Plumed 2.5.7 needs Gromacs 2019.4, 2018.8, 2016.6 +< # Plumed 2.5.6 needs Gromacs 2019.4, 2018.8, 2016.6 +< # Plumed 2.5.5 needs Gromacs 2019.4, 2018.8, 2016.6 +< # Plumed 2.5.4 needs Gromacs 2019.4, 2018.8, 2016.6 +< # Plumed 2.5.3 needs Gromacs 2019.4, 2018.8, 2016.6 +< # Plumed 2.5.2 needs Gromacs 2019.2, 2018.6, 2016.6 +< # Plumed 2.5.1 needs Gromacs 2018.6, 2016.6 +< # Plumed 2.5.0 needs Gromacs 2018.4, 2016.5 +--- +> # Plumed 2.9.0 needs Gromacs 2023, 2022.5, 2021.7, 2020.7 +> # Plumed 2.8.3 needs Gromacs 2022.5, 2021.7, 2020.7, 2019.6 +> # Plumed 2.8.2 needs Gromacs 2022.5, 2021.7, 2020.7, 2019.6 +> # Plumed 2.8.1 needs Gromacs 2022.3, 2021.6, 2020.7, 2019.6 +> # Plumed 2.8.0 needs Gromacs 2021.4, 2020.6, 2019.6 +> # Plumed 2.7.6 needs Gromacs 2021.5, 2020.6, 2019.6 +> # Plumed 2.7.5 needs Gromacs 2021.5, 2020.6, 2019.6 +> # Plumed 2.7.4 needs Gromacs 2021.4, 2020.6, 2019.6 +> # Plumed 2.7.3 needs Gromacs 2021.4, 2020.6, 2019.6 +> # Plumed 2.7.2 needs Gromacs 2021, 2020.6, 2019.6 +> # Plumed 2.7.1 needs Gromacs 2021, 2020.5, 2019.6 +> # Plumed 2.7.0 needs Gromacs 2020.4, 2019.6 +> # Plumed 2.6.6 needs Gromacs 2020.4, 2019.6, 2018.8 +> # Plumed 2.6.5 needs Gromacs 2020.4, 2019.6, 2018.8 +> # Plumed 2.6.4 needs Gromacs 2020.4, 2019.6, 2018.8 +> # Plumed 2.6.3 needs Gromacs 2020.4, 2019.6, 2018.8 +> # Plumed 2.6.2 needs Gromacs 2020.4, 2019.6, 2018.8 +> # Plumed 2.6.1 needs Gromacs 2020.2, 2019.6, 2018.8 +> # Plumed 2.6.0 needs Gromacs 2019.4, 2018.8 +> # Plumed 2.5.7 needs Gromacs 2019.4, 2018.8, 2016.6 +> # Plumed 2.5.6 needs Gromacs 2019.4, 2018.8, 2016.6 +> # Plumed 2.5.5 needs Gromacs 2019.4, 2018.8, 2016.6 +> # Plumed 2.5.4 needs Gromacs 2019.4, 2018.8, 2016.6 +> # Plumed 2.5.3 needs Gromacs 2019.4, 2018.8, 2016.6 +> # Plumed 2.5.2 needs Gromacs 2019.2, 2018.6, 2016.6 +> # Plumed 2.5.1 needs Gromacs 2018.6, 2016.6 +> # Plumed 2.5.0 needs Gromacs 2018.4, 2016.5 +205c232 +< # https://github.com/plumed/plumed2/tree/v2.7.1/patches +--- +> # https://github.com/plumed/plumed2/tree/v2.9.0/patches +206a234,238 +> +> # Versions without minor release number, such as `2023` and `2021`, +> # require exact specifcation using `@=`, starting from Spack v0.20.0, +> # see https://github.com/spack/spack/releases/tag/v0.20.0 +> +208,209c240,241 +< "2023": "2.9.0", +< "2022.5": "2.8.2", +--- +> "=2023": "2.9.0", +> "2022.5": "2.8.2:2.9.0", +211c243 +< "2021.7": "2.8.2", +--- +> "2021.7": "2.8.2:2.9.0", +215,216c247,248 +< "2021": "2.7.1:2.7.2", +< "2020.7": "2.8.1:2.8.2", +--- +> "=2021": "2.7.1:2.7.2", +> "2020.7": "2.8.1:2.9.0", +221c253 +< "2019.6": "2.6.1:2.8.2", +--- +> "2019.6": "2.6.1:2.8.3", +257a290,291 +> depends_on("pkgconfig", type="build") +> +260,261c294,295 +< depends_on("lapack", when="+lapack") +< depends_on("blas", when="+blas") +--- +> depends_on("lapack") +> depends_on("blas") +269d302 +< depends_on("dbcsr", when="+cp2k") +271a305 +> depends_on("heffte", when="+heffte") +273,279c307,318 +< # requires( +< # "%intel", +< # "%oneapi", +< # policy="one_of", +< # when="+intel_provided_gcc", +< # msg="Only attempt to find gcc libs for Intel compiler if Intel compiler is used.", +< # ) +--- +> requires( +> "%intel", +> "%oneapi", +> policy="one_of", +> when="+intel_provided_gcc", +> msg="Only attempt to find gcc libs for Intel compiler if Intel compiler is used.", +> ) +> +> # If the Intel suite is used for Lapack, it must be used for fftw and vice-versa +> for _intel_pkg in INTEL_MATH_LIBRARIES: +> requires(f"^[virtuals=fftw-api] {_intel_pkg}", when=f"^[virtuals=lapack] {_intel_pkg}") +> requires(f"^[virtuals=lapack] {_intel_pkg}", when=f"^[virtuals=fftw-api] {_intel_pkg}") +282a322,327 +> # 2021.2 will always try to build tests (see https://gromacs.bioexcel.eu/t/compilation-failure-for-gromacs-2021-1-and-2021-2-with-cmake-3-20-2/2129) +> patch( +> "https://gitlab.com/gromacs/gromacs/-/commit/10262892e11a87fda0f59e633c89ed5ab1100509.diff", +> sha256="2c30d00404b76421c13866cc42afa5e63276f7926c862838751b158df8727b1b", +> when="@2021.1:2021.2", +> ) +504,518c549,555 +< if "+lapack" in self.spec: +< options.append("-DGMX_EXTERNAL_LAPACK:BOOL=ON") +< if self.spec["lapack"].libs: +< options.append( +< "-DGMX_LAPACK_USER={0}".format(self.spec["lapack"].libs.joined(";")) +< ) +< else: +< options.append("-DGMX_EXTERNAL_LAPACK:BOOL=OFF") +< +< if "+blas" in self.spec: +< options.append("-DGMX_EXTERNAL_BLAS:BOOL=ON") +< if self.spec["blas"].libs: +< options.append("-DGMX_BLAS_USER={0}".format(self.spec["blas"].libs.joined(";"))) +< else: +< options.append("-DGMX_EXTERNAL_BLAS:BOOL=OFF") +--- +> options.append("-DGMX_EXTERNAL_LAPACK:BOOL=ON") +> if self.spec["lapack"].libs: +> options.append("-DGMX_LAPACK_USER={0}".format(self.spec["lapack"].libs.joined(";"))) +> +> options.append("-DGMX_EXTERNAL_BLAS:BOOL=ON") +> if self.spec["blas"].libs: +> options.append("-DGMX_BLAS_USER={0}".format(self.spec["blas"].libs.joined(";"))) +530a568,580 +> if "+heffte" in self.spec: +> options.append("-DGMX_USE_HEFFTE=on") +> options.append(f'-DHeffte_ROOT={self.spec["heffte"].prefix}') +> +> if "+intel-data-center-gpu-max" in self.spec: +> options.append("-DGMX_GPU_NB_CLUSTER_SIZE=8") +> options.append("-DGMX_GPU_NB_NUM_CLUSTER_PER_CELL_X=1") +> +> if "~nblib" in self.spec: +> options.append("-DGMX_INSTALL_NBLIB_API=OFF") +> if "~gmxapi" in self.spec: +> options.append("-DGMXAPI=OFF") +> +533c583,586 +< if target >= "zen2": +--- +> if target >= "zen4": +> # AMD Family 17h (EPYC Genoa) +> options.append("-DGMX_SIMD=AVX_512") +> elif target >= "zen2": +611c664 +< if "^mkl" in self.spec: +--- +> if self.spec["lapack"].name in INTEL_MATH_LIBRARIES: +615c668 +< if not self.spec["mkl"].satisfies("@2023:"): +--- +> if self.spec.satisfies("@:2022"): +###### DIFF hdf +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5c5 +< #PAWSEY Additions to handle cce compiler in flag_handler +--- +> +27a28,31 +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> depends_on("fortran", type="build") # generated +> +135c139 +< if "+external-xdr" in self.spec and self.spec["rpc"].name != "libc": +--- +> if "+external-xdr" in self.spec and self.spec["rpc"].name == "libtirpc": +149c153,157 +< if self.spec.satisfies("@:4.2.15 %apple-clang") or self.spec.satisfies("%clang@16:") or self.spec.satisfies("%cce"): +--- +> if ( +> self.spec.satisfies("@:4.2.15 %apple-clang") +> or self.spec.satisfies("%clang@16:") +> or self.spec.satisfies("%oneapi") +> ): +152c160 +< if self.spec.satisfies("%clang@16:") or self.spec.satisfies("%cce"): +--- +> if self.spec.satisfies("%clang@16:") or self.spec.satisfies("%apple-clang@15:"): +177c185 +< elif self.spec["rpc"].name != "libc": +--- +> elif self.spec["rpc"].name == "libtirpc": +213c221 +< self.cache_extra_test_sources(self.extra_install_tests) +--- +> cache_extra_test_sources(self, self.extra_install_tests) +###### DIFF healpix-cxx +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,22c5 +< # Differences for the 'healpix-cxx' package +< # 6c6 +< # < from spack.package import * +< # --- +< # > from spack import * +< # 20d19 +< # < patch('cfitsio_version_check.patch', when="@3.50:") +< # 21a21,29 +< # > def patch(self): +< # > spec = self.spec +< # > configure_fix = FileFilter('configure') +< # > # Link libsharp static libs +< # > configure_fix.filter( +< # > r'^SHARP_LIBS=.*$', +< # > 'SHARP_LIBS="-L{0} -lsharp -lc_utils -lfftpack -lm"' +< # > .format(spec['libsharp'].prefix.lib) +< # > ) +< # Contribute patch +--- +> +31c14,16 +< url = "https://ayera.dl.sourceforge.net/project/healpix/Healpix_3.50/healpix_cxx-3.50.0.tar.gz" +--- +> url = "https://ayera.dl.sourceforge.net/project/healpix/Healpix_3.50/healpix_cxx-3.50.0.tar.gz" +> +> license("GPL-2.0-or-later") +33c18 +< version('3.50.0', sha256='6538ee160423e8a0c0f92cf2b2001e1a2afd9567d026a86ff6e2287c1580cb4c') +--- +> version("3.50.0", sha256="6538ee160423e8a0c0f92cf2b2001e1a2afd9567d026a86ff6e2287c1580cb4c") +35,37c20,21 +< depends_on('cfitsio') +< depends_on('libsharp', type='build') +< patch('cfitsio_version_check.patch', when="@3.50:") +--- +> depends_on("cfitsio") +> depends_on("libsharp", type="build") +38a23,32 +> def patch(self): +> spec = self.spec +> configure_fix = FileFilter("configure") +> # Link libsharp static libs +> configure_fix.filter( +> r"^SHARP_LIBS=.*$", +> 'SHARP_LIBS="-L{0} -lsharp -lc_utils -lfftpack -lm"'.format( +> spec["libsharp"].prefix.lib +> ), +> ) +###### DIFF hyperbeam +###### DIFF idg +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5c5 +< # Contribute back the recipe +--- +> +9c9 +< class Idg(CMakePackage, CudaPackage): +--- +> class Idg(CMakePackage): +11,12c11,12 +< Image Domain Gridding (IDG) is a fast method for convolutional resampling (gridding/degridding) +< of radio astronomical data (visibilities). Direction-dependent effects (DDEs) +--- +> Image Domain Gridding (IDG) is a fast method for convolutional resampling (gridding/degridding) +> of radio astronomical data (visibilities). Direction-dependent effects (DDEs) +17c17,29 +< git = "https://gitlab.com/astron-idg/idg.git" +--- +> git = "https://git.astron.nl/RD/idg.git" +> url = "https://git.astron.nl/RD/idg/-/archive/1.2.0/idg-1.2.0.tar.gz" +> +> maintainers("pelahi") +> +> license("GPL-3.0-or-later") +> +> version("1.2.0", commit="ccf8951283c12547326800adae99440c70177449") +> version("1.0.0", commit="3322756fb8b6e3bb1fe5293f3e07e40623ff8486") +> version("0.8.1", commit="a09f3c85094c592f9304fff4c31e920c7592c3c3") +> +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +19,34c31,33 +< version("1.2.0", tag="1.2.0") +< version("1.1.0", tag="1.1.0") +< version("1.0.0", tag="1.0.0") +< version("0.7", tag="0.7") +< +< depends_on('boost') +< depends_on('fftw-api@3') +< depends_on('blas') +< +< +< def cmake_args(self): +< args = [] +< if '+cuda' in self.spec: +< args.append("-DBUILD_LIB_CUDA=ON") +< args.append(f"-DCUDA_ROOT_DIR={self.spec['cuda'].prefix}") +< return args +--- +> depends_on("boost") +> depends_on("fftw-api@3") +> depends_on("blas") +###### DIFF kokkos +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5d4 +< #Pawsey additions to handle ROCM paths +8c7 +< from llnl.util import lang, tty +--- +> import llnl.util.lang as lang +13d11 +< +26c24,26 +< maintainers("janciesko", "crtrott") +--- +> maintainers("cedricchevalier19", "nmm0", "lucbv") +> +> license("Apache-2.0 WITH LLVM-exception") +29a30,33 +> version("4.3.01", sha256="5998b7c732664d6b5e219ccc445cd3077f0e3968b4be480c29cd194b4f45ec70") +> version("4.3.00", sha256="53cf30d3b44dade51d48efefdaee7a6cf109a091b702a443a2eda63992e5fe0d") +> version("4.2.01", sha256="cbabbabba021d00923fb357d2e1b905dda3838bd03c885a6752062fe03c67964") +> version("4.2.00", sha256="ac08765848a0a6ac584a0a46cd12803f66dd2a2c2db99bb17c06ffc589bf5be8") +48a53,54 +> depends_on("cxx", type="build") # Kokkos requires a C++ compiler +> +49a56 +> conflicts("cmake@3.28", when="@:4.2.01 +cuda") +65d71 +< conflicts("@:3.5 +sycl", when="%dpcpp@2022:") +159a166,167 +> "gfx940": "amd_gfx940", +> "gfx942": "amd_gfx942", +193a202,203 +> depends_on("intel-oneapi-dpl", when="+sycl") +> depends_on("rocthrust", when="@4.3: +rocm") +238a249,255 +> patch("sycl_bhalft_test.patch", when="@4.2.00 +sycl") +> # adds amd_gfx940 support to Kokkos 4.2.00 (upstreamed in https://github.com/kokkos/kokkos/pull/6671) +> patch( +> "https://github.com/rbberger/kokkos/commit/293319c5844f4d8eea51eb9cd1457115a5016d3f.patch?full_index=1", +> sha256="145619e87dbf26b66ea23e76906576e2a854a3b09f2a2dd70363e61419fa6a6e", +> when="@4.2.00", +> ) +338a356 +> options.append(self.define("Kokkos_ENABLE_ROCTHRUST", True)) +346a365,375 +> # Kokkos 4.2.00+ changed the default to Kokkos_ENABLE_IMPL_CUDA_MALLOC_ASYNC=on +> # which breaks GPU-aware with Cray-MPICH +> # See https://github.com/kokkos/kokkos/pull/6402 +> # TODO: disable this once Cray-MPICH is fixed +> if ( +> self.spec.satisfies("@4.2.00:") +> and "mpi" in self.spec +> and self.spec["mpi"].name == "cray-mpich" +> ): +> options.append(self.define("Kokkos_ENABLE_IMPL_CUDA_MALLOC_ASYNC", False)) +> +352,365d380 +< # TODO: Replace this method and its 'get' use for cmake path with +< # join_path(self.spec['cmake'].prefix.bin, 'cmake') once stand-alone +< # tests can access build dependencies through self.spec['cmake']. +< def cmake_bin(self, set=True): +< """(Hack) Set/get cmake dependency path.""" +< filepath = join_path(self.install_test_root, "cmake_bin_path.txt") +< if set: +< with open(filepath, "w") as out_file: +< cmake_bin = join_path(self.spec["cmake"].prefix.bin, "cmake") +< out_file.write("{0}\n".format(cmake_bin)) +< elif os.path.isfile(filepath): +< with open(filepath, "r") as in_file: +< return in_file.read().strip() +< +378c393 +< join_path(self.install_test_root, cmake_out_path) +--- +> join_path(install_test_root(self), cmake_out_path) +383,394c398 +< self.cache_extra_test_sources(cmake_out_path) +< self.cmake_bin(set=True) +< +< def build_tests(self, cmake_path): +< """Build test.""" +< cmake_bin = self.cmake_bin(set=False) +< +< if not cmake_bin: +< tty.msg("Skipping kokkos test: cmake_bin_path.txt not found") +< return +< +< cmake_args = [cmake_path, "-DEXECUTABLE_OUTPUT_PATH=" + cmake_path] +--- +> cache_extra_test_sources(self, cmake_out_path) +396,411c400,401 +< if not self.run_test(cmake_bin, options=cmake_args, purpose="Generate the Makefile"): +< tty.warn("Skipping kokkos test: failed to generate Makefile") +< return +< +< if not self.run_test("make", purpose="Build test software"): +< tty.warn("Skipping kokkos test: failed to build test") +< +< def run_tests(self, cmake_path): +< """Run test.""" +< if not self.run_test( +< "make", options=[cmake_path, "test"], purpose="Checking ability to execute." +< ): +< tty.warn("Failed to run kokkos test") +< +< def test(self): +< # Skip if unsupported version +--- +> def test_run(self): +> """Test if kokkos builds and runs""" +417,418c407,410 +< tty.warn("Skipping smoke tests: {0} is missing".format(cmake_path)) +< return +--- +> raise SkipTest(f"{cmake_path} is missing") +> +> cmake = self.spec["cmake"].command +> cmake(cmake_path, "-DEXECUTABLE_OUTPUT_PATH=" + cmake_path) +420,421c412,414 +< self.build_tests(cmake_path) +< self.run_tests(cmake_path) +--- +> make = which("make") +> make() +> make(cmake_path, "test") +432c425 +< "hsa-rocr-dev": rocm_prefix.hsa, +--- +> "hsa-rocr-dev": rocm_prefix.hsa, +459c452 +< ) +--- +> ) +468c461 +< self.set_variables(env) +--- +> self.set_variables(env) +###### DIFF lammps +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,10d4 +< +< # PAWSEY MODIFICATIONS +< # added 20230802.3 version +< # Had to comment all versions except the last one vecause of weird conflicts due to maybe the older version of spack we are using +< # Had to add a ROCM LLVM LIB path to the LD_LIBRARY_PATH as it is not added by the compiler in the RPATH somehow. +< +12,13c6 +< +< import archspec +--- +> import os +18c11 +< class Lammps(CMakePackage, CudaPackage, ROCmPackage): +--- +> class Lammps(CMakePackage, CudaPackage, ROCmPackage, PythonExtension): +29c22,24 +< # maintainers("rbberger") +--- +> maintainers("rbberger") +> +> license("GPL-2.0-only") +36a32,42 +> version("20240627", sha256="2174a99d266279823a8c57629ee1c21ec357816aefd85f964d9f859fe9222aa5") +> version("20240417", sha256="158b288725c251fd8b30dbcf61749e0d6a042807da92af865a7d3c413efdd8ea") +> version( +> "20240207.1", sha256="3ba62c2a1ed463fceedf313a1c3ea2997994aa102379a8d35b525ea424f56776" +> ) +> version( +> "20240207", +> sha256="d518f32de4eb2681f2543be63926411e72072dd7d67c1670c090b5baabed98ac", +> deprecated=True, +> ) +> version("20231121", sha256="704d8a990874a425bcdfe0245faf13d712231ba23f014a3ebc27bc14398856f1") +39c45 +< sha256="2713cd876b2e590725ab4c2b6506313cae9538e6f34c251ebc3215376fb60f98", +--- +> sha256="6666e28cb90d3ff01cbbda6c81bdb85cf436bbb41604a87f2ab2fa559caa8510", +42a49,58 +> "20230802.2", +> sha256="3bcecabc9cad08d0a4e4d989b52d29c58505f7ead8ebacf43c9db8d9fd3d564a", +> deprecated=True, +> ) +> version( +> "20230802.1", +> sha256="0e5568485e5ee080412dba44a1b7a93f864f1b5c75121f11d528854269953ed0", +> deprecated=True, +> ) +> version( +44a61,369 +> deprecated=True, +> ) +> version( +> "20230615", +> sha256="8470ed7b26ccd3728f4b44a7f1c520f1af23a648af685fd30b42b840fdfae2ff", +> deprecated=True, +> ) +> version( +> "20230328", +> sha256="14f5a5c37e4b46466e90d8b35476800e66acee74999f7358f4c12dfe662bfd99", +> deprecated=True, +> ) +> version( +> "20230208", +> sha256="60221242145da4479e5b207d9a0eed90af4168d7a297b4dc8c0e7f2b3215602e", +> deprecated=True, +> ) +> version( +> "20221222", +> sha256="75372ee7ef982767fc4ed4dc95e20ddca8247419adeb0c1276c40e43d1eab955", +> deprecated=True, +> ) +> version( +> "20221103", +> sha256="d28517b84b157d4e46a1a64ed787b4662d8f2f5ade3f5a04bb0caed068f32f7e", +> deprecated=True, +> ) +> version( +> "20220915", +> sha256="392b8d35fc7919b0efaf8b389259a9b795a817e58e75e380467c63d03a0dab75", +> deprecated=True, +> ) +> version( +> "20220803", +> sha256="f37cb0b35c1682ffceae5826aadce47278aa7003099a1655fcea43acd7d37926", +> deprecated=True, +> ) +> version( +> "20220623.4", sha256="42541b4dbd0d339d16ddb377e76d192bc3d1d5712fdf9e2cdc838fc980d0a0cf" +> ) +> version( +> "20220623.3", +> sha256="8a276a01b50d37eecfe6eb36f420f354cde51936d20aca7944dea60d3c098c89", +> deprecated=True, +> ) +> version( +> "20220623.2", +> sha256="8a560213e83919623525c4a7c4b5f0eda35cdf3b0c0e6548fd891379e04ca9e6", +> deprecated=True, +> ) +> version( +> "20220623.1", +> sha256="58e3b2b984f8935bb0db5631e143be2826c45ffd48844f7c394f36624a3e17a2", +> deprecated=True, +> ) +> version( +> "20220623", +> sha256="d27ede095c9f00cd13a26f967a723d07cf8f4df65c700ed73573577bc173d5ce", +> deprecated=True, +> ) +> version( +> "20220602", +> sha256="3e8f54453e53b3b387a68317277f832b8cf64a981e64b21e98bb37ea36ac4a60", +> deprecated=True, +> ) +> version( +> "20220504", +> sha256="fe05bae8090fd0177b3c1b987cd32a9cb7cd05d790828ba954c764eb52e10b52", +> deprecated=True, +> ) +> version( +> "20220324", +> sha256="d791cc93eedfc345fdf87bfa5b6f7e17e461f86ba197f9e9c3d477ce8657a7ef", +> deprecated=True, +> ) +> version( +> "20220217", +> sha256="e5bd2bf325835fa98d1b95f0667c83076580916027df5b8109d5470d1b97da98", +> deprecated=True, +> ) +> version( +> "20220107", +> sha256="fbf6c6814968ae0d772d7b6783079ff4f249a8faeceb39992c344969e9f1edbb", +> deprecated=True, +> ) +> version( +> "20211214", +> sha256="9f7b1ee2394678c1a6baa2c158a62345680a952eee251783e3c246b3f12db4c9", +> deprecated=True, +> ) +> version( +> "20211027", +> sha256="c06f682fcf9d5921ca90c857a104e90fba0fe65decaac9732745e4da49281938", +> deprecated=True, +> ) +> version( +> "20210929.3", sha256="e4c274f0dc5fdedc43f2b365156653d1105197a116ff2bafe893523cdb22532e" +> ) +> version( +> "20210929.2", +> sha256="9318ca816cde16a9a4174bf22a1966f5f2155cb32c0ad5a6757633276411fb36", +> deprecated=True, +> ) +> version( +> "20210929.1", +> sha256="5000b422c9c245b92df63507de5aa2ea4af345ea1f00180167aaa084b711c27c", +> deprecated=True, +> ) +> version( +> "20210929", +> sha256="2dff656cb21fd9a6d46c818741c99d400cfb1b12102604844663b655fb2f893d", +> deprecated=True, +> ) +> version( +> "20210920", +> sha256="e3eba96933c1dd3177143c7ac837cae69faceba196948fbad2970425db414d8c", +> deprecated=True, +> ) +> version( +> "20210831", +> sha256="532c42576a79d72682deaf43225ca773ed9f9e35deb484a82f91905b6cba23ec", +> deprecated=True, +> ) +> version( +> "20210730", +> sha256="c5e998c8282a835d2bcba4fceffe3cecdf9aed9bdf79fa9c945af573e632f6e7", +> deprecated=True, +> ) +> version( +> "20210728", +> sha256="6b844d2c3f7170a59d36fbf761483aa0c63d95eda254d00fe4d10542403abe36", +> deprecated=True, +> ) +> version( +> "20210702", +> sha256="4fdd8ca2dbde8809c0048716650b73ae1f840e22ebe24b25f6f7a499377fea57", +> deprecated=True, +> ) +> version( +> "20210527", +> sha256="f9f29970941f406d5c250de52a4cd07e5a4e44ae3b5ffed46edd019d998b8c33", +> deprecated=True, +> ) +> version( +> "20210514", +> sha256="74d9c4386f2181b15a024314c42b7a0b0aaefd3b4b947aeca00fe07e5b2f3317", +> deprecated=True, +> ) +> version( +> "20210408", +> sha256="1645147b7777de4f616b8232edf0b597868084f969c777fa0a757949c3f71f56", +> deprecated=True, +> ) +> version( +> "20210310", +> sha256="25708378dbeccf794bc5045aceb84380bf4a3ca03fc8e5d150a26ca88d371474", +> deprecated=True, +> ) +> version( +> "20210210", +> sha256="2c5ba2c7935ad559ca94ee826e8727e65b49ef4582eb856534fffba70e44101a", +> deprecated=True, +> ) +> version("20201029", sha256="759705e16c1fedd6aa6e07d028cc0c78d73c76b76736668420946a74050c3726") +> version( +> "20200721", +> sha256="845bfeddb7b667799a1a5dbc166b397d714c3d2720316604a979d3465b4190a9", +> deprecated=True, +> ) +> version( +> "20200630", +> sha256="413cbfabcc1541a339c7a4ab5693fbeb768f46bb1250640ba94686c6e90922fc", +> deprecated=True, +> ) +> version( +> "20200505", +> sha256="c49d77fd602d28ebd8cf10f7359b9fc4d14668c72039028ed7792453d416de73", +> deprecated=True, +> ) +> version("20200303", sha256="a1a2e3e763ef5baecea258732518d75775639db26e60af1634ab385ed89224d1") +> version( +> "20200227", +> sha256="1aabcf38bc72285797c710b648e906151a912c36b634a9c88ac383aacf85516e", +> deprecated=True, +> ) +> version( +> "20200218", +> sha256="73bcf146660804ced954f6a0a8dce937482677778d46018ca5a688127bf97211", +> deprecated=True, +> ) +> version( +> "20200204", +> sha256="3bf3de546ede34ffcd89f1fca5fd66aa78c662e7c8a76e30ce593e44a00d23ce", +> deprecated=True, +> ) +> version( +> "20200124", +> sha256="443829560d760690e1ae21ad54922f56f34f640a81e817f5cc65d2a4af3a6a5d", +> deprecated=True, +> ) +> version( +> "20200109", +> sha256="f2fd24f6c10837801f490913d73f672ec7c6becda08465d7e834a2bfbe3d7cd6", +> deprecated=True, +> ) +> version( +> "20191120", +> sha256="fd146bf517a6c2fb8a69ecb3749dc352eef94414739cd7855c668c690af85d27", +> deprecated=True, +> ) +> version( +> "20191030", +> sha256="5279567f731386ffdb87800b448903a63de2591064e13b4d5216acae25b7e541", +> deprecated=True, +> ) +> version( +> "20190919", +> sha256="0f693203afe86bc70c084c55f29330bdeea3e3ad6791f81c727f7a34a7f6caf3", +> deprecated=True, +> ) +> version( +> "20190807", +> sha256="895d71914057e070fdf0ae5ccf9d6552b932355056690bdb8e86d96549218cc0", +> deprecated=True, +> ) +> version( +> "20190605", +> sha256="c7b35090aef7b114d2b47a7298c1e8237dd811da87995c997bf7639cca743152", +> deprecated=True, +> ) +> version( +> "20181212", +> sha256="ccc5d2c21c4b62ce4afe7b3a0fe2f37b83e5a5e43819b7c2e2e255cce2ce0f24", +> deprecated=True, +> ) +> version( +> "20181207", +> sha256="d92104d008a7f1d0b6071011decc5c6dc8b936a3418b20bd34b055371302557f", +> deprecated=True, +> ) +> version( +> "20181127", +> sha256="c076b633eda5506f895de4c73103df8b995d9fec01be82c67c7608efcc345179", +> deprecated=True, +> ) +> version( +> "20181115", +> sha256="3bc9c166e465cac625c4a8e4060e597003f4619dadd57d3bc8d25bcd930f286e", +> deprecated=True, +> ) +> version( +> "20181109", +> sha256="dd30fe492fa147fb6f39bfcc79d8c786b9689f7fbe86d56de58cace53b6198c9", +> deprecated=True, +> ) +> version( +> "20181024", +> sha256="a171dff5aff7aaa2c9606ab2abc9260f2b685a5c7f6d650e7f2b59cf4aa149d6", +> deprecated=True, +> ) +> version( +> "20181010", +> sha256="bda762ee2d2dcefe0b4e36fb689c6b9f7ede49324444ccde6c59cba727b4b02d", +> deprecated=True, +> ) +> version( +> "20180918", +> sha256="02f143d518d8647b77137adc527faa9725c7afbc538d670253169e2a9b3fa0e6", +> deprecated=True, +> ) +> version( +> "20180905", +> sha256="ee0df649e33a9bf4fe62e062452978731548a56b7487e8e1ce9403676217958d", +> deprecated=True, +> ) +> version( +> "20180831", +> sha256="6c604b3ebd0cef1a5b18730d2c2eb1e659b2db65c5b1ae6240b8a0b150e4dff3", +> deprecated=True, +> ) +> version( +> "20180822", +> sha256="9f8942ca3f8e81377ae88ccfd075da4e27d0dd677526085e1a807777c8324074", +> deprecated=True, +> ) +> version( +> "20180629", +> sha256="1acf7d9b37b99f17563cd4c8bb00ec57bb2e29eb77c0603fd6871898de74763b", +> deprecated=True, +> ) +> version( +> "20180316", +> sha256="a81f88c93e417ecb87cd5f5464c9a2570384a48ff13764051c5e846c3d1258c1", +> deprecated=True, +> ) +> version( +> "20180222", +> sha256="374254d5131b7118b9ab0f0e27d20c3d13d96b03ed2b5224057f0c1065828694", +> deprecated=True, +> ) +> version( +> "20170922", +> sha256="f0bf6eb530d528f4d261d0a261e5616cbb6e990156808b721e73234e463849d3", +> deprecated=True, +> ) +> version( +> "20170901", +> sha256="5d88d4e92f4e0bb57c8ab30e0d20de556830af820223778b9967bec2184efd46", +> deprecated=True, +46,354c371,380 +< #version( +< # "20230615", +< # sha256="8470ed7b26ccd3728f4b44a7f1c520f1af23a648af685fd30b42b840fdfae2ff", +< # +< #) +< #version( +< # "20230328", +< # sha256="14f5a5c37e4b46466e90d8b35476800e66acee74999f7358f4c12dfe662bfd99", +< # +< #) +< #version( +< # "20230208", +< # sha256="60221242145da4479e5b207d9a0eed90af4168d7a297b4dc8c0e7f2b3215602e", +< # +< #) +< #version( +< # "20221222", +< # sha256="75372ee7ef982767fc4ed4dc95e20ddca8247419adeb0c1276c40e43d1eab955", +< # +< #) +< #version( +< # "20221103", +< # sha256="d28517b84b157d4e46a1a64ed787b4662d8f2f5ade3f5a04bb0caed068f32f7e", +< # +< #) +< #version( +< # "20220915", +< # sha256="392b8d35fc7919b0efaf8b389259a9b795a817e58e75e380467c63d03a0dab75", +< # +< #) +< #version( +< # "20220803", +< # sha256="f37cb0b35c1682ffceae5826aadce47278aa7003099a1655fcea43acd7d37926", +< # +< #) +< ##version( +< ## "20220623.4", sha256="42541b4dbd0d339d16ddb377e76d192bc3d1d5712fdf9e2cdc838fc980d0a0cf", +< ## +< ##) +< #version( +< # "20220623.3", +< # sha256="8a276a01b50d37eecfe6eb36f420f354cde51936d20aca7944dea60d3c098c89", +< # +< #) +< #version( +< # "20220623.2", +< # sha256="8a560213e83919623525c4a7c4b5f0eda35cdf3b0c0e6548fd891379e04ca9e6", +< # +< #) +< #version( +< # "20220623.1", +< # sha256="58e3b2b984f8935bb0db5631e143be2826c45ffd48844f7c394f36624a3e17a2", +< # +< #) +< #version( +< # "20220623", +< # sha256="d27ede095c9f00cd13a26f967a723d07cf8f4df65c700ed73573577bc173d5ce", +< # +< #) +< #version( +< # "20220602", +< # sha256="3e8f54453e53b3b387a68317277f832b8cf64a981e64b21e98bb37ea36ac4a60", +< # +< #) +< #version( +< # "20220504", +< # sha256="fe05bae8090fd0177b3c1b987cd32a9cb7cd05d790828ba954c764eb52e10b52", +< # +< #) +< #version( +< # "20220324", +< # sha256="d791cc93eedfc345fdf87bfa5b6f7e17e461f86ba197f9e9c3d477ce8657a7ef", +< # +< #) +< #version( +< # "20220217", +< # sha256="e5bd2bf325835fa98d1b95f0667c83076580916027df5b8109d5470d1b97da98", +< # +< #) +< #version( +< # "20220107", +< # sha256="fbf6c6814968ae0d772d7b6783079ff4f249a8faeceb39992c344969e9f1edbb", +< # +< #) +< #version( +< # "20211214", +< # sha256="9f7b1ee2394678c1a6baa2c158a62345680a952eee251783e3c246b3f12db4c9", +< # +< #) +< #version( +< # "20211027", +< # sha256="c06f682fcf9d5921ca90c857a104e90fba0fe65decaac9732745e4da49281938", +< # +< #) +< #version( +< # "20210929.3", sha256="e4c274f0dc5fdedc43f2b365156653d1105197a116ff2bafe893523cdb22532e" +< #) +< #version( +< # "20210929.2", +< # sha256="9318ca816cde16a9a4174bf22a1966f5f2155cb32c0ad5a6757633276411fb36", +< # +< #) +< #version( +< # "20210929.1", +< # sha256="5000b422c9c245b92df63507de5aa2ea4af345ea1f00180167aaa084b711c27c", +< # +< #) +< #version( +< # "20210929", +< # sha256="2dff656cb21fd9a6d46c818741c99d400cfb1b12102604844663b655fb2f893d", +< # +< #) +< #version( +< # "20210920", +< # sha256="e3eba96933c1dd3177143c7ac837cae69faceba196948fbad2970425db414d8c", +< # +< #) +< #version( +< # "20210831", +< # sha256="532c42576a79d72682deaf43225ca773ed9f9e35deb484a82f91905b6cba23ec", +< # +< #) +< #version( +< # "20210730", +< # sha256="c5e998c8282a835d2bcba4fceffe3cecdf9aed9bdf79fa9c945af573e632f6e7", +< # +< #) +< #version( +< # "20210728", +< # sha256="6b844d2c3f7170a59d36fbf761483aa0c63d95eda254d00fe4d10542403abe36", +< # +< #) +< #version( +< # "20210702", +< # sha256="4fdd8ca2dbde8809c0048716650b73ae1f840e22ebe24b25f6f7a499377fea57", +< # +< #) +< #version( +< # "20210527", +< # sha256="f9f29970941f406d5c250de52a4cd07e5a4e44ae3b5ffed46edd019d998b8c33", +< # +< #) +< #version( +< # "20210514", +< # sha256="74d9c4386f2181b15a024314c42b7a0b0aaefd3b4b947aeca00fe07e5b2f3317", +< # +< #) +< #version( +< # "20210408", +< # sha256="1645147b7777de4f616b8232edf0b597868084f969c777fa0a757949c3f71f56", +< # +< #) +< #version( +< # "20210310", +< # sha256="25708378dbeccf794bc5045aceb84380bf4a3ca03fc8e5d150a26ca88d371474", +< # +< #) +< #version( +< # "20210210", +< # sha256="2c5ba2c7935ad559ca94ee826e8727e65b49ef4582eb856534fffba70e44101a", +< # +< #) +< #version("20201029", sha256="759705e16c1fedd6aa6e07d028cc0c78d73c76b76736668420946a74050c3726") +< #version( +< # "20200721", +< # sha256="845bfeddb7b667799a1a5dbc166b397d714c3d2720316604a979d3465b4190a9", +< # +< #) +< #version( +< # "20200630", +< # sha256="413cbfabcc1541a339c7a4ab5693fbeb768f46bb1250640ba94686c6e90922fc", +< # +< #) +< #version( +< # "20200505", +< # sha256="c49d77fd602d28ebd8cf10f7359b9fc4d14668c72039028ed7792453d416de73", +< # +< #) +< #version("20200303", sha256="a1a2e3e763ef5baecea258732518d75775639db26e60af1634ab385ed89224d1") +< #version( +< # "20200227", +< # sha256="1aabcf38bc72285797c710b648e906151a912c36b634a9c88ac383aacf85516e", +< # +< #) +< #version( +< # "20200218", +< # sha256="73bcf146660804ced954f6a0a8dce937482677778d46018ca5a688127bf97211", +< # +< #) +< #version( +< # "20200204", +< # sha256="3bf3de546ede34ffcd89f1fca5fd66aa78c662e7c8a76e30ce593e44a00d23ce", +< # +< #) +< #version( +< # "20200124", +< # sha256="443829560d760690e1ae21ad54922f56f34f640a81e817f5cc65d2a4af3a6a5d", +< # +< #) +< #version( +< # "20200109", +< # sha256="f2fd24f6c10837801f490913d73f672ec7c6becda08465d7e834a2bfbe3d7cd6", +< # +< #) +< #version( +< # "20191120", +< # sha256="fd146bf517a6c2fb8a69ecb3749dc352eef94414739cd7855c668c690af85d27", +< # +< #) +< #version( +< # "20191030", +< # sha256="5279567f731386ffdb87800b448903a63de2591064e13b4d5216acae25b7e541", +< # +< #) +< #version( +< # "20190919", +< # sha256="0f693203afe86bc70c084c55f29330bdeea3e3ad6791f81c727f7a34a7f6caf3", +< # +< #) +< #version( +< # "20190807", +< # sha256="895d71914057e070fdf0ae5ccf9d6552b932355056690bdb8e86d96549218cc0", +< # +< #) +< #version( +< # "20190605", +< # sha256="c7b35090aef7b114d2b47a7298c1e8237dd811da87995c997bf7639cca743152", +< # +< #) +< #version( +< # "20181212", +< # sha256="ccc5d2c21c4b62ce4afe7b3a0fe2f37b83e5a5e43819b7c2e2e255cce2ce0f24", +< # +< #) +< #version( +< # "20181207", +< # sha256="d92104d008a7f1d0b6071011decc5c6dc8b936a3418b20bd34b055371302557f", +< # +< #) +< #version( +< # "20181127", +< # sha256="c076b633eda5506f895de4c73103df8b995d9fec01be82c67c7608efcc345179", +< # +< #) +< #version( +< # "20181115", +< # sha256="3bc9c166e465cac625c4a8e4060e597003f4619dadd57d3bc8d25bcd930f286e", +< # +< #) +< #version( +< # "20181109", +< # sha256="dd30fe492fa147fb6f39bfcc79d8c786b9689f7fbe86d56de58cace53b6198c9", +< # +< #) +< #version( +< # "20181024", +< # sha256="a171dff5aff7aaa2c9606ab2abc9260f2b685a5c7f6d650e7f2b59cf4aa149d6", +< # +< #) +< #version( +< # "20181010", +< # sha256="bda762ee2d2dcefe0b4e36fb689c6b9f7ede49324444ccde6c59cba727b4b02d", +< # +< #) +< #version( +< # "20180918", +< # sha256="02f143d518d8647b77137adc527faa9725c7afbc538d670253169e2a9b3fa0e6", +< # +< #) +< #version( +< # "20180905", +< # sha256="ee0df649e33a9bf4fe62e062452978731548a56b7487e8e1ce9403676217958d", +< # +< #) +< #version( +< # "20180831", +< # sha256="6c604b3ebd0cef1a5b18730d2c2eb1e659b2db65c5b1ae6240b8a0b150e4dff3", +< # +< #) +< #version( +< # "20180822", +< # sha256="9f8942ca3f8e81377ae88ccfd075da4e27d0dd677526085e1a807777c8324074", +< # +< #) +< #version( +< # "20180629", +< # sha256="1acf7d9b37b99f17563cd4c8bb00ec57bb2e29eb77c0603fd6871898de74763b", +< # +< #) +< #version( +< # "20180316", +< # sha256="a81f88c93e417ecb87cd5f5464c9a2570384a48ff13764051c5e846c3d1258c1", +< # +< #) +< #version( +< # "20180222", +< # sha256="374254d5131b7118b9ab0f0e27d20c3d13d96b03ed2b5224057f0c1065828694", +< # +< #) +< #version( +< # "20170922", +< # sha256="f0bf6eb530d528f4d261d0a261e5616cbb6e990156808b721e73234e463849d3", +< # +< #) +< #version( +< # "20170901", +< # sha256="5d88d4e92f4e0bb57c8ab30e0d20de556830af820223778b9967bec2184efd46", +< # +< #) +--- +> +> depends_on("cxx", type="build") +> +> # mdi, scafacos, ml-quip, qmmm require C, but not available in Spack +> for c_pkg in ("adios", "atc", "awpmd", "ml-pod", "electrode", "kim", "h5md", "tools"): +> depends_on("c", type="build", when=f"+{c_pkg}") +> +> # scafacos, ml-quip require Fortran, but not available in Spack +> for fc_pkg in ("kim",): +> depends_on("fortran", type="build", when=f"+{fc_pkg}") +356a383,385 +> "20230802.3", +> "20230802.2", +> "20230802.1", +446a476 +> "ml-uf3": {"when": "@20240627:"}, +451c481 +< "mpiio": {}, +--- +> "mpiio": {"when": "@:20230802.1"}, +544c574,579 +< variant("exceptions", default=False, description="Build with lammps exceptions") +--- +> variant( +> "exceptions", +> default=False, +> description="Build with lammps exceptions", +> when="@:20230802.1", +> ) +575a611 +> variant("tools", default=False, description="Build LAMMPS tools (msi2lmp, binary2txt, chain)") +576a613 +> depends_on("cmake@3.16:", when="@20231121:") +609a647,648 +> depends_on("kokkos@4.3.00:", when="@20240417: +kokkos") +> depends_on("kokkos@4.3.01:", when="@20240627: +kokkos") +616,623c655,666 +< depends_on("py-cython", when="+mliap+python") +< depends_on("py-cython", when="+ml-iap+python") +< depends_on("py-numpy", when="+python") +< depends_on("py-mpi4py", when="+python+mpi") +< depends_on("py-setuptools", when="@20220217:+python", type="build") +< depends_on("n2p2@2.1.4:", when="+user-hdnnp") +< depends_on("n2p2@2.1.4:", when="+ml-hdnnp") +< depends_on("n2p2+shared", when="+lib ^n2p2") +--- +> depends_on("py-cython", when="+mliap+python", type="build") +> depends_on("py-cython", when="+ml-iap+python", type="build") +> depends_on("py-pip", when="+python", type="build") +> depends_on("py-wheel", when="+python", type="build") +> depends_on("py-build", when="+python", type="build") +> depends_on("py-numpy", when="+python", type=("build", "run")) +> depends_on("py-mpi4py", when="+python+mpi", type=("build", "run")) +> depends_on("py-setuptools@42:", when="@20220217:+python", type=("build", "run")) +> for _n2p2_cond in ("+user-hdnnp", "+ml-hdnnp"): +> with when(_n2p2_cond): +> depends_on("n2p2@2.1.4:") +> depends_on("n2p2+shared", when="+lib") +627c670,671 +< depends_on("llvm-amdgpu +openmp", when="+rocm +openmp", type="build") +--- +> depends_on("llvm-amdgpu ", when="+rocm", type="build") +> depends_on("rocm-openmp-extras", when="+rocm +openmp", type="build") +700,701c744,745 +< when="@:20230802", +< msg="LAMMPS is incompatible with Kokkos 4.x until @20230802", +--- +> when="@:20230802.1", +> msg="LAMMPS is incompatible with Kokkos 4.x until @20230802.1", +707c751,756 +< patch("intel-aocc.patch", when="@20220324:20221103 +intel %aocc") +--- +> +> # This patch merged to LAMMPS trunk at 20221222 and backported to +> # stable version 20220623.4. We still patch all other affected +> # versions here +> patch("intel-aocc.patch", when="@20220324:20220623.3,20220803:20221103 +intel %aocc") +> +714a764,773 +> # Add large potential files +> resource( +> name="C_10_10.mesocnt", +> url="https://download.lammps.org/potentials/C_10_10.mesocnt", +> sha256="923f600a081d948eb8b4510f84aa96167b5a6c3e1aba16845d2364ae137dc346", +> expand=False, +> placement={"C_10_10.mesocnt": "potentials/C_10_10.mesocnt"}, +> when="+mesont", +> ) +> +730a790 +> self.define_from_variant("BUILD_TOOLS", "tools"), +731a792 +> self.define("DOWNLOAD_POTENTIALS", False), +779,781c840 +< cmake_tune_flags = archspec.cpu.TARGETS[spec.target.name].optimization_flags( +< spec.compiler.name, spec.compiler.version +< ) +--- +> cmake_tune_flags = spec.architecture.target.optimization_flags(spec.compiler) +800c859 +< elif "^mkl" in spec: +--- +> elif spec["fftw-api"].name in INTEL_MATH_LIBRARIES: +831a891,895 +> if "@:20231121" in spec: +> if "^hip@:5.4" in spec: +> args.append(self.define("HIP_PATH", f"{spec['hip'].prefix}/hip")) +> elif "^hip@5.5:" in spec: +> args.append(self.define("HIP_PATH", spec["hip"].prefix)) +844,845c908,932 +< env.prepend_path("LD_LIBRARY_PATH", self.prefix.lib) +< env.prepend_path("LD_LIBRARY_PATH", self.prefix.lib64) +--- +> if self.spec.platform == "darwin": +> env.prepend_path("DYLD_FALLBACK_LIBRARY_PATH", self.prefix.lib) +> env.prepend_path("DYLD_FALLBACK_LIBRARY_PATH", self.prefix.lib64) +> else: +> env.prepend_path("LD_LIBRARY_PATH", self.prefix.lib) +> env.prepend_path("LD_LIBRARY_PATH", self.prefix.lib64) +> if "+plugin" in self.spec: +> env.prepend_path("LAMMPS_PLUGIN_PATH", self.prefix.lib.lammps.plugins) +> env.prepend_path("LAMMPS_PLUGIN_PATH", self.prefix.lib64.lammps.plugins) +> +> @run_after("install") +> def make_plugins_directories(self): +> os.makedirs(self.prefix.lib.lammps.plugins, exist_ok=True) +> os.makedirs(self.prefix.lib64.lammps.plugins, exist_ok=True) +> +> @run_after("install") +> def install_python(self): +> # do LAMMPS Python package installation using pip +> if self.spec.satisfies("@20230328: +python"): +> with working_dir("python"): +> os.environ["LAMMPS_VERSION_FILE"] = join_path( +> self.stage.source_path, "src", "version.h" +> ) +> args = std_pip_args + ["--prefix=" + self.prefix, "."] +> pip(*args) +###### DIFF lapackpp +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5c5 +< # Pawsey additions - added 2023.11.05 version +--- +> +12a13,14 +> ["master", "master"], +> ["2024.05.31", "2024.05.31"], +35c37,45 +< version("2023.11.05", sha256="9a505ef4e76504b6714cc19eb1b58939694f9ab51427a5bb915b016d615570ca") +--- +> license("BSD-3-Clause") +> +> version("master", branch="master") +> version( +> "2024.05.31", sha256="093646d492a4c2c6b4d7001effb559c80da7fa31fd5ba517a6d686ca8c78cd99" +> ) +> version( +> "2023.11.05", sha256="9a505ef4e76504b6714cc19eb1b58939694f9ab51427a5bb915b016d615570ca" +> ) +59a70,71 +> +> depends_on("cxx", type="build") # generated +###### DIFF libffi +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5c5 +< # Pawsey addtions - line 48 to handle cce compiler +--- +> +17a18,21 +> license("MIT") +> +> version("3.4.6", sha256="b0dea9df23c863a7a50e825440f3ebffabd65df1497108e5d437747843895a4e") +> version("3.4.5", sha256="96fff4e589e3b239d888d9aa44b3ff30693c2ba1617f953925a70ddebcc102b2") +31a36,38 +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> +34a42,46 +> patch( +> "https://github.com/libffi/libffi/commit/ce077e5565366171aa1b4438749b0922fce887a4.patch?full_index=1", +> sha256="070b1f3aa87f2b56f83aff38afc42157e1692bfaa580276ecdbad2048b818ed7", +> when="@3.4.3:3.4.4", +> ) +47d58 +< or self.spec.satisfies("%cce@16:") +53c64 +< args = [] +--- +> args = ["--with-pic"] +###### DIFF libxpm +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +6,7d5 +< # using spack/0.19.0 recipe. spack/0.20.0 doesn't work on joey +< +14c12 +< homepage = "https://cgit.freedesktop.org/xorg/lib/libXpm" +--- +> homepage = "https://gitlab.freedesktop.org/xorg/lib/libXpm" +16a15,23 +> license("X11") +> +> maintainers("wdconinc") +> +> version("3.5.17", sha256="959466c7dfcfcaa8a65055bfc311f74d4c43d9257900f85ab042604d286df0c6") +> version("3.5.16", sha256="43a70e6f9b67215fb223ca270d83bdcb868c513948441d5b781ea0765df6bfb4") +> version("3.5.15", sha256="2a9bd419e31270593e59e744136ee2375ae817322447928d2abb6225560776f9") +> version("3.5.14", sha256="18861cc64dfffc0e7fe317b0eeb935adf64858fd5d82004894c4906d909dabf8") +> version("3.5.13", sha256="e3dfb0fb8c1f127432f2a498c7856b37ce78a61e8da73f1aab165a73dd97ad00") +23a31,32 +> depends_on("c", type="build") +> +27c36,37 +< depends_on("xproto") +--- +> depends_on("xproto", type="build") +> depends_on("ncompress", when="@3.5.15") +31,41c41,44 +< # def flag_handler(self, name, flags): +< # if name == "ldlibs" and "intl" in self.spec["gettext"].libs.names: +< # flags.append("-lintl") +< # return env_flags(name, flags) +< +< def setup_build_environment(self, env): +< # If libxpm is installed as an external package, gettext won't +< # be available in the spec. See +< # https://github.com/spack/spack/issues/9149 for details. +< if "gettext" in self.spec: +< env.append_flags("LDFLAGS", "-L{0} -lintl".format(self.spec["gettext"].prefix.lib)) +--- +> def flag_handler(self, name, flags): +> if name == "ldflags" and "intl" in self.spec["gettext"].libs.names: +> flags.append("-lintl") +> return env_flags(name, flags) +###### DIFF magma +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5d4 +< # lines introduced to handle rocm-path +9d7 +< from spack.util.prefix import Prefix +18c16 +< homepage = "https://icl.cs.utk.edu/magma/" +--- +> homepage = "https://icl.utk.edu/magma/" +20c18 +< url = "https://icl.cs.utk.edu/projectsfiles/magma/downloads/magma-2.2.0.tar.gz" +--- +> url = "https://icl.utk.edu/projectsfiles/magma/downloads/magma-2.2.0.tar.gz" +27a26 +> version("2.8.0", sha256="f4e5e75350743fe57f49b615247da2cc875e5193cc90c11b43554a7c82cc4348") +42a42,45 +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> depends_on("fortran", type="build") # generated +> +51a55,70 +> # This ensures that rocm-core matches the hip package version in the case that +> # hip is an external package. +> for ver in [ +> "5.5.0", +> "5.5.1", +> "5.6.0", +> "5.6.1", +> "5.7.0", +> "5.7.1", +> "6.0.0", +> "6.0.2", +> "6.1.0", +> "6.1.1", +> "6.1.2", +> ]: +> depends_on(f"rocm-core@{ver}", when=f"@2.8.0: +rocm ^hip@{ver}") +68c87 +< conflicts("cuda_arch={}".format(target)) +--- +> conflicts(f"cuda_arch={target}") +82a102 +> patch("0001-fix-magma-build-error-with-rocm-6.0.0.patch", when="@2.7.2 ^hip@6.0 + rocm") +100c120 +< gpu_target = " ".join("sm_{0}".format(i) for i in cuda_archs) +--- +> gpu_target = " ".join(f"sm_{i}" for i in cuda_archs) +106,107c126,127 +< inc.write("GPU_TARGET = {0}\n".format(gpu_target)) +< inc.write("BACKEND = {0}\n".format(backend)) +--- +> inc.write(f"GPU_TARGET = {gpu_target}\n") +> inc.write(f"BACKEND = {backend}\n") +138c158 +< capabilities = " ".join("sm{0}{1}".format(sep, i) for i in cuda_arch) +--- +> capabilities = " ".join(f"sm{sep}{i}" for i in cuda_arch) +151c171 +< # See https://github.com/ROCmSoftwarePlatform/rocFFT/issues/322 +--- +> # See https://github.com/ROCm/rocFFT/issues/322 +153a174,175 +> if spec.satisfies("@2.8.0:"): +> options.append(define("ROCM_CORE", spec["rocm-core"].prefix)) +172c194 +< self.cache_extra_test_sources([self.test_src_dir]) +--- +> cache_extra_test_sources(self, [self.test_src_dir]) +174c196,197 +< def test(self): +--- +> def test_c(self): +> """Run C examples""" +176,177c199,200 +< with working_dir(test_dir, create=False): +< pkg_config_path = "{0}/lib/pkgconfig".format(self.prefix) +--- +> with working_dir(test_dir): +> pkg_config_path = self.prefix.lib.pkgconfig +178a202 +> +180,188c204,215 +< self.run_test("./example_sparse", purpose="MAGMA smoke test - sparse solver") +< self.run_test( +< "./example_sparse_operator", purpose="MAGMA smoke test - sparse operator" +< ) +< self.run_test("./example_v1", purpose="MAGMA smoke test - legacy v1 interface") +< self.run_test("./example_v2", purpose="MAGMA smoke test - v2 interface") +< if "+fortran" in self.spec: +< make("fortran") +< self.run_test("./example_f", purpose="MAGMA smoke test - Fortran interface") +--- +> tests = [ +> ("example_sparse", "sparse solver"), +> ("example_sparse_operator", "sparse operator"), +> ("example_v1", "legacy v1 interface"), +> ("example_v2", "v2 interface"), +> ] +> +> for test, desc in tests: +> with test_part(self, f"test_c_{test}", purpose=f"Run {desc} example"): +> exe = which(test) +> exe() +> +191,236c218,230 +< def get_paths(self): +< rocm_spec = self.spec["hip"] +< rocm_prefix = Prefix(rocm_spec.prefix) +< +< paths = { +< "hip-path": rocm_spec.prefix, +< "rocm-path": rocm_spec.prefix, +< "rocm-device-libs": rocm_spec.prefix, #rocm_prefix, #elf.spec["llvm-amdgpu"].prefix, +< "llvm-amdgpu": rocm_prefix.llvm, +< "hsa-rocr-dev": rocm_prefix.hsa, +< } +< paths["bitcode"] = paths["rocm-device-libs"].amdgcn.bitcode +< +< return paths +< +< def set_variables(self, env): +< if self.spec.satisfies("+rocm"): +< # Note: do not use self.spec[name] here, since not all dependencies +< # have defined prefixes when hip is marked as external. +< paths = self.get_paths() +< +< # Used in hipcc, but only useful when hip is external, since only then +< # there is a common prefix /opt/rocm-x.y.z. +< env.set("ROCM_PATH", paths["rocm-path"]) +< # Just the prefix of hip (used in hipcc) +< env.set("HIP_PATH", paths["hip-path"]) +< env.set("HIP_DEVICE_LIB_PATH", paths["bitcode"]) +< env.set("HIP_CLANG_PATH", paths["llvm-amdgpu"].bin) +< env.set("HSA_PATH", paths["hsa-rocr-dev"]) +< env.set("DEVICE_LIB_PATH", paths["bitcode"]) +< env.set("LLVM_PATH", paths["llvm-amdgpu"]) +< +< env.append_path( +< "HIPCC_COMPILE_FLAGS_APPEND", +< "--rocm-path={0}".format(paths["rocm-path"]), +< separator=" ", +< ) +< +< +< def setup_build_environment(self, env): +< if self.spec.satisfies("+rocm"): +< self.set_variables(env) +< +< def setup_run_environment(self, env): +< if self.spec.satisfies("+rocm"): +< self.set_variables(env) +--- +> def test_fortran(self): +> """Run Fortran example""" +> if "+fortran" not in self.spec: +> raise SkipTest("Package must be installed with +fortran") +> +> test_dir = join_path(self.test_suite.current_test_cache_dir, self.test_src_dir) +> with working_dir(test_dir): +> pkg_config_path = self.prefix.lib.pkgconfig +> with spack.util.environment.set_env(PKG_CONFIG_PATH=pkg_config_path): +> make("fortran") +> example_f = which("example_f") +> example_f() +> make("clean") +###### DIFF mctc-lib +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,6c5 +< # +< # Pawsey addition: just grabbed the latest recipe from spack/develop +--- +> +17c16,18 +< maintainers = ["awvwgk"] +--- +> maintainers("awvwgk") +> +> license("Apache-2.0") +20,21c21,24 +< version("0.3.1", "a5032a0bbbbacc952037c5215b71aa6b438767a84bafb60fda25ba43c8835513") +< version("0.3.0", "81f3edbf322e6e28e621730a796278498b84af0f221f785c537a315312059bf0") +--- +> version("0.3.1", sha256="a5032a0bbbbacc952037c5215b71aa6b438767a84bafb60fda25ba43c8835513") +> version("0.3.0", sha256="81f3edbf322e6e28e621730a796278498b84af0f221f785c537a315312059bf0") +> +> depends_on("fortran", type="build") # generated +30,32c33 +< return [ +< "-Djson={0}".format("enabled" if "+json" in self.spec else "disabled"), +< ] +--- +> return ["-Djson={0}".format("enabled" if "+json" in self.spec else "disabled")] +###### DIFF mgard +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,8d4 +< # to handle cray environment +< # if self.spec.satisfies("@2020-10-01 %oneapi@2023:") or self.spec.satisfies("%cce"): +< # flags.append("-Wno-error=c++11-narrowing") +< # is added +27c23,26 +< version("2023-03-31", commit="a8a04a86ff30f91d0b430a7c52960a12fa119589", preferred=True) +--- +> license("Apache-2.0") +> +> version("2023-12-09", commit="d61d8c06c49a72b2e582cc02de88b7b27e1275d2", preferred=True) +> version("2023-03-31", commit="a8a04a86ff30f91d0b430a7c52960a12fa119589") +32a32,33 +> depends_on("cxx", type="build") # generated +> +50a52 +> depends_on("zlib@1.2.9:", when="^[virtuals=zlib-api] zlib") # crc32_z +53c55 +< depends_on("protobuf@:3.21.12", when="@2022-11-18:") +--- +> depends_on("protobuf@3.4:", when="@2022-11-18:") +59a62,64 +> with when("+openmp"): +> depends_on("llvm-openmp", when="%apple-clang") +> +64a70,73 +> conflicts("protobuf@3.22:", when="target=ppc64le", msg="GCC 9.4 segfault in CI") +> conflicts("protobuf@3.22:", when="+cuda target=aarch64:", msg="nvcc fails on ARM SIMD headers") +> # https://github.com/abseil/abseil-cpp/issues/1629 +> conflicts("abseil-cpp@20240116.1", when="+cuda", msg="triggers nvcc parser bug") +68c77,79 +< if self.spec.satisfies("@2020-10-01 %oneapi@2023:") or self.spec.satisfies("%cce"): +--- +> if self.spec.satisfies("@2020-10-01 %oneapi@2023:"): +> flags.append("-Wno-error=c++11-narrowing") +> if self.spec.satisfies("@2020-10-01 %apple-clang@15:"): +###### DIFF mwalib +###### DIFF namd +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,41d4 +< # Differences for the 'namd' package +< # 12c12 +< # < from spack.package import * +< # --- +< # > from spack import * +< # 31,32c31,32 +< # < variant('fftw', default='3', values=('none', '2', '3', 'mkl', 'amdfftw', 'cray'), +< # < description='Enable the use of FFTW/FFTW3/MKL FFT/AMDFFTW/CRAY FFTW') +< # --- +< # > variant('fftw', default='3', values=('none', '2', '3', 'mkl', 'amdfftw'), +< # > description='Enable the use of FFTW/FFTW3/MKL FFT/AMDFFTW') +< # 37,38d36 +< # < variant('plumed', default=False, description='Enable PLUMED support') +< # < +< # 44,45d41 +< # < patch('charmpp-shasta-2.14.patch', when='@2.14') +< # < patch('lpython-2.14.patch.2') +< # 55d50 +< # < depends_on('cray-fftw', when="fftw=cray") +< # 64,66d58 +< # < depends_on('plumed@2.6:+mpi', when='@2.12:2.13+plumed') +< # < depends_on('plumed@2.7:+mpi', when='@2.14+plumed') +< # < +< # 216,219d207 +< # < elif fftw_version == 'cray': +< # < self._copy_arch_file('fftw3') +< # < opts.extend(['--with-fftw3', +< # < '--fftw-prefix', spec['cray-fftw'].prefix]) +< # 257,259d244 +< # < def patch(self): +< # < if '+plumed' in self.spec: +< # < self.spec['plumed'].package.apply_patch(self, force=True) +< +< # Contribute cray additions +< +< # To install Namd with hip support use the following command: +< # spack install namd@2.15a2+rocm amdgpu_target=gfx90a ^charmpp@7.0.0 backend=mpi ^ncurses@6.3+symlinks arch=linux-sles15-zen3 +57,58c20,21 +< url = "file://{0}/NAMD_2.14_Source.tar.gz".format(os.getcwd()) +< # git = "https://charm.cs.illinois.edu/gerrit/namd.git" +--- +> url = "file://{0}/NAMD_2.12_Source.tar.gz".format(os.getcwd()) +> git = "https://charm.cs.illinois.edu/gerrit/namd.git" +59a23 +> redistribute(source=False, binary=False) +61,71c25 +< version("master", branch="master") +< version('2.15a1', branch="master", tag='release-2-15-alpha-1') +< version('2.15a2', sha256='b7ba66c0599254aec265470b477f5c51bf6fccedaeab810132b567cafbd854b7') +< # version("2.15a2", md5="2431366620afa868468320777871ea5c") +< version('2.14', sha256='34044d85d9b4ae61650ccdba5cda4794088c3a9075932392dd0752ef8c049235', +< preferred=True) +< version('2.13', '9e3323ed856e36e34d5c17a7b0341e38') +< version('2.12', '2a1191909b1ab03bf0205971ad4d8ee9') +< +< variant('fftw', default='3', values=('none', '2', '3', 'mkl', 'amdfftw', 'cray'), +< description='Enable the use of FFTW/FFTW3/MKL FFT/AMDFFTW/CRAY FFTW') +--- +> maintainers("jcphill") +73,74c27,76 +< variant('interface', default='none', values=('none', 'tcl', 'python'), +< description='Enables TCL and/or python interface') +--- +> version("master", branch="master") +> version("3.0", sha256="301c64f0f1db860f7336efdb26223ccf66b5ab42bfc9141df8d81ec1e20bf472") +> version( +> "3.0b7", +> sha256="b18ff43b0f55ec59e137c62eba1812589dd88b2122c3a05ea652781667f438b4", +> deprecated=True, +> ) +> version( +> "3.0b6", +> sha256="8b5fb1dc8d5b5666c6a45d20ee7e8c9d1f5c186578e2cf148b68ba421d43b850", +> deprecated=True, +> ) +> version( +> "3.0b3", +> sha256="20c32b6161f9c376536e3cb97c3bfe5367e1baaaace3c716ff79831fc2eb8199", +> deprecated=True, +> ) +> version( +> "2.15a2", +> sha256="8748cbaa93fc480f92fc263d9323e55bce6623fc693dbfd4a40f59b92669713e", +> deprecated=True, +> ) +> version("2.15a1", branch="master", tag="release-2-15-alpha-1", deprecated=True) +> # Same as above, but lets you use a local file instead of git +> version( +> "2.15a1.manual", +> sha256="474006e98e32dddae59616b3b75f13a2bb149deaf7a0d617ce7fb9fd5a56a33a", +> deprecated=True, +> ) +> version( +> "2.14", +> sha256="34044d85d9b4ae61650ccdba5cda4794088c3a9075932392dd0752ef8c049235", +> preferred=True, +> ) +> version("2.13", md5="9e3323ed856e36e34d5c17a7b0341e38") +> version("2.12", md5="2a1191909b1ab03bf0205971ad4d8ee9") +> +> variant( +> "fftw", +> default="3", +> values=("none", "2", "3", "mkl", "amdfftw"), +> description="Enable the use of FFTW/FFTW3/MKL FFT/AMDFFTW", +> ) +> +> variant( +> "interface", +> default="tcl", +> values=("none", "tcl", "python"), +> description="Enables Tcl and/or python interface", +> ) +76c78,79 +< variant('plumed', default=False, description='Enable PLUMED support') +--- +> variant("avxtiles", when="target=x86_64_v4:", default=False, description="Enable avxtiles") +> variant("single_node_gpu", default=False, description="Single node GPU") +81,90c84,87 +< patch('inherited-member-2.13.patch', when='@2.13') +< patch('inherited-member-2.14.patch', when='@2.14') +< patch('charmpp-shasta-2.14.patch', when='@2.14') +< +< # From python 3.8 python3-config requires --embed to report lpython linkage. +< # See https://docs.python.org/3/whatsnew/3.8.html#debug-build-uses-the-same-abi-as-release-build +< patch('lpython-for-3.8+.patch') +< +< # error: 'struct BaseLB::LDStats' has no member named 'n_objs' +< patch('nobjs.patch', when='@2.14') +--- +> patch("inherited-member-2.13.patch", when="@2.13") +> patch("inherited-member-2.14.patch", when="@2.14") +> # Handle change in python-config for python@3.8: +> patch("namd-python38.patch", when="interface=python ^python@3.8:") +92,95c89,92 +< depends_on('charmpp@7.0.0', when="+rocm") +< depends_on('charmpp@6.10.1:', when="@2.14:") +< depends_on('charmpp@6.8.2', when="@2.13") +< depends_on('charmpp@6.7.1', when="@2.12") +--- +> depends_on("charmpp@7.0.0:", when="@3.0:") +> depends_on("charmpp@6.10.1:6", when="@2.14:2") +> depends_on("charmpp@6.8.2", when="@2.13") +> depends_on("charmpp@6.7.1", when="@2.12") +97,98c94,95 +< depends_on('fftw@:2', when="fftw=2") +< depends_on('fftw@3:', when="fftw=3") +--- +> depends_on("fftw@:2", when="fftw=2") +> depends_on("fftw@3:", when="fftw=3") +100,101c97 +< depends_on('amdfftw', when="fftw=amdfftw") +< depends_on('cray-fftw', when="fftw=cray") +--- +> depends_on("amdfftw", when="fftw=amdfftw") +103c99 +< depends_on('intel-mkl', when="fftw=mkl") +--- +> depends_on("mkl", when="fftw=mkl") +105c101 +< depends_on('tcl', when='interface=tcl') +--- +> depends_on("tcl", when="interface=tcl") +107,108c103,104 +< depends_on('tcl', when='interface=python') +< depends_on('python', when='interface=python') +--- +> depends_on("tcl", when="interface=python") +> depends_on("python", when="interface=python") +110,111c106,108 +< depends_on('plumed@2.6:+mpi', when='@2.12:2.13+plumed') +< depends_on('plumed@2.7:+mpi', when='@2.14+plumed') +--- +> conflicts("+avxtiles", when="@:2.14,3:", msg="AVXTiles algorithm requires NAMD 2.15") +> conflicts("+rocm", when="+cuda", msg="NAMD supports only one GPU backend at a time") +> conflicts("+single_node_gpu", when="~cuda~rocm") +116,117c113,114 +< depends_on('cuda@6.5.14:7.5.18', when='@2.12 +cuda') +< depends_on('cuda@8.0.61:', when='@2.13: +cuda') +--- +> depends_on("cuda@6.5.14:7.5.18", when="@2.12 +cuda") +> depends_on("cuda@8.0.61:", when="@2.13: +cuda") +120,126c117,126 +< config_filename = 'arch/{0}.{1}'.format(self.arch, lib) +< copy('arch/Linux-x86_64.{0}'.format(lib), +< config_filename) +< if lib == 'tcl': +< filter_file(r'-ltcl8\.5', +< '-ltcl{0}'.format(self.spec['tcl'].version.up_to(2)), +< config_filename) +--- +> config_filename = "arch/{0}.{1}".format(self.arch, lib) +> if self.arch == "linux-aarch64": +> copy("arch/Linux-ARM64.{0}".format(lib), config_filename) +> else: +> copy("arch/Linux-x86_64.{0}".format(lib), config_filename) +> +> if lib == "tcl": +> filter_file( +> r"-ltcl8\.5", "-ltcl{0}".format(self.spec["tcl"].version.up_to(2)), config_filename +> ) +129c129 +< if lib != 'python': +--- +> if lib != "python": +132,135c132,137 +< opts.extend([ +< '--with-{0}'.format(lib), +< '--{0}-prefix'.format(lib), spec[lib].prefix +< ]) +--- +> lib_prefix = ( +> spec[lib].package.component_prefix +> if spec[lib].name == "intel-oneapi-mkl" +> else spec[lib].prefix +> ) +> opts.extend(["--with-{0}".format(lib), "--{0}-prefix".format(lib), lib_prefix]) +143c145 +< return '{0}-{1}'.format(plat, march) +--- +> return "{0}-{1}".format(plat, march) +147c149 +< return '{0}-spack'.format(self.arch) +--- +> return "{0}-spack".format(self.arch) +151,153c153,155 +< m64 = '-m64 ' if not spec.satisfies('arch=aarch64:') else '' +< with working_dir('arch'): +< with open('{0}.arch'.format(self.build_directory), 'w') as fh: +--- +> m64 = "-m64 " if not spec.satisfies("arch=aarch64:") else "" +> with working_dir("arch"): +> with open("{0}.arch".format(self.build_directory), "w") as fh: +157,158c159 +< archopt = spec.target.optimization_flags( +< spec.compiler.name, spec.compiler.version) +--- +> archopt = spec.architecture.target.optimization_flags(spec.compiler) +160c161 +< if self.spec.satisfies('^charmpp@:6.10.1'): +--- +> if self.spec.satisfies("^charmpp@:6.10.1"): +162,166c163,173 +< 'gcc': m64 + '-O3 -fexpensive-optimizations \ +< -ffast-math -lpthread ' + archopt, +< 'intel': '-O2 -ip -qopenmp-simd' + archopt, +< 'aocc': m64 + '-O3 -ffp-contract=fast -ffast-math \ +< -fopenmp ' + archopt} +--- +> "gcc": m64 +> + "-O3 -fexpensive-optimizations \ +> -ffast-math -lpthread " +> + archopt, +> "intel": "-O2 -ip -qopenmp-simd" + archopt, +> "clang": m64 + "-O3 -ffast-math -fopenmp " + archopt, +> "aocc": m64 +> + "-O3 -ffp-contract=fast -ffast-math \ +> -fopenmp " +> + archopt, +> } +169,187c176,210 +< 'gcc': m64 + '-O3 -fexpensive-optimizations \ +< -ffast-math -lpthread ' + archopt, +< 'intel': '-O2 -ip ' + archopt, +< 'aocc': m64 + '-O3 -ffp-contract=fast \ +< -ffast-math ' + archopt} +< +< optim_opts = optims_opts[self.compiler.name] \ +< if self.compiler.name in optims_opts else '' +< +< fh.write('\n'.join([ +< 'NAMD_ARCH = {0}'.format(self.arch), +< 'CHARMARCH = {0}'.format(self.spec['charmpp'].charmarch), +< 'CXX = {0.cxx} {0.cxx11_flag}'.format( +< self.compiler), +< 'CXXOPTS = {0}'.format(optim_opts), +< 'CC = {0}'.format(self.compiler.cc), +< 'COPTS = {0}'.format(optim_opts), +< '' +< ])) +--- +> "gcc": m64 +> + "-O3 -fexpensive-optimizations \ +> -ffast-math -lpthread " +> + archopt, +> "intel": "-O2 -ip " + archopt, +> "clang": m64 + "-O3 -ffast-math -fopenmp " + archopt, +> "aocc": m64 +> + "-O3 -ffp-contract=fast \ +> -ffast-math " +> + archopt, +> } +> +> if self.spec.satisfies("+avxtiles"): +> optims_opts["aocc"] += " -DNAMD_AVXTILES" +> optims_opts["clang"] += " -DNAMD_AVXTILES" +> optims_opts["gcc"] += " -DNAMD_AVXTILES" +> optims_opts["intel"] += " -DNAMD_AVXTILES" +> +> optim_opts = ( +> optims_opts[self.compiler.name] if self.compiler.name in optims_opts else "" +> ) +> +> fh.write( +> "\n".join( +> [ +> "NAMD_ARCH = {0}".format(self.arch), +> "CHARMARCH = {0}".format(self.spec["charmpp"].charmarch), +> "CXX = {0.cxx} {0.cxx11_flag}".format(self.compiler), +> "CXXOPTS = {0}".format(optim_opts), +> "CC = {0}".format(self.compiler.cc), +> "COPTS = {0}".format(optim_opts), +> "", +> ] +> ) +> ) +195,196c218,219 +< with working_dir('arch'): +< arch_filename = '{0}.arch'.format(self.build_directory) +--- +> with working_dir("arch"): +> arch_filename = "{0}.arch".format(self.build_directory) +199,206c222,223 +< [ +< r"^CHARMARCH = .*$", +< 'CHARMARCH = {0}'.format(self.spec['charmpp'].charmarch) +< ], +< [ +< r"^NAMD_ARCH = .*$", +< 'NAMD_ARCH = {0}'.format(self.arch) +< ] +--- +> [r"^CHARMARCH = .*$", "CHARMARCH = {0}".format(self.spec["charmpp"].charmarch)], +> [r"^NAMD_ARCH = .*$", "NAMD_ARCH = {0}".format(self.arch)], +210,215c227,233 +< if spec.platform == "linux" and \ +< self.compiler.name == "intel" and \ +< 'avx512' in spec.target and \ +< spec.target >= 'skylake_avx512': +< if spec.version >= Version("2.15") and \ +< os.path.exists("Linux-AVX512-icc.arch"): +--- +> if ( +> spec.platform == "linux" +> and self.compiler.name == "intel" +> and "avx512" in spec.target +> and spec.target >= "skylake_avx512" +> ): +> if spec.version >= Version("2.15") and os.path.exists("Linux-AVX512-icc.arch"): +218,221c236,237 +< elif spec.version >= Version("2.14") and \ +< os.path.exists("Linux-SKX-icc.arch"): +< tty.info("Building binaries with Skylake-X" +< "AVX512 optimization") +--- +> elif spec.version >= Version("2.14") and os.path.exists("Linux-SKX-icc.arch"): +> tty.info("Building binaries with Skylake-X" "AVX512 optimization") +226,233c242,243 +< replace.append([ +< r"^CXX = icpc", +< 'CXX = {0}'.format(self.compiler.cxx) +< ]) +< replace.append([ +< r"^CC = icc", +< 'CC = {0}'.format(self.compiler.cc) +< ]) +--- +> replace.append([r"^CXX = icpc", "CXX = {0}".format(self.compiler.cxx)]) +> replace.append([r"^CC = icc", "CC = {0}".format(self.compiler.cc)]) +250c260 +< self._copy_arch_file('base') +--- +> self._copy_arch_file("base") +252,265c262,270 +< opts = ['--charm-base', spec['charmpp'].prefix] +< fftw_version = spec.variants['fftw'].value +< if fftw_version == 'none': +< opts.append('--without-fftw') +< elif fftw_version == 'mkl': +< self._append_option(opts, 'mkl') +< elif fftw_version == 'amdfftw': +< self._copy_arch_file('fftw3') +< opts.extend(['--with-fftw3', +< '--fftw-prefix', spec['amdfftw'].prefix]) +< elif fftw_version == 'cray': +< self._copy_arch_file('fftw3') +< opts.extend(['--with-fftw3', +< '--fftw-prefix', spec['cray-fftw'].prefix]) +--- +> opts = ["--charm-base", spec["charmpp"].prefix] +> fftw_version = spec.variants["fftw"].value +> if fftw_version == "none": +> opts.append("--without-fftw") +> elif fftw_version == "mkl": +> self._append_option(opts, "mkl") +> elif fftw_version == "amdfftw": +> self._copy_arch_file("fftw3") +> opts.extend(["--with-fftw3", "--fftw-prefix", spec["amdfftw"].prefix]) +267c272 +< _fftw = 'fftw{0}'.format('' if fftw_version == '2' else '3') +--- +> _fftw = "fftw{0}".format("" if fftw_version == "2" else "3") +270,271c275 +< opts.extend(['--with-{0}'.format(_fftw), +< '--fftw-prefix', spec['fftw'].prefix]) +--- +> opts.extend(["--with-{0}".format(_fftw), "--fftw-prefix", spec["fftw"].prefix]) +273,275c277,279 +< interface_type = spec.variants['interface'].value +< if interface_type != 'none': +< self._append_option(opts, 'tcl') +--- +> interface_type = spec.variants["interface"].value +> if interface_type != "none": +> self._append_option(opts, "tcl") +277,278c281,282 +< if interface_type == 'python': +< self._append_option(opts, 'python') +--- +> if interface_type == "python": +> self._append_option(opts, "python") +280,289c284,305 +< opts.extend([ +< '--without-tcl', +< '--without-python' +< ]) +< +< if '+cuda' in spec: +< self._append_option(opts, 'cuda') +< filter_file('^CUDADIR=.*$', +< 'CUDADIR={0}'.format(spec['cuda'].prefix), +< join_path('arch', self.arch + '.cuda')) +--- +> opts.extend(["--without-tcl", "--without-python"]) +> +> if "+cuda" in spec: +> self._append_option(opts, "cuda") +> filter_file( +> "^CUDADIR=.*$", +> "CUDADIR={0}".format(spec["cuda"].prefix), +> join_path("arch", self.arch + ".cuda"), +> ) +> for cuda_arch in spec.variants["cuda_arch"].value: +> opts.extend(["--cuda-gencode", f"arch=compute_{cuda_arch},code=sm_{cuda_arch}"]) +> +> if "+single_node_gpu" in spec: +> opts.extend(["--with-single-node-cuda"]) +> +> if "+rocm" in spec: +> self._copy_arch_file("hip") +> opts.append("--with-hip") +> opts.extend(["--rocm-prefix", os.environ["ROCM_PATH"]]) +> +> if "+single_node_gpu" in spec: +> opts.extend(["--with-single-node-hip"]) +291c307 +< config = Executable('./config') +--- +> config = Executable("./config") +298,305c314,328 +< if not os.path.exists(join_path( +< self.spec['charmpp'].prefix, self.spec['charmpp'].charmarch)): +< filter_file(r"^CHARM = \$\(CHARMBASE\)/\$\(CHARMARCH\)", +< "CHARM = $(CHARMBASE)", +< join_path(self.build_directory, "Make.config")) +< def patch(self): +< if '+plumed' in self.spec: +< self.spec['plumed'].package.apply_patch(self) +--- +> if not os.path.exists( +> join_path(self.spec["charmpp"].prefix, self.spec["charmpp"].charmarch) +> ): +> filter_file( +> r"^CHARM = \$\(CHARMBASE\)/\$\(CHARMARCH\)", +> "CHARM = $(CHARMBASE)", +> join_path(self.build_directory, "Make.config"), +> ) +> +> @when("@3.0b3") +> def build(self, spec, prefix): +> # Disable parallel build +> # https://github.com/spack/spack/pull/43215 +> with working_dir(self.build_directory): +> make(parallel=False) +310c333,337 +< install('namd2', prefix.bin) +--- +> if spec.version < Version("3"): +> install("namd2", prefix.bin) +> else: +> install("namd3", prefix.bin) +> install("psfgen", prefix.bin) +314,320c341 +< install('charmrun', prefix.bin) +< +< def url_for_version(self,version): +< if self.spec.satisfies("+rocm"): +< return "file://{0}/NAMD_2.15a2_Source.tar.gz".format(os.getcwd()) +< else: +< return "file://{0}/NAMD_2.12_Source.tar.gz".format(os.getcwd()) +--- +> install("charmrun", prefix.bin) +###### DIFF nekrs +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +7a8 +> from spack.package import * +9,10d9 +< class Nekrs(CMakePackage, ROCmPackage): +< """High-order methods have the potential to overcome the current limitations of standard CFD solvers. For this reason, we have been developing and improving our spectral element code for more than 35 years now. It features state-of-the-art, scalable algorithms that are fast and efficient on platforms ranging from laptops to the world’s fastest computers. Applications span a wide range of fields, including fluid flow, thermal convection, combustion and magnetohydrodynamics. Our user community includes hundreds of scientists and engineers in academia, laboratories and industry.""" +12,15c11,65 +< homepage = 'https://nek5000.mcs.anl.gov/' +< url = 'https://github.com/Nek5000/nekRS/archive/refs/tags/v22.0.tar.gz' +< git = 'https://github.com/Nek5000/nekRS.git' +< maintainers = ['Basha', 'crist'] +--- +> class Nekrs(Package, CudaPackage, ROCmPackage): +> """nekRS is an open-source Navier Stokes solver based on the spectral +> element method targeting classical processors and hardware accelerators +> like GPUs""" +> +> homepage = "https://github.com/Nek5000/nekRS" +> git = "https://github.com/Nek5000/nekRS.git" +> +> tags = [ +> "cfd", +> "flow", +> "hpc", +> "solver", +> "navier-stokes", +> "spectral-elements", +> "fluid", +> "ecp", +> "ecp-apps", +> ] +> +> maintainers("thilinarmtb", "stgeke") +> +> license("BSD-3-Clause") +> +> version("21.0", tag="v21.0", commit="bcd890bf3f9fb4d91224c83aeda75c33570f1eaa") +> +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> depends_on("fortran", type="build") # generated +> +> variant("opencl", default=False, description="Activates support for OpenCL") +> +> # Conflicts: +> # nekrs includes following packages, but in order to build as part of +> # CEED we can't leave them in as conflicts. They should be enabled +> # sometime in future. +> # for pkg in ['occa', 'hyper', 'nek5000', 'blas', 'lapack', 'gslib']: +> # conflicts('^' + pkg, msg=(pkg + " is built into nekRS")) +> +> # Dependencies +> depends_on("mpi") +> depends_on("git") +> depends_on("cmake") +> +> @run_before("install") +> def fortran_check(self): +> if not self.compiler.f77: +> msg = "Cannot build NekRS without a Fortran 77 compiler." +> raise RuntimeError(msg) +> +> # Following 4 methods are stolen from OCCA since we are using OCCA +> # shipped with nekRS. +> def _setup_runtime_flags(self, s_env): +> spec = self.spec +> s_env.set("OCCA_CXX", self.compiler.cxx) +17,18c67,75 +< version("23.0",tag="v23.0") +< version("22.0",tag="v22.0") +--- +> cxxflags = spec.compiler_flags["cxxflags"] +> if cxxflags: +> # Run-time compiler flags: +> s_env.set("OCCA_CXXFLAGS", " ".join(cxxflags)) +> +> if "+cuda" in spec: +> cuda_dir = spec["cuda"].prefix +> # Run-time CUDA compiler: +> s_env.set("OCCA_CUDA_COMPILER", join_path(cuda_dir, "bin", "nvcc")) +20,21c77,80 +< variant('rocm', default=True, description='Enable Hip support') +< variant('mpi', default=True, description='Enable mpi support') +--- +> def setup_build_environment(self, env): +> spec = self.spec +> # The environment variable CXX is automatically set to the Spack +> # compiler wrapper. +23,24c82,91 +< depends_on('hip') +< depends_on('mpi') +--- +> # The cxxflags, if specified, will be set by the Spack compiler wrapper +> # while the environment variable CXXFLAGS will remain undefined. +> # We define CXXFLAGS in the environment to tell OCCA to use the user +> # specified flags instead of its defaults. This way the compiler will +> # get the cxxflags twice - once from the Spack compiler wrapper and +> # second time from OCCA - however, only the second one will be seen in +> # the verbose output, so we keep both. +> cxxflags = spec.compiler_flags["cxxflags"] +> if cxxflags: +> env.set("CXXFLAGS", " ".join(cxxflags)) +26,27c93,105 +< def cmake_args(self): +< args = [] +--- +> # For the cuda, openmp, and opencl variants, set the environment +> # variable OCCA_{CUDA,OPENMP,OPENCL}_ENABLED only if the variant is +> # disabled. Otherwise, let OCCA autodetect what is available. +> +> if "+cuda" in spec: +> cuda_dir = spec["cuda"].prefix +> cuda_libs_list = ["libcuda", "libcudart", "libOpenCL"] +> cuda_libs = find_libraries(cuda_libs_list, cuda_dir, shared=True, recursive=True) +> env.set("OCCA_INCLUDE_PATH", cuda_dir.include) +> env.set("OCCA_LIBRARY_PATH", ":".join(cuda_libs.directories)) +> env.set("OCCA_CUDA_ENABLED", "1") +> else: +> env.set("OCCA_CUDA_ENABLED", "0") +29,33c107,108 +< args.append('-DENABLE_CUDA=0') +< args.append('-DENABLE_HIP=1') +< args.append('-DENABLE_OPENCL=0') +< args.append('-DGPU_MPI=1') +< args.append('-DAMDGPU_TARGET=gfx90a') +--- +> env.set("OCCA_OPENCL_ENABLED", "1" if "+opencl" in spec else "0") +> env.set("OCCA_HIP_ENABLED", "1" if "+rocm" in spec else "0") +35c110,112 +< return args +--- +> # Setup run-time environment for testing. +> env.set("OCCA_VERBOSE", "1") +> self._setup_runtime_flags(env) +38,47c115,116 +< spec = self.spec +< env.set("OCCA_CXX", self.compiler.cxx) +< cxxflags = spec.compiler_flags["cxxflags"] +< env.set("OCCA_CXXFLAGS", " ".join(cxxflags)) +< env.set("NEKRS_HOME", self.prefix) +< +< +< def setup_build_environment(self, env): +< spec = self.spec +< rocm_dir = spec["hip"].prefix +--- +> # The 'env' is included in the Spack generated module files. +> self._setup_runtime_flags(env) +49,60c118,140 +< env.set("OCCA_INCLUDE_PATH", rocm_dir.include) +< env.set("OCCA_LIBRARY_PATH", ":".join(rocm_dir.directories)) +< env.set("NEKRS_INSTALL_DIR", self.prefix) +< env.set("OCCA_CXX", "CC") +< env.set("OCCA_CXXFLAGS", " ".join(spec.compiler_flags["cxxflags"])) +< env.set("OCCA_ENABLE_HIP","1") +< env.set("CXXFLAGS", " ".join(spec.compiler_flags["cxxflags"])) +< env.set("OCCA_VERBOSE", "1") +< env.set("NEKRS_CC", spec["mpi"].mpicc) +< env.set("NEKRS_CXX", spec["mpi"].mpicxx) +< env.set("NEKRS_FC", spec["mpi"].mpifc) +< env.set("TRAVIS", "true") +--- +> def setup_dependent_build_environment(self, env, dependent_spec): +> # Export OCCA_* variables for everyone using this package from within +> # Spack. +> self._setup_runtime_flags(env) +> +> def install(self, spec, prefix): +> script_dir = "scripts" +> +> with working_dir(script_dir): +> # Make sure nekmpi wrapper uses srun when we know OpenMPI +> # is not built with mpiexec +> if "^openmpi~legacylaunchers" in spec: +> filter_file(r"mpirun -np", "srun -n", "nrsmpi") +> filter_file(r"mpirun -np", "srun -n", "nrspre") +> filter_file(r"mpirun -np", "srun -n", "nrsbmpi") +> +> makenrs = Executable(os.path.join(os.getcwd(), "makenrs")) +> +> makenrs.add_default_env("NEKRS_INSTALL_DIR", prefix) +> makenrs.add_default_env("NEKRS_CC", spec["mpi"].mpicc) +> makenrs.add_default_env("NEKRS_CXX", spec["mpi"].mpicxx) +> makenrs.add_default_env("NEKRS_FC", spec["mpi"].mpifc) +> makenrs.add_default_env("TRAVIS", "true") +61a142 +> makenrs(output=str, error=str, fail_on_error=True) +###### DIFF nektar +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,6d4 +< # Nektar builds its own boost and other packages - better than let spack handling it. +< from spack.package import * +9a8,12 +> import llnl.util.filesystem as fs +> +> from spack.package import * +> +> +14,51c17 +< # url = "https://gitlab.nektar.info/nektar/nektar/-/archive/v4.4.1/nektar-v4.4.1.tar.bz2" +< url = "file://{0}/nektar-v5.0.2.tar.bz2".format(os.getcwd()) +< manual_download = True +< #version('5.2.0', sha256="") +< version('5.1.0', sha256='f5fdb729909e4dcd42cb071f06569634fa87fe90384ba0f2f857a9e0e56b6ac5') +< version('5.0.3', sha256='1ef6f8f94f850ae78675bca3f752aa6c9f75401d1d6da4ec25df7fa795b860e9') +< version('5.0.2', sha256='24af60a48dbdf0455149540b35a6a59acd636c47b3150b261899a1a1ca886c0b') +< version('5.0.0', sha256='5c594453fbfaa433f732a55405da9bba27d4a00c32d7b9d7515767925fb4a818') +< version('4.4.1', sha256='71cfd93d848a751ae9ae5e5ba336cee4b4827d4abcd56f6b8dc5c460ed6b738c') +< +< variant('mpi', default=True, description='Builds with mpi support') +< variant('avx2', default=True, description='Builds with simd avx2 support') +< variant('fftw', default=True, description='Builds with fftw support') +< variant('arpack', default=True, description='Builds with arpack support') +< variant('hdf5', default=True, description='Builds with hdf5 support') +< variant('scotch', default=False, +< description='Builds with scotch partitioning support') +< variant('unit-tests', default=False, description='Builds unit tests') +< variant('regression-tests', default=False, description='Builds regression tests') +< variant('benchmarking-tests', default=False, description='Builds benchmark timing codes') +< variant('python', default=False, description='Builds python bindings') +< +< # depends_on('cmake@2.8.8:', type='build', when="~hdf5") +< # depends_on('cmake@3.2:', type='build', when="+hdf5") +< +< depends_on('tinyxml', when='platform=darwin') +< depends_on('mpi', when='+mpi') +< depends_on('blas') +< depends_on('lapack') +< # depends_on('boost@1.57.0 ~atomic ~chrono ~exception +filesystem ~graph +iostreams ~locale ~log ~math ~mpi +multithreaded ~numpy +pic ~program_options ~python ~random +regex ~serialization ~signals +system ~test +thread ~timer ~wave') +< +< depends_on('fftw@3.0: +mpi', when="+mpi+fftw") +< depends_on('fftw@3.0: ~mpi', when="~mpi+fftw") +< depends_on('arpack-ng +mpi', when="+arpack+mpi") +< depends_on('arpack-ng ~mpi', when="+arpack~mpi") +< depends_on('hdf5 +mpi +hl', when="+mpi+hdf5") +< depends_on('scotch ~mpi ~metis', when="~mpi+scotch") +< depends_on('scotch +mpi ~metis', when="+mpi+scotch") +--- +> git = "https://gitlab.nektar.info/nektar/nektar.git" +53,54c19,126 +< conflicts('+hdf5', when='~mpi', +< msg='Nektar hdf5 output is for parallel builds only') +--- +> version("5.5.0", commit="4365d5d7156139f238db962deae5eb25e0437d12", preferred=True) +> version("5.4.0", commit="002bf62648ec667e10524ceb8a98bb1c21804130") +> version("5.3.0", commit="f286f809cfeb26cb73828c90a689a048898971d2") +> +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> +> variant("mpi", default=True, description="Builds with mpi support") +> variant("fftw", default=True, description="Builds with fftw support") +> variant("arpack", default=True, description="Builds with arpack support") +> variant("tinyxml", default=True, description="Builds with external tinyxml support") +> variant("hdf5", default=True, description="Builds with hdf5 support") +> variant("scotch", default=False, description="Builds with scotch partitioning support") +> variant("demos", default=False, description="Build demonstration codes") +> variant("python", default=True, description="Enable python support") +> # Solver variants +> variant( +> "acoustic_solver", +> default=False, +> description="Builds an executable associated with the Acoustic solver", +> ) +> variant( +> "adr_solver", +> default=False, +> description="Builds an executable associated with the ADR solver", +> ) +> variant( +> "cardiac_solver", +> default=False, +> description="Builds an executable associated with the Cardiac electrophysiology solver", +> ) +> variant( +> "compflow_solver", +> default=False, +> description="Builds an executable associated with the CompressibleFlow solver", +> ) +> variant( +> "diff_solver", +> default=False, +> description="Builds an executable associated with the Diffusion solver", +> ) +> variant( +> "dummy_solver", +> default=False, +> description="Builds an executable associated with the Dummy solver", +> ) +> variant( +> "elasticity_solver", +> default=False, +> description="Builds an executable associated with the Elasticity solver", +> ) +> variant( +> "imgwarp_solver", +> default=False, +> description="Builds an executable associated with the Image Warping solver", +> ) +> variant( +> "ins_solver", +> default=False, +> description="Builds an executable associated with the Incompressible Navier Stokes solver", +> ) +> variant( +> "mmf_solver", +> default=False, +> description="Builds an executable associated with the MMF solver", +> ) +> variant( +> "pulsewave_solver", +> default=False, +> description="Builds an executable associated with the Pulse Wave solver", +> ) +> variant( +> "shwater_solver", +> default=False, +> description="Builds an executable associated with the Shallow Water solver", +> ) +> variant( +> "vortexwave_solver", +> default=False, +> description="Builds an executable associated with the Vortex Wave solver", +> ) +> +> depends_on("cmake@2.8.8:", type="build", when="~hdf5") +> depends_on("cmake@3.2:", type="build", when="+hdf5") +> +> depends_on("blas") +> depends_on("zlib") +> depends_on("tinyxml", when="+tinyxml") +> depends_on("lapack") +> depends_on( +> "boost@1.74.0: +thread +iostreams +filesystem +system +program_options +regex +pic" +> "+python +numpy", +> when="+python", +> ) +> depends_on( +> "boost@1.74.0: +thread +iostreams +filesystem +system +program_options +regex +pic", +> when="~python", +> ) +> depends_on("tinyxml", when="platform=darwin") +> +> depends_on("mpi", when="+mpi", type=("build", "link", "run")) +> depends_on("fftw@3.0: +mpi", when="+mpi+fftw") +> depends_on("fftw@3.0: ~mpi", when="~mpi+fftw") +> depends_on("arpack-ng +mpi", when="+arpack+mpi") +> depends_on("arpack-ng ~mpi", when="+arpack~mpi") +> depends_on("hdf5 +mpi +hl", when="+mpi+hdf5") +> depends_on("scotch ~mpi ~metis", when="~mpi+scotch") +> depends_on("scotch +mpi ~metis", when="+mpi+scotch") +56,57c128 +< def cmake_args(self): +< args = [] +--- +> extends("python@3:", when="+python") +59,60c130 +< def hasfeature(feature): +< return 'ON' if feature in self.spec else 'OFF' +--- +> conflicts("+hdf5", when="~mpi", msg="Nektar's hdf5 output is for parallel builds only") +62,77c132,134 +< args.append('-DNEKTAR_USE_FFTW=ON') +< args.append('-DNEKTAR_USE_ARPACK=ON') +< args.append('-DNEKTAR_USE_HDF5=ON') +< args.append('-DNEKTAR_ERROR_ON_WARNINGS=OFF') +< +< args.append('-DNEKTAR_USE_MPI=%s' % hasfeature('+mpi')) +< # args.append('-DNEKTAR_USE_FFTW=%s' % hasfeature('+fftw')) +< # args.append('-DNEKTAR_USE_ARPACK=%s' % hasfeature('+arpack')) +< # args.append('-DNEKTAR_USE_HDF5=%s' % hasfeature('+hdf5')) +< args.append('-DNEKTAR_USE_SCOTCH=%s' % hasfeature('+scotch')) +< args.append('-DNEKTAR_ENABLE_SIMD_AVX2=%s' % hasfeature('+avx2')) +< args.append('-DNEKTAR_USE_PETSC=OFF') +< args.append('-DNEKTAR_BUILD_UNIT_TESTS=%s' % hasfeature('+unit-tests')) +< args.append('-DNEKTAR_BUILD_TESTS=%s' % hasfeature('+regression-tests')) +< args.append('-DNEKTAR_BUILD_TIMINGS=%s' % hasfeature('+benchmarking-tests')) +< args.append('-DNEKTAR_BUILD_PYTHON=%s' % hasfeature('+python')) +--- +> def cmake_args(self): +> def hasfeature(feature): +> return True if feature in self.spec else False +78a136,164 +> args = [ +> self.define_from_variant("NEKTAR_BUILD_DEMOS", "demos"), +> self.define_from_variant("NEKTAR_BUILD_PYTHON", "python"), +> self.define("NEKTAR_BUILD_SOLVERS", True), +> self.define("NEKTAR_BUILD_UTILITIES", True), +> self.define("NEKTAR_ERROR_ON_WARNINGS", False), +> self.define_from_variant("NEKTAR_SOLVER_ACOUSTIC", "acoustic_solver"), +> self.define_from_variant("NEKTAR_SOLVER_ADR", "adr_solver"), +> self.define_from_variant("NEKTAR_SOLVER_CARDIAC_EP", "cardiac_solver"), +> self.define_from_variant("NEKTAR_SOLVER_COMPRESSIBLE_FLOW", "compflow_solver"), +> self.define_from_variant("NEKTAR_SOLVER_DIFFUSION", "diff_solver"), +> self.define_from_variant("NEKTAR_SOLVER_DUMMY", "dummy_solver"), +> self.define_from_variant("NEKTAR_SOLVER_ELASTICITY", "elasticity_solver"), +> self.define_from_variant("NEKTAR_SOLVER_IMAGE_WARPING", "imgwarp_solver"), +> self.define_from_variant("NEKTAR_SOLVER_INCNAVIERSTOKES", "ins_solver"), +> self.define_from_variant("NEKTAR_SOLVER_MMF", "mmf_solver"), +> self.define_from_variant("NEKTAR_SOLVER_PULSEWAVE", "pulsewave_solver"), +> self.define_from_variant("NEKTAR_SOLVER_SHALLOW_WATER", "shwater_solver"), +> self.define_from_variant("NEKTAR_SOLVER_VORTEXWAVE", "vortexwave_solver"), +> self.define_from_variant("NEKTAR_USE_ARPACK", "arpack"), +> self.define_from_variant("NEKTAR_USE_FFTW", "fftw"), +> self.define_from_variant("NEKTAR_USE_HDF5", "hdf5"), +> self.define_from_variant("NEKTAR_USE_MPI", "mpi"), +> self.define("NEKTAR_USE_PETSC", False), +> self.define_from_variant("NEKTAR_USE_SCOTCH", "scotch"), +> self.define("NEKTAR_USE_THREAD_SAFETY", True), +> self.define("NEKTAR_USE_MKL", hasfeature("^intel-oneapi-mkl")), +> self.define("NEKTAR_USE_OPENBLAS", hasfeature("^openblas")), +> ] +79a166,194 +> +> def install(self, spec, prefix): +> super(Nektar, self).install(spec, prefix) +> if "+python" in spec: +> python = which("python") +> with fs.working_dir(self.build_directory): +> python("setup.py", "install", "--prefix", prefix) +> +> def setup_run_environment(self, env): +> env.append_path( +> "CMAKE_PREFIX_PATH", +> os.path.join( +> self.spec.prefix, os.path.join("lib64", os.path.join("nektar++", "cmake")) +> ), +> ) +> env.append_path( +> "PYTHONPATH", os.path.abspath(os.path.join(self.spec.prefix, "build_tree")) +> ) +> +> def setup_dependent_run_environment(self, env, dependent_spec): +> self.setup_run_environment(env) +> +> def setup_dependent_build_environment(self, env, dependent_spec): +> self.setup_run_environment(env) +> +> def add_files_to_view(self, view, merge_map, skip_if_exists=True): +> super(Nektar, self).add_files_to_view(view, merge_map, skip_if_exists) +> path = self.view_destination(view) +> view.link(os.path.join(path, "lib64", "nektar++"), os.path.join(path, "lib", "nektar++")) +###### DIFF netcdf-c +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,10c5 +< #pawsey additions +< # def flag_handler(self, name, flags): +< # if name == "cflags": +< # if self.spec.satisfies("%cce"): +< # flags.append("-Wno-error=incompatible-function-pointer-types") +< # return (flags, None, None) +--- +> +33a29,30 +> license("BSD-3-Clause") +> +58a56,58 +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> +64,66c64,69 +< # TODO: fetch from the upstream repo once https://github.com/Unidata/netcdf-c/pull/2595 +< # is accepted: +< patch("netcdfc-mpi-win-support.patch", when="platform=windows") +--- +> # TODO: https://github.com/Unidata/netcdf-c/pull/2595 contains some of the changes +> # made in this patch but is not sufficent to replace the patch. There is currently +> # no upstream PR (or set of PRs) covering all changes in this path. +> # When #2595 lands, this patch should be updated to include only +> # the changes not incorporated into that PR +> patch("netcdfc_correct_and_export_link_interface.patch", when="platform=windows") +136a140 +> variant("logging", default=False, description="Enable logging") +167c171 +< for __p in ["darwin", "cray", "linux"]: +--- +> for __p in ["darwin", "linux"]: +250c254 +< depends_on("zlib@1.2.5:", when="^zlib") +--- +> depends_on("zlib@1.2.5:", when="^[virtuals=zlib-api] zlib") +253c257 +< for __p in ["darwin", "cray", "linux"]: +--- +> for __p in ["darwin", "linux"]: +290,292d293 +< if name == "cflags": +< if self.spec.satisfies("%cce"): +< flags.append("-Wno-error=incompatible-function-pointer-types") +309d309 +< self.pkg.setup_run_environment(env) +343a344 +> self.define_from_variant("NETCDF_ENABLE_LOGGING", "logging"), +351a353,356 +> if "+shared" in self.pkg.spec["hdf5"]: +> base_cmake_args.append(self.define("NC_FIND_SHARED_LIBS", True)) +> else: +> base_cmake_args.append(self.define("NC_FIND_SHARED_LIBS", False)) +353a359,378 +> @run_after("install") +> def patch_hdf5_pkgconfigcmake(self): +> """ +> Incorrect hdf5 library names are put in the package config and config.cmake files +> due to incorrectly using hdf5 target names +> https://github.com/spack/spack/pull/42878 +> """ +> if sys.platform == "win32": +> return +> +> pkgconfig_file = find(self.prefix, "netcdf.pc", recursive=True) +> cmakeconfig_file = find(self.prefix, "netCDFTargets.cmake", recursive=True) +> ncconfig_file = find(self.prefix, "nc-config", recursive=True) +> settingsconfig_file = find(self.prefix, "libnetcdf.settings", recursive=True) +> +> files = pkgconfig_file + cmakeconfig_file + ncconfig_file + settingsconfig_file +> config = "shared" if self.spec.satisfies("+shared") else "static" +> filter_file(f"hdf5-{config}", "hdf5", *files, ignore_absent=True) +> filter_file(f"hdf5_hl-{config}", "hdf5_hl", *files, ignore_absent=True) +> +414a440,441 +> config_args += self.enable_or_disable("logging") +> +443c470 +< if "+external-xdr" in hdf: +--- +> if "+external-xdr ^libtirpc" in hdf: +452c479 +< extra_libs.append(hdf5["zlib"].libs) +--- +> extra_libs.append(hdf5["zlib-api"].libs) +###### DIFF netlib-scalapack +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +45c45,49 +< if name == "fflags": +--- +> if name == "cflags": +> if self.spec.satisfies("%gcc@14:"): +> # https://bugzilla.redhat.com/show_bug.cgi?id=2178710 +> iflags.append("-std=gnu89") +> elif name == "fflags": +110a115 +> git = "https://github.com/Reference-ScaLAPACK/scalapack" +112a118,119 +> license("BSD-3-Clause-Open-MPI") +> +117a125,128 +> version("master", branch="master") +> +> depends_on("c", type="build") # generated +> depends_on("fortran", type="build") # generated +120,126d130 +< +< def flag_handler(self, name, flags): +< if name == "cflags": +< if self.spec.satisfies("%cce"): +< flags.append("-Wno-error=implicit-function-declaration") +< return (flags, None, None) +< +###### DIFF not_in_spack.txt +###### DIFF omnitrace +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +6c6 +< #- ---------------------------------------------------------------------------- +--- +> # ---------------------------------------------------------------------------- +17a18,19 +> license("MIT") +> +19d20 +< version("1.11.2", commit="1df597e049b240fb263e7fcd7bddc78097d27f00", submodules=True) +31a33,36 +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> depends_on("fortran", type="build") # generated +> +81d85 +< depends_on("tbb@2018.6.0:") +125,133d128 +< +< # TBB include and lib directories, version 10.x or later. +< args.extend( +< [ +< "-DTBB_INCLUDE_DIRS=%s" % spec["tbb"].prefix.include, +< "-DTBB_LIBRARY=%s" % spec["tbb"].prefix.lib, +< ] +< ) +< +138,142d132 +< if "+python" in spec: +< pyexe = spec["python"].command.path +< args.append(self.define("PYTHON_EXECUTABLE", pyexe)) +< args.append(self.define("Python3_EXECUTABLE", pyexe)) +< +158,161d147 +< +< def setup_run_environment(self, env): +< if "+python" in self.spec: +< env.prepend_path("PYTHONPATH", join_path(self.prefix.lib, "python", "site-packages")) +###### DIFF openfoam +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +46,47d45 +< #AEG: Importing this module to use their tools for copying files +< import shutil +51a50 +> from spack.pkg.builtin.boost import Boost +54,59d52 +< #AEG: Will use this function to save the original files before any modification +< def save_original(theFile): +< backHere = theFile + '.original' +< if not os.path.isfile(backHere): +< shutil.copyfile(theFile, backHere) +< +62,68c55,61 +< 'add_extra_files', +< 'write_environ', +< 'rewrite_environ_files', +< 'mplib_content', +< 'foam_add_path', +< 'foam_add_lib', +< 'OpenfoamArch', +--- +> "add_extra_files", +> "write_environ", +> "rewrite_environ_files", +> "mplib_content", +> "foam_add_path", +> "foam_add_lib", +> "OpenfoamArch", +79c72 +< indir = join_path(os.path.dirname(__file__), 'common') +--- +> indir = join_path(os.path.dirname(__file__), "common") +81c74 +< tty.info('Added file {0}'.format(f)) +--- +> tty.info("Added file {0}".format(f)) +84c77 +< indir = join_path(foam_pkg.package_dir, 'assets') +--- +> indir = join_path(foam_pkg.package_dir, "assets") +86c79 +< tty.info('Added file {0}'.format(f)) +--- +> tty.info("Added file {0}".format(f)) +95,96c88,89 +< if key.startswith('#'): +< return '## export {0}={1}\n'.format(re.sub(r'^#+\s*', '', key), value) +--- +> if key.startswith("#"): +> return "## export {0}={1}\n".format(re.sub(r"^#+\s*", "", key), value) +98c91 +< return 'unset {0}\n'.format(key) +--- +> return "unset {0}\n".format(key) +100c93 +< return 'export {0}={1}\n'.format(key, value) +--- +> return "export {0}={1}\n".format(key, value) +108,109c101,102 +< if key.startswith('#'): +< return '## setenv {0} {1}\n'.format(re.sub(r'^#+\s*', '', key), value) +--- +> if key.startswith("#"): +> return "## setenv {0} {1}\n".format(re.sub(r"^#+\s*", "", key), value) +111c104 +< return 'unsetenv {0}\n'.format(key) +--- +> return "unsetenv {0}\n".format(key) +113c106 +< return 'setenv {0} {1}\n'.format(key, value) +--- +> return "setenv {0} {1}\n".format(key, value) +142,143c135,136 +< with open(output, 'w') as outfile: +< outfile.write('# spack generated\n') +--- +> with open(output, "w") as outfile: +> outfile.write("# spack generated\n") +145c138 +< outfile.write('# spack\n') +--- +> outfile.write("# spack\n") +157c150 +< rcfile = kwargs.get('posix', None) +--- +> rcfile = kwargs.get("posix", None) +160c153 +< rcfile = kwargs.get('cshell', None) +--- +> rcfile = kwargs.get("cshell", None) +167,169c160,162 +< Keyword Options: +< posix[=None] If set, the name of the POSIX file to rewrite. +< cshell[=None] If set, the name of the C-shell file to rewrite. +--- +> Keyword Options: +> posix[=None] If set, the name of the POSIX file to rewrite. +> cshell[=None] If set, the name of the C-shell file to rewrite. +171c164 +< rcfile = kwargs.get('posix', None) +--- +> rcfile = kwargs.get("posix", None) +174c167 +< regex = r'^(\s*export\s+{0})=.*$'.format(k) +--- +> regex = r"^(\s*export\s+{0})=.*$".format(k) +176,178c169,171 +< replace = r'unset {0} #SPACK: unset'.format(k) +< elif v.startswith('#'): +< replace = r'unset {0} {1}'.format(k, v) +--- +> replace = r"unset {0} #SPACK: unset".format(k) +> elif v.startswith("#"): +> replace = r"unset {0} {1}".format(k, v) +180,182c173 +< replace = r'\1={0}'.format(v) +< #AEG:saving original for easier installation debug +< save_original(rcfile) +--- +> replace = r"\1={0}".format(v) +185c176 +< rcfile = kwargs.get('cshell', None) +--- +> rcfile = kwargs.get("cshell", None) +188c179 +< regex = r'^(\s*setenv\s+{0})\s+.*$'.format(k) +--- +> regex = r"^(\s*setenv\s+{0})\s+.*$".format(k) +190,192c181,183 +< replace = r'unsetenv {0} #SPACK: unset'.format(k) +< elif v.startswith('#'): +< replace = r'unsetenv {0} {1}'.format(k, v) +--- +> replace = r"unsetenv {0} #SPACK: unset".format(k) +> elif v.startswith("#"): +> replace = r"unsetenv {0} {1}".format(k, v) +194,196c185 +< replace = r'\1 {0}'.format(v) +< #AEG:saving original for easier installation debug +< save_original(rcfile) +--- +> replace = r"\1 {0}".format(v) +202c191 +< return '"' + ':'.join(args) + ':${PATH}"' +--- +> return '"' + ":".join(args) + ':${PATH}"' +207c196 +< return '"' + ':'.join(args) + ':${LD_LIBRARY_PATH}"' +--- +> return '"' + ":".join(args) + ':${LD_LIBRARY_PATH}"' +231c220 +< mpi_spec = spec['mpi'] +--- +> mpi_spec = spec["mpi"] +236,238c225,227 +< libname = 'mpi' +< if 'mpich' in mpi_spec.name: +< libname = 'mpich' +--- +> libname = "mpi" +> if "mpich" in mpi_spec.name: +> libname = "mpich" +245a235 +> +247,255c237,244 +< 'name': '{0}-{1}'.format(mpi_spec.name, mpi_spec.version), +< 'prefix': pre, +< 'include': inc, +< 'bindir': bin, +< 'libdir': lib, +< 'FLAGS': '-DOMPI_SKIP_MPICXX -DMPICH_SKIP_MPICXX', +< 'PINC': '-I{0}'.format(inc), +< #AEG:'PLIBS': '-L{0} -l{1}'.format(lib, libname), +< 'PLIBS': '-L{0} -L{1} -l{2} -l{3}'.format(lib+'$(WM_COMPILER_LIB_ARCH)',lib, libname,'rt'), +--- +> "name": "{0}-{1}".format(mpi_spec.name, mpi_spec.version), +> "prefix": pre, +> "include": inc, +> "bindir": bin, +> "libdir": lib, +> "FLAGS": "-DOMPI_SKIP_MPICXX -DMPICH_SKIP_MPICXX", +> "PINC": "-I{0}".format(inc), +> "PLIBS": "-L{0} -l{1}".format(lib, libname), +261a251 +> +271c261 +< maintainers = ['olesenm'] +--- +> maintainers("olesenm") +273,274c263,264 +< url = "https://sourceforge.net/projects/openfoam/files/v1906/OpenFOAM-v1906.tgz" +< git = "https://develop.openfoam.com/Development/openfoam.git" +--- +> url = "https://sourceforge.net/projects/openfoam/files/v1906/OpenFOAM-v1906.tgz" +> git = "https://develop.openfoam.com/Development/openfoam.git" +277a268,269 +> license("GPL-3.0-or-later") +> +279a272,277 +> version("2312", sha256="f113183a4d027c93939212af8967053c5f8fe76fb62e5848cb11bbcf8e829552") +> version("2306", sha256="d7fba773658c0f06ad17f90199565f32e9bf502b7bb03077503642064e1f5344") +> version( +> "2212_230612", sha256="604cd731173ec2a3645c838cf2468fae050a35c6340e2ca7c157699899d904c0" +> ) +> version("2212", sha256="0a3ddbfea9abca04c3a811e72fcbb184c6b1f92c295461e63b231f1a97e96476") +338,360c336,337 +< variant('float32', default=False, +< description='Use single-precision') +< variant('spdp', default=False, +< description='Use single/double mixed precision') +< variant('int64', default=False, +< description='With 64-bit labels') +< variant('knl', default=False, +< description='Use KNL compiler settings') +< variant('kahip', default=False, +< description='With kahip decomposition') +< variant('metis', default=False, +< description='With metis decomposition') +< variant('scotch', default=True, +< description='With scotch/ptscotch decomposition') +< variant('zoltan', default=False, +< description='With zoltan renumbering') +< variant('mgridgen', default=False, description='With mgridgen support') +< variant('paraview', default=False, +< description='Build paraview plugins and runtime post-processing') +< variant('vtk', default=False, +< description='With VTK runTimePostProcessing') +< variant('source', default=True, +< description='Install library/application sources and tutorials') +--- +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +362c339,361 +< depends_on('mpi') +--- +> variant("int64", default=False, description="With 64-bit labels") +> variant("knl", default=False, description="Use KNL compiler settings") +> variant("kahip", default=False, description="With kahip decomposition") +> variant("metis", default=False, description="With metis decomposition") +> variant("scotch", default=True, description="With scotch/ptscotch decomposition") +> variant("zoltan", default=False, description="With zoltan renumbering") +> variant("mgridgen", default=False, description="With mgridgen support") +> variant( +> "paraview", default=False, description="Build paraview plugins and runtime post-processing" +> ) +> variant("vtk", default=False, description="With VTK runTimePostProcessing") +> variant( +> "source", default=True, description="Install library/application sources and tutorials" +> ) +> variant( +> "precision", +> default="dp", +> description="Precision option", +> values=("sp", "dp", conditional("spdp", when="@1906:")), +> multi=False, +> ) +> +> depends_on("mpi") +368,372c367,380 +< depends_on('zlib') +< depends_on('fftw-api') +< depends_on('boost') +< # OpenFOAM does not play nice with CGAL 5.X +< depends_on('cgal@:4') +--- +> depends_on("zlib-api") +> depends_on("fftw-api") +> +> # TODO: replace this with an explicit list of components of Boost, +> # for instance depends_on('boost +filesystem') +> # See https://github.com/spack/spack/pull/22303 for reference +> depends_on(Boost.with_default_variants) +> +> # Earlier versions of OpenFOAM may not work with CGAL 5.6. I do +> # not know which OpenFOAM added support for 5.x and conservatively +> # use 2312 in the check. +> depends_on("cgal", when="@2312:") +> depends_on("cgal@:4", when="@:2306") +> +375,377c383,385 +< depends_on('flex@:2.6.1,2.6.4:') +< depends_on('cmake', type='build') +< depends_on('m4', type='build') +--- +> depends_on("flex@:2.6.1,2.6.4:") +> depends_on("cmake", type="build") +> depends_on("m4", type="build") +380,384c388,392 +< depends_on('scotch~metis+mpi~int64', when='+scotch~int64') +< depends_on('scotch~metis+mpi+int64', when='+scotch+int64') +< depends_on('kahip', when='+kahip') +< depends_on('metis@5:', when='+metis') +< depends_on('metis+int64', when='+metis+int64') +--- +> depends_on("scotch~metis+mpi~int64", when="+scotch~int64") +> depends_on("scotch~metis+mpi+int64", when="+scotch+int64") +> depends_on("kahip", when="+kahip") +> depends_on("metis@5:", when="+metis") +> depends_on("metis+int64", when="+metis+int64") +386,389c394,397 +< depends_on('parmgridgen', when='+mgridgen', type='build') +< depends_on('zoltan', when='+zoltan') +< depends_on('vtk', when='+vtk') +< depends_on('adios2', when='@1912:') +--- +> depends_on("parmgridgen", when="+mgridgen", type="build") +> depends_on("zoltan", when="+zoltan") +> depends_on("vtk", when="+vtk") +> depends_on("adios2~fortran", when="@1912:") +397c405 +< depends_on('paraview@5.4:', when='@1706:+paraview') +--- +> depends_on("paraview@5.4:", when="@1706:+paraview") +399c407,410 +< depends_on('paraview@:5.0.1', when='@1612+paraview') +--- +> depends_on("paraview@:5.0.1", when="@1612+paraview") +> +> # Icx only support from v2106 onwards +> conflicts("%oneapi", when="@:2012", msg="OneAPI compiler not supported. Try v2106 or greater.") +402,403c413,414 +< common = ['spack-Allwmake', 'README-spack'] +< assets = [] +--- +> common = ["spack-Allwmake", "README-spack"] +> assets = [] # type: List[str] +406c417 +< patch('1612-spack-patches.patch', when='@1612') +--- +> patch("1612-spack-patches.patch", when="@1612") +408,411c419,429 +< patch('https://develop.openfoam.com/Development/openfoam/commit/8831dfc58b0295d0d301a78341dd6f4599073d45.patch', +< when='@1806', +< sha256='531146be868dd0cda70c1cf12a22110a38a30fd93b5ada6234be3d6c9256c6cf' +< ) +--- +> patch( +> "https://develop.openfoam.com/Development/openfoam/commit/8831dfc58b0295d0d301a78341dd6f4599073d45.patch", +> when="@1806", +> sha256="531146be868dd0cda70c1cf12a22110a38a30fd93b5ada6234be3d6c9256c6cf", +> ) +> # Fix: missing std::array include (searchable sphere) +> patch( +> "https://develop.openfoam.com/Development/openfoam/commit/b4324b1297761545d5b10f50b60ab29e71c172aa.patch", +> when="@2012_220610", +> sha256="bad4b0e80fd26ea702bce9ccfb925edbbaa3308f70392fe6da2c7671b1d39bea", +> ) +418c436 +< 'link': False +--- +> "link": False +425c443 +< etc_prefs = {} +--- +> etc_prefs = {} # type: Dict[str,str] +428c446 +< etc_config = {} +--- +> etc_config = {} # type: Dict[str,str] +430,431c448,449 +< phases = ['configure', 'build', 'install'] +< build_script = './spack-Allwmake' # From patch() method. +--- +> phases = ["configure", "build", "install"] +> build_script = "./spack-Allwmake" # From patch() method. +443,444c461,462 +< if version <= Version('1612'): +< fmt = 'v{0}+/OpenFOAM-v{1}+.tgz' +--- +> if version <= Version("1612"): +> fmt = "v{0}+/OpenFOAM-v{1}+.tgz" +446c464 +< fmt = 'v{0}/OpenFOAM-v{1}.tgz' +--- +> fmt = "v{0}/OpenFOAM-v{1}.tgz" +450,456c468,473 +< """Sets a minimal openfoam environment. +< """ +< tty.info('OpenFOAM minimal env {0}'.format(self.prefix)) +< env.set('FOAM_PROJECT_DIR', self.projectdir) +< env.set('WM_PROJECT_DIR', self.projectdir) +< for d in ['wmake', self.archbin]: # bin added automatically +< env.prepend_path('PATH', join_path(self.projectdir, d)) +--- +> """Sets a minimal openfoam environment.""" +> tty.info("OpenFOAM minimal env {0}".format(self.prefix)) +> env.set("FOAM_PROJECT_DIR", self.projectdir) +> env.set("WM_PROJECT_DIR", self.projectdir) +> for d in ["wmake", self.archbin]: # bin added automatically +> env.prepend_path("PATH", join_path(self.projectdir, d)) +459,460c476 +< """Sets the build environment (prior to unpacking the sources). +< """ +--- +> """Sets the build environment (prior to unpacking the sources).""" +472c488 +< bashrc = join_path(self.projectdir, 'etc', 'bashrc') +--- +> bashrc = join_path(self.projectdir, "etc", "bashrc") +483,485c499,500 +< 'PS1', # Leave untouched +< 'MANPATH', # Leave untouched +< +--- +> "PS1", # Leave untouched +> "MANPATH", # Leave untouched +493d507 +< +496c510 +< '[A-Z].*_ARCH_PATH', +--- +> "[A-Z].*_ARCH_PATH", +498d511 +< +501,502c514,515 +< 'FOAM_RUN', +< '(FOAM|WM)_.*USER_.*', +--- +> "FOAM_RUN", +> "(FOAM|WM)_.*USER_.*", +505,506c518,520 +< 'MPI_ARCH_PATH', # Can be required for compilation +< ]) +--- +> "MPI_ARCH_PATH" # Can be required for compilation +> ], +> ) +510,511c524 +< #AEG:solutionFromSpack#284444:tty.info('OpenFOAM bashrc env: {0}'.format(bashrc)) +< tty.debug('OpenFOAM bashrc env: {0}'.format(bashrc)) +--- +> tty.debug("OpenFOAM bashrc env: {0}".format(bashrc)) +525c538 +< env.set('FOAM_PROJECT_DIR', self.projectdir) +--- +> env.set("FOAM_PROJECT_DIR", self.projectdir) +533c546 +< env.set('FOAM_PROJECT_DIR', self.projectdir) +--- +> env.set("FOAM_PROJECT_DIR", self.projectdir) +549c562 +< return join_path('platforms', self.foam_arch, 'bin') +--- +> return join_path("platforms", self.foam_arch, "bin") +554c567 +< return join_path('platforms', self.foam_arch, 'lib') +--- +> return join_path("platforms", self.foam_arch, "lib") +558c571 +< Where needed, apply filter as an alternative to normal patching.""" +--- +> Where needed, apply filter as an alternative to normal patching.""" +561c574 +< @when('@:1806') +--- +> @when("@:1806") +564c577 +< Where needed, apply filter as an alternative to normal patching.""" +--- +> Where needed, apply filter as an alternative to normal patching.""" +570c583 +< tty.info('Added directory link {0}'.format(projdir)) +--- +> tty.info("Added directory link {0}".format(projdir)) +572,576c585,586 +< os.path.relpath( +< self.stage.source_path, +< self.stage.path +< ), +< join_path(self.stage.path, projdir) +--- +> os.path.relpath(self.stage.source_path, self.stage.path), +> join_path(self.stage.path, projdir), +582,583c592 +< 'WM_THIRD_PARTY_DIR': +< r'$WM_PROJECT_DIR/ThirdParty #SPACK: No separate third-party', +--- +> "WM_THIRD_PARTY_DIR": r"$WM_PROJECT_DIR/ThirdParty #SPACK: No separate third-party" +586,588c595,596 +< edits, +< posix=join_path('etc', 'bashrc'), +< cshell=join_path('etc', 'cshrc')) +--- +> edits, posix=join_path("etc", "bashrc"), cshell=join_path("etc", "cshrc") +> ) +594,595c602,603 +< for rcdir in ['config.sh', 'config.csh']: +< rcfile = join_path('etc', rcdir, 'settings') +--- +> for rcdir in ["config.sh", "config.csh"]: +> rcfile = join_path("etc", rcdir, "settings") +597,603c605 +< #AEG:saving original for easier installation debug +< save_original(rcfile) +< filter_file( +< 'WM_PROJECT_INST_DIR/', +< 'WM_PROJECT_DIR/', +< rcfile, +< backup=False) +--- +> filter_file("WM_PROJECT_INST_DIR/", "WM_PROJECT_DIR/", rcfile, backup=False) +610,622c612 +< controlDict = 'etc/controlDict' +< if os.path.exists(controlDict): +< #AEG:saving original for easier installation debug +< save_original(controlDict) +< filter_file(r'trapFpe\s+\d+\s*;', 'trapFpe 0;', +< controlDict, backup=False) +< +< #AEG: Using this function to change the default controlDict settings to use collated filehandler +< def configure_filehandler_collated(self): +< """Enable filehandler collated by default +< """ +< # Set 'fileHandler collated' in etc/controlDict +< controlDict = 'etc/controlDict' +--- +> controlDict = "etc/controlDict" +624,687c614 +< #AEG:saving original for easier installation debug +< save_original(controlDict) +< filter_file(r'fileHandler.*;', 'fileHandler collated;', +< controlDict, backup=False) +< +< #---- +< #AEG: Specific settings for Pawsey +< def make_pawsey_settings(self): +< """Settings for Pawsey +< This for when no @when applies! +< """ +< tty.info('Nothing to do in this method for Pawsey settings') +< +< @when('@1812:') +< def make_pawsey_settings(self): +< """Settings for Pawsey +< This for @1812: +< """ +< tty.info('Calling the collated change:') +< self.configure_filehandler_collated() +< +< @run_before('configure') +< def call_make_pawsey_settings(self): +< """Finally performing Pawsey Settings +< """ +< tty.info('Calling the method "pawsey_settings":') +< self.make_pawsey_settings() +< #----- +< #----- +< #AEG: This dummy function is when no @when applies: +< def make_pawsey_rules(self): +< """Pawsey rules when no @when applies +< """ +< tty.info('Nothing to do for the Pawsey rules when no @when applies') +< +< #AEG: The Pawsey Rules rules: +< @when('@1812: %gcc') +< def make_pawsey_rules(self): +< """Create Pawsey rules (based on Cray original rules) unless supplied upstream. +< """ +< compOrig = 'Cray' #This is the name of existing wmake/rules to be used as template for the new ones +< compNew = 'CrayGcc' #This is the name to be used for the new wmake/rules +< compOrigBaseGeneral = 'Gcc' #These are the rules/General used in the original wmake/rules above +< #compNewBaseGeneral = 'Gcc' #These are the rules/General to be used in the new rules +< +< general_rules = 'wmake/rules/General' +< arch_rules = 'wmake/rules/linux64' # self.arch +< src = arch_rules + compOrig +< dst = arch_rules + compNew +< #AEG: In theory, next line shoudl be used for clang based ones +< #self.configure_trapFpe_off() # LLVM may falsely trigger FPE +< +< if os.path.exists(dst): +< return +< +< # Handle rules/ or rules// +< if not os.path.exists(src): +< src = join_path(arch_rules, compOrig) +< dst = join_path(arch_rules, compNew) +< if os.path.exists(dst): +< return +< +< tty.info('Add Pawsey wmake rules') +< copy_tree(src, dst) +--- +> filter_file(r"trapFpe\s+\d+\s*;", "trapFpe 0;", controlDict, backup=False) +689,705c616,627 +< if self.spec.version >= Version('1906'): +< for cfg in ['c', 'c++', 'general']: +< rule = join_path(dst, cfg) +< #AEG:saving original for easier installation debug +< save_original(rule) +< filter_file(compOrig, compNew, rule, backup=False) +< else: +< #AEG:saving original for easier installation debug +< save_original(join_path(dst, 'c')) +< filter_file(compOrig, compNew, rule, backup=False) +< filter_file(compOrigBaseGeneral, spack_cc, join_path(dst, 'c'), +< backup=False, string=True) +< #AEG:saving original for easier installation debug +< save_original(join_path(dst, 'c++')) +< filter_file(compOrig, compNew, rule, backup=False) +< filter_file(compOrigBaseGeneral + '++', spack_cxx, join_path(dst, 'c++'), +< backup=False, string=True) +--- +> @when("@:2106 %aocc@3.2.0:") +> @run_before("configure") +> def make_amd_rules(self): +> """Due to the change in the linker behavior in AOCC v3.2, it is now +> issuing diagnostic messages for the unreferenced symbols in the +> shared objects as it may lead to run time failures. +> """ +> general_rules = "wmake/rules/General" +> src = join_path(general_rules, "Clang") +> filter_file( +> "clang++", spack_cxx + " -pthread", join_path(src, "c++"), backup=False, string=True +> ) +707,735c629,630 +< src = join_path(general_rules, compOrigBaseGeneral) +< dst = join_path(general_rules, compNew) +< copy_tree(src, dst) +< if self.spec.version >= Version('1906'): +< #AEG:saving original for easier installation debug +< save_original(join_path(dst, 'c')) +< filter_file(compOrigBaseGeneral, spack_cc, join_path(dst, 'c'), +< backup=False, string=True) +< #AEG:saving original for easier installation debug +< save_original(join_path(dst, 'c++')) +< filter_file(compOrigBaseGeneral + '++', spack_cxx, join_path(dst, 'c++'), +< backup=False, string=True) +< +< #AEG: This additional function was needed for correct logic when using @when(@1812: %fj) for the fujitsu +< @run_before('configure') +< def call_make_pawsey_rules(self): +< """Calling the correct Pawsey rules with @when +< """ +< self.make_pawsey_rules() +< #----- +< #----- +< #AEG: This additional function was needed for correct logic when using @when(@1812: %fj) for the fujitsu +< def make_fujitsu_rules(self): +< """Fujitsu rules when no @when applies +< """ +< tty.info('Nothing to do for the fujitsu rules when no @when applies') +< +< #AEG: Original function for the fujitsu rules: +< @when('@1812: %fj') +--- +> @when("@1812: %fj") +> @run_before("configure") +741,744c636,639 +< general_rules = 'wmake/rules/General' +< arch_rules = 'wmake/rules/linuxARM64' # self.arch +< src = arch_rules + 'Clang' +< dst = arch_rules + 'Fujitsu2' # self.compiler +--- +> general_rules = "wmake/rules/General" +> arch_rules = "wmake/rules/linuxARM64" # self.arch +> src = arch_rules + "Clang" +> dst = arch_rules + "Fujitsu" # self.compiler +752,753c647,648 +< src = join_path(arch_rules, 'Clang') +< dst = join_path(arch_rules, 'Fujitsu') # self.compiler +--- +> src = join_path(arch_rules, "Clang") +> dst = join_path(arch_rules, "Fujitsu") # self.compiler +757c652 +< tty.info('Add Fujitsu wmake rules') +--- +> tty.info("Add Fujitsu wmake rules") +760,761c655,656 +< if self.spec.version >= Version('1906'): +< for cfg in ['c', 'c++', 'general']: +--- +> if self.spec.version >= Version("1906"): +> for cfg in ["c", "c++", "general"]: +763,765c658 +< #AEG:saving original for easier installation debug +< save_original(rule) +< filter_file('Clang', 'Fujitsu', rule, backup=False) +--- +> filter_file("Clang", "Fujitsu", rule, backup=False) +767,774c660,661 +< #AEG:saving original for easier installation debug +< save_original(join_path(dst, 'c')) +< filter_file('clang', spack_cc, join_path(dst, 'c'), +< backup=False, string=True) +< #AEG:saving original for easier installation debug +< save_original(join_path(dst, 'c++')) +< filter_file('clang++', spack_cxx, join_path(dst, 'c++'), +< backup=False, string=True) +--- +> filter_file("clang", spack_cc, join_path(dst, "c"), backup=False, string=True) +> filter_file("clang++", spack_cxx, join_path(dst, "c++"), backup=False, string=True) +776,777c663,664 +< src = join_path(general_rules, 'Clang') +< dst = join_path(general_rules, 'Fujitsu') # self.compiler +--- +> src = join_path(general_rules, "Clang") +> dst = join_path(general_rules, "Fujitsu") # self.compiler +779,795c666,668 +< if self.spec.version >= Version('1906'): +< #AEG:saving original for easier installation debug +< save_original(join_path(dst, 'c')) +< filter_file('clang', spack_cc, join_path(dst, 'c'), +< backup=False, string=True) +< #AEG:saving original for easier installation debug +< save_original(join_path(dst, 'c++')) +< filter_file('clang++', spack_cxx, join_path(dst, 'c++'), +< backup=False, string=True) +< +< #AEG: This additional function was needed for correct logic when using @when(@1812: %fj) for the fujitsu +< @run_before('configure') +< def call_make_fujitsu_rules(self): +< """Calling the correct fujitsu rules with @when +< """ +< self.make_fujitsu_rules() +< #----- +--- +> if self.spec.version >= Version("1906"): +> filter_file("clang", spack_cc, join_path(dst, "c"), backup=False, string=True) +> filter_file("clang++", spack_cxx, join_path(dst, "c++"), backup=False, string=True) +803d675 +< +808,810c680,681 +< edits, +< posix=join_path('etc', 'bashrc'), +< cshell=join_path('etc', 'cshrc')) +--- +> edits, posix=join_path("etc", "bashrc"), cshell=join_path("etc", "cshrc") +> ) +821c692 +< user_mpi = mplib_content(spec, '${MPI_ARCH_PATH}') +--- +> user_mpi = mplib_content(spec, "${MPI_ARCH_PATH}") +825,838c696,707 +< 'CGAL': [ +< #AEG: Adding the GMP and MPFR pieces +< ('boost_version', 'boost_system'), +< ('cgal_version', 'cgal_system'), +< ('BOOST_ARCH_PATH', spec['boost'].prefix), +< ('CGAL_ARCH_PATH', spec['cgal'].prefix), +< ('GMP_ARCH_PATH', spec['gmp'].prefix), +< ('MPFR_ARCH_PATH', spec['mpfr'].prefix), +< ('LD_LIBRARY_PATH', +< foam_add_lib( +< pkglib(spec['boost'], '${BOOST_ARCH_PATH}'), +< pkglib(spec['cgal'], '${CGAL_ARCH_PATH}'), +< pkglib(spec['gmp'], '${GMP_ARCH_PATH}'), +< pkglib(spec['mpfr'], '${MPFR_ARCH_PATH}'))), +--- +> "CGAL": [ +> ("BOOST_ARCH_PATH", spec["boost"].prefix), +> ("CGAL_ARCH_PATH", spec["cgal"].prefix), +> ("MPFR_ARCH_PATH", spec["mpfr"].prefix), +> ( +> "LD_LIBRARY_PATH", +> foam_add_lib( +> pkglib(spec["boost"], "${BOOST_ARCH_PATH}"), +> pkglib(spec["cgal"], "${CGAL_ARCH_PATH}"), +> pkglib(spec["mpfr"], "${MPFR_ARCH_PATH}"), +> ), +> ), +840,844c709,711 +< 'FFTW': [ +< ('FFTW_ARCH_PATH', spec['fftw-api'].prefix), # Absolute +< ('LD_LIBRARY_PATH', +< foam_add_lib( +< pkglib(spec['fftw-api'], '${BOOST_ARCH_PATH}'))), +--- +> "FFTW": [ +> ("FFTW_ARCH_PATH", spec["fftw-api"].prefix), # Absolute +> ("LD_LIBRARY_PATH", foam_add_lib(pkglib(spec["fftw-api"], "${BOOST_ARCH_PATH}"))), +847,850c714,717 +< 'mpi-user': [ +< ('MPI_ARCH_PATH', spec['mpi'].prefix), # Absolute +< ('LD_LIBRARY_PATH', foam_add_lib(user_mpi['libdir'])), +< ('PATH', foam_add_path(user_mpi['bindir'])), +--- +> "mpi-user": [ +> ("MPI_ARCH_PATH", spec["mpi"].prefix), # Absolute +> ("LD_LIBRARY_PATH", foam_add_lib(user_mpi["libdir"])), +> ("PATH", foam_add_path(user_mpi["bindir"])), +852,859c719,726 +< 'adios2': {}, +< 'scotch': {}, +< 'kahip': {}, +< 'metis': {}, +< 'ensight': {}, # Disable settings +< 'paraview': [], +< 'gperftools': [], # Disable settings +< 'vtk': [], +--- +> "adios2": {}, +> "scotch": {}, +> "kahip": {}, +> "metis": {}, +> "ensight": {}, # Disable settings +> "paraview": [], +> "gperftools": [], # Disable settings +> "vtk": [], +863,868c730,734 +< if spec.satisfies('@1912:'): +< self.etc_config['adios2'] = [ +< ('ADIOS2_ARCH_PATH', spec['adios2'].prefix), +< ('LD_LIBRARY_PATH', +< foam_add_lib(pkglib(spec['adios2'], '${ADIOS2_ARCH_PATH}'))), +< ('PATH', foam_add_path('${ADIOS2_ARCH_PATH}/bin')), +--- +> if spec.satisfies("@1912:"): +> self.etc_config["adios2"] = [ +> ("ADIOS2_ARCH_PATH", spec["adios2"].prefix), +> ("LD_LIBRARY_PATH", foam_add_lib(pkglib(spec["adios2"], "${ADIOS2_ARCH_PATH}"))), +> ("PATH", foam_add_path("${ADIOS2_ARCH_PATH}/bin")), +871,873c737,739 +< if '+scotch' in spec: +< self.etc_config['scotch'] = { +< 'SCOTCH_ARCH_PATH': spec['scotch'].prefix, +--- +> if "+scotch" in spec: +> self.etc_config["scotch"] = { +> "SCOTCH_ARCH_PATH": spec["scotch"].prefix, +875c741 +< 'SCOTCH_VERSION': 'scotch-{0}'.format(spec['scotch'].version), +--- +> "SCOTCH_VERSION": "scotch-{0}".format(spec["scotch"].version), +878,881c744,745 +< if '+kahip' in spec: +< self.etc_config['kahip'] = { +< 'KAHIP_ARCH_PATH': spec['kahip'].prefix, +< } +--- +> if "+kahip" in spec: +> self.etc_config["kahip"] = {"KAHIP_ARCH_PATH": spec["kahip"].prefix} +883,886c747,748 +< if '+metis' in spec: +< self.etc_config['metis'] = { +< 'METIS_ARCH_PATH': spec['metis'].prefix, +< } +--- +> if "+metis" in spec: +> self.etc_config["metis"] = {"METIS_ARCH_PATH": spec["metis"].prefix} +889,895c751,757 +< if '+paraview' in spec: +< pvmajor = 'paraview-{0}'.format(spec['paraview'].version.up_to(2)) +< self.etc_config['paraview'] = [ +< ('ParaView_DIR', spec['paraview'].prefix), +< ('ParaView_INCLUDE_DIR', '${ParaView_DIR}/include/' + pvmajor), +< ('PV_PLUGIN_PATH', '$FOAM_LIBBIN/' + pvmajor), +< ('PATH', foam_add_path('${ParaView_DIR}/bin')), +--- +> if "+paraview" in spec: +> pvmajor = "paraview-{0}".format(spec["paraview"].version.up_to(2)) +> self.etc_config["paraview"] = [ +> ("ParaView_DIR", spec["paraview"].prefix), +> ("ParaView_INCLUDE_DIR", "${ParaView_DIR}/include/" + pvmajor), +> ("PV_PLUGIN_PATH", "$FOAM_LIBBIN/" + pvmajor), +> ("PATH", foam_add_path("${ParaView_DIR}/bin")), +898,902c760,763 +< if '+vtk' in spec: +< self.etc_config['vtk'] = [ +< ('VTK_DIR', spec['vtk'].prefix), +< ('LD_LIBRARY_PATH', +< foam_add_lib(pkglib(spec['vtk'], '${VTK_DIR}'))), +--- +> if "+vtk" in spec: +> self.etc_config["vtk"] = [ +> ("VTK_DIR", spec["vtk"].prefix), +> ("LD_LIBRARY_PATH", foam_add_lib(pkglib(spec["vtk"], "${VTK_DIR}"))), +906,909c767,768 +< if '+mgridgen' in spec: +< self.etc_config['mgridgen'] = { +< 'MGRIDGEN_ARCH_PATH': spec['parmgridgen'].prefix +< } +--- +> if "+mgridgen" in spec: +> self.etc_config["mgridgen"] = {"MGRIDGEN_ARCH_PATH": spec["parmgridgen"].prefix} +912,915c771,772 +< if '+zoltan' in spec: +< self.etc_config['zoltan'] = { +< 'ZOLTAN_ARCH_PATH': spec['zoltan'].prefix +< } +--- +> if "+zoltan" in spec: +> self.etc_config["zoltan"] = {"ZOLTAN_ARCH_PATH": spec["zoltan"].prefix} +922,923c779,781 +< posix=join_path('etc', 'prefs.sh'), +< cshell=join_path('etc', 'prefs.csh')) +--- +> posix=join_path("etc", "prefs.sh"), +> cshell=join_path("etc", "prefs.csh"), +> ) +929,930c787,789 +< posix=join_path('etc', 'config.sh', component), +< cshell=join_path('etc', 'config.csh', component)) +--- +> posix=join_path("etc", "config.sh", component), +> cshell=join_path("etc", "config.csh", component), +> ) +940c799 +< args = ['-silent'] +--- +> args = ["-silent"] +942c801 +< args.append('-j{0}'.format(make_jobs)) +--- +> args.append("-j{0}".format(make_jobs)) +951,954c810,811 +< edits = { +< 'WM_PROJECT_DIR': self.projectdir, +< } +< etc_dir = join_path(self.projectdir, 'etc') +--- +> edits = {"WM_PROJECT_DIR": self.projectdir} +> etc_dir = join_path(self.projectdir, "etc") +956,958c813,814 +< edits, +< posix=join_path(etc_dir, 'bashrc'), +< cshell=join_path(etc_dir, 'cshrc')) +--- +> edits, posix=join_path(etc_dir, "bashrc"), cshell=join_path(etc_dir, "cshrc") +> ) +960c816 +< @when('@:1806') +--- +> @when("@:1806") +971,972c827,828 +< 'WM_PROJECT_INST_DIR': os.path.dirname(self.projectdir), +< 'WM_PROJECT_DIR': join_path('$WM_PROJECT_INST_DIR', projdir), +--- +> "WM_PROJECT_INST_DIR": os.path.dirname(self.projectdir), +> "WM_PROJECT_DIR": join_path("$WM_PROJECT_INST_DIR", projdir), +974c830 +< etc_dir = join_path(self.projectdir, 'etc') +--- +> etc_dir = join_path(self.projectdir, "etc") +976,978c832,833 +< edits, +< posix=join_path(etc_dir, 'bashrc'), +< cshell=join_path(etc_dir, 'cshrc')) +--- +> edits, posix=join_path(etc_dir, "bashrc"), cshell=join_path(etc_dir, "cshrc") +> ) +985,986c840,841 +< if '+source' in spec: +< ignored = re.compile(r'^spack-.*') +--- +> if "+source" in spec: +> ignored = re.compile(r"^spack-.*") +988c843 +< ignored = re.compile(r'^(Allwmake|spack-).*') +--- +> ignored = re.compile(r"^(Allwmake|spack-).*") +990,993c845 +< files = [ +< f for f in glob.glob("*") +< if os.path.isfile(f) and not ignored.search(f) +< ] +--- +> files = [f for f in glob.glob("*") if os.path.isfile(f) and not ignored.search(f)] +1000,1002c852,854 +< dirs = ['META-INFO', 'etc', 'bin', 'wmake'] +< if '+source' in spec: +< dirs.extend(['applications', 'src', 'tutorials']) +--- +> dirs = ["META-INFO", "etc", "bin", "wmake"] +> if "+source" in spec: +> dirs.extend(["applications", "src", "tutorials"]) +1006,1013c858,862 +< install_tree( +< d, +< join_path(self.projectdir, d), +< symlinks=True) +< +< dirs = ['platforms'] +< if '+source' in spec: +< dirs.extend(['doc']) +--- +> install_tree(d, join_path(self.projectdir, d), symlinks=True) +> +> dirs = ["platforms"] +> if "+source" in spec: +> dirs.extend(["doc"]) +1016c865 +< relative_ignore_paths = ['src', 'applications', 'html', 'Guides'] +--- +> relative_ignore_paths = ["src", "applications", "html", "Guides"] +1019,1023c868 +< install_tree( +< d, +< join_path(self.projectdir, d), +< ignore=ignore, +< symlinks=True) +--- +> install_tree(d, join_path(self.projectdir, d), ignore=ignore, symlinks=True) +1034c879,880 +< join_path('log.' + str(self.foam_arch))) +--- +> join_path("log." + str(self.foam_arch)), +> ) +1036c882 +< if not self.config['link']: +--- +> if not self.config["link"]: +1042c888 +< os.symlink(self.archlib, 'lib') +--- +> os.symlink(self.archlib, "lib") +1045c891 +< with working_dir(join_path(self.projectdir, 'bin')): +--- +> with working_dir(join_path(self.projectdir, "bin")): +1047,1048c893 +< f for f in glob.glob(join_path('..', self.archbin, "*")) +< if os.path.isfile(f) +--- +> f for f in glob.glob(join_path("..", self.archbin, "*")) if os.path.isfile(f) +1055c900,901 +< class OpenfoamArch(object): +--- +> +> class OpenfoamArch: +1067,1068c913 +< compiler_mapping = {'aocc': 'Amd', 'fj': 'Fujitsu', +< 'intel': 'Icc', 'oneapi': 'Icx'} +--- +> compiler_mapping = {"aocc": "Amd", "fj": "Fujitsu", "intel": "Icc", "oneapi": "Icx"} +1072,1079c917,924 +< self.compiler = None # <- %compiler +< self.arch_option = '' # Eg, -march=knl +< self.label_size = None # <- +int64 +< self.precision_option = 'DP' # <- +float32 | +spdp +< self.compile_option = kwargs.get('compile-option', '-spack') +< self.arch = None +< self.options = None +< self.mplib = kwargs.get('mplib', 'USERMPI') +--- +> self.compiler = None # <- %compiler +> self.arch_option = "" # Eg, -march=knl +> self.label_size = None # <- +int64 +> self.precision_option = "DP" # <- precision= sp | dp | spdp +> self.compile_option = kwargs.get("compile-option", "-spack") +> self.arch = None +> self.options = None +> self.mplib = kwargs.get("mplib", "USERMPI") +1082,1085c927,930 +< if '+int64' in spec: +< self.label_size = '64' +< elif kwargs.get('label-size', True): +< self.label_size = '32' +--- +> if "+int64" in spec: +> self.label_size = "64" +> elif kwargs.get("label-size", True): +> self.label_size = "32" +1088,1091c933,936 +< if '+spdp' in spec: +< self.precision_option = 'SPDP' +< elif '+float32' in spec: +< self.precision_option = 'SP' +--- +> if "precision=sp" in spec: +> self.precision_option = "SP" +> elif "precision=spdp" in spec: +> self.precision_option = "SPDP" +1094,1095c939,940 +< if '+knl' in spec: +< self.arch_option = '-march=knl' +--- +> if "+knl" in spec: +> self.arch_option = "-march=knl" +1104,1112c949 +< #AEG: updating the compiler if installing in a Cray: +< plat = str(spec.architecture.platform) +< tty.info('Spack Platform is set to {0}'.format(plat)) +< tty.info('Current compiler is set to {0}'.format(comp)) +< if plat == 'cray': +< self.compiler = plat.capitalize() + comp.capitalize() +< else: +< self.compiler = comp.capitalize() +< tty.info('Now compiler is set to {0}'.format(str(self.compiler))) +--- +> self.compiler = comp.capitalize() +1117,1118c954 +< """Set WM_ARCH string corresponding to spack platform/target +< """ +--- +> """Set WM_ARCH string corresponding to spack platform/target""" +1121,1125d956 +< #AEG:Redefining platform to use rules as linuxXX instead of original problematic "cray" +< tty.info('Spack defined platform is {0}'.format(platform)) +< if platform == 'cray': +< platform = 'linux' +< tty.info('Now platform is {0}'.format(platform)) +1131,1138c962,969 +< if platform == 'linux': +< if target == 'x86_64': +< platform += '64' +< elif target == 'ia64': +< platform += 'IA64' +< elif target == 'armv7l': +< platform += 'ARM7' +< elif target == 'aarch64': +--- +> if platform == "linux": +> if target == "x86_64": +> platform += "64" +> elif target == "ia64": +> platform += "IA64" +> elif target == "armv7l": +> platform += "ARM7" +> elif target == "aarch64": +1140,1147c971,977 +< platform += 'ARM64' +< elif target == 'ppc64': +< platform += 'PPC64' +< elif target == 'ppc64le': +< platform += 'PPC64le' +< elif platform == 'darwin': +< if target == 'x86_64': +< platform += '64' +--- +> platform += "ARM64" +> elif target == "ppc64": +> platform += "PPC64" +> elif target == "ppc64le": +> platform += "PPC64le" +> elif platform == "darwin": +> platform += "64" # aarch64 or x86_64 +1152,1153c982 +< """Set WM_OPTIONS string consistent with current settings +< """ +--- +> """Set WM_OPTIONS string consistent with current settings""" +1162,1167c991,999 +< self.options = ''.join([ +< self.arch, +< self.compiler, +< self.precision_option, +< ('Int' + self.label_size if self.label_size else ''), +< self.compile_option]) +--- +> self.options = "".join( +> [ +> self.arch, +> self.compiler, +> self.precision_option, +> ("Int" + self.label_size if self.label_size else ""), +> self.compile_option, +> ] +> ) +1177,1183c1009,1017 +< return dict([ +< ('WM_COMPILER', self.compiler), +< ('WM_LABEL_SIZE', self.label_size), +< ('WM_PRECISION_OPTION', self.precision_option), +< ('WM_COMPILE_OPTION', self.compile_option), +< ('WM_MPLIB', self.mplib), +< ]) +--- +> return dict( +> [ +> ("WM_COMPILER", self.compiler), +> ("WM_LABEL_SIZE", self.label_size), +> ("WM_PRECISION_OPTION", self.precision_option), +> ("WM_COMPILE_OPTION", self.compile_option), +> ("WM_MPLIB", self.mplib), +> ] +> ) +1186c1020 +< """Return the wmake/rules/ General/common, General or +--- +> """Return wmake/rules/ General/common, General or +1190c1024 +< rules_dir = os.path.join(projdir, 'wmake', 'rules') +--- +> rules_dir = os.path.join(projdir, "wmake", "rules") +1192c1026 +< return os.path.join(rules_dir, 'General', 'common') +--- +> return os.path.join(rules_dir, "General", "common") +1194c1028 +< return os.path.join(rules_dir, 'General') +--- +> return os.path.join(rules_dir, "General") +1204,1205c1038 +< """Verify that a wmake/rules/ compiler rule exists in the project. +< """ +--- +> """Verify that a wmake/rules/ compiler rule exists in the project.""" +1210,1213c1043 +< raise InstallError( +< #AEG:'No wmake rule for {0} {1}'.format(self.arch, self.compiler)) +< 'Failed to find the directory {0}\n'.format(rule_dir) +< + 'No wmake rule for {0} {1}'.format(self.arch, self.compiler)) +--- +> raise InstallError("No wmake rule for {0} {1}".format(self.arch, self.compiler)) +1232,1233c1062,1063 +< with open(src, 'r') as infile: +< with open(dst, 'w') as outfile: +--- +> with open(src, "r") as infile: +> with open(dst, "w") as outfile: +1237c1067 +< if re.match(r'^\S+DBUG\s*:?=', line): +--- +> if re.match(r"^\S+DBUG\s*:?=", line): +1240c1070 +< elif re.match(r'^\S+OPT\s*:?=', line): +--- +> elif re.match(r"^\S+OPT\s*:?=", line): +1242c1072 +< outfile.write(' ') +--- +> outfile.write(" ") +1244c1074 +< outfile.write('\n') +--- +> outfile.write("\n") +1248c1078 +< """ Create {c,c++}-spack and mplib{USERMPI} rules in the +--- +> """Create {c,c++}-spack and mplib{USERMPI} rules in the +1262,1264c1092,1094 +< rpath = '{0}{1}'.format( +< foam_pkg.compiler.cxx_rpath_arg, +< join_path(foam_pkg.projectdir, foam_pkg.archlib)) +--- +> rpath = "{0}{1}".format( +> foam_pkg.compiler.cxx_rpath_arg, join_path(foam_pkg.projectdir, foam_pkg.archlib) +> ) +1273,1276c1103,1106 +< for lang in ['c', 'c++']: +< gen = join_path(comm_dir, '{0}Opt'.format(lang)) +< src = join_path(rule_dir, '{0}Opt'.format(lang)) +< dst = join_path(rule_dir, '{0}{1}'.format(lang, self.compile_option)) +--- +> for lang in ["c", "c++"]: +> gen = join_path(comm_dir, "{0}Opt".format(lang)) +> src = join_path(rule_dir, "{0}Opt".format(lang)) +> dst = join_path(rule_dir, "{0}{1}".format(lang, self.compile_option)) +1283,1285c1113,1116 +< for mplib in ['mplibUSERMPI']: +< with open(mplib, 'w') as out: +< out.write("""# MPI from spack ({name})\n +--- +> for mplib in ["mplibUSERMPI"]: +> with open(mplib, "w") as out: +> out.write( +> """# MPI from spack ({name})\n +1290c1121,1125 +< """.format(**user_mpi)) +--- +> """.format( +> **user_mpi +> ) +> ) +> +###### DIFF perl +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +6,15d5 +< # +< # Author: Milton Woods +< # Date: March 22, 2017 +< # Author: George Hartzell +< # Date: July 21, 2016 +< # Author: Justin Too +< # Date: September 6, 2015 +< # +< +< #pawsey additions - flag_handler function to handle cce +20a11 +> from llnl.util.filesystem import windows_sfn +35c26 +< tags = ["windows"] +--- +> tags = ["windows", "build-tools"] +38a30,31 +> license("Artistic-1.0-Perl OR GPL-1.0-or-later") +> +44,59c37,45 +< # Maintenance releases (even numbers, preferred) +< version( +< "5.38.0", +< sha256="213ef58089d2f2c972ea353517dc60ec3656f050dcc027666e118b508423e517", +< preferred=True, +< ) +< version( +< "5.36.1", +< sha256="68203665d8ece02988fc77dc92fccbb297a83a4bb4b8d07558442f978da54cc1", +< preferred=True, +< ) +< version( +< "5.36.0", +< sha256="e26085af8ac396f62add8a533c3a0ea8c8497d836f0689347ac5abd7b7a4e00a", +< preferred=True, +< ) +--- +> # Maintenance releases (even numbers) +> version("5.40.0", sha256="c740348f357396327a9795d3e8323bafd0fe8a5c7835fc1cbaba0cc8dfe7161f") +> version("5.38.2", sha256="a0a31534451eb7b83c7d6594a497543a54d488bc90ca00f5e34762577f40655e") +> version("5.38.0", sha256="213ef58089d2f2c972ea353517dc60ec3656f050dcc027666e118b508423e517") +> version("5.36.3", sha256="f2a1ad88116391a176262dd42dfc52ef22afb40f4c0e9810f15d561e6f1c726a") +> version("5.36.1", sha256="68203665d8ece02988fc77dc92fccbb297a83a4bb4b8d07558442f978da54cc1") +> version("5.36.0", sha256="e26085af8ac396f62add8a533c3a0ea8c8497d836f0689347ac5abd7b7a4e00a") +> +> # End of life releases (deprecated) +63c49 +< preferred=True, +--- +> deprecated=True, +68c54 +< preferred=True, +--- +> deprecated=True, +73c59 +< preferred=True, +--- +> deprecated=True, +78c64 +< preferred=True, +--- +> deprecated=True, +83c69 +< preferred=True, +--- +> deprecated=True, +88c74 +< preferred=True, +--- +> deprecated=True, +93c79 +< preferred=True, +--- +> deprecated=True, +98c84,139 +< preferred=True, +--- +> deprecated=True, +> ) +> version( +> "5.28.0", +> sha256="7e929f64d4cb0e9d1159d4a59fc89394e27fa1f7004d0836ca0d514685406ea8", +> deprecated=True, +> ) +> version( +> "5.26.2", +> sha256="572f9cea625d6062f8a63b5cee9d3ee840800a001d2bb201a41b9a177ab7f70d", +> deprecated=True, +> ) +> version( +> "5.24.1", +> sha256="e6c185c9b09bdb3f1b13f678999050c639859a7ef39c8cad418448075f5918af", +> deprecated=True, +> ) +> version( +> "5.22.4", +> sha256="ba9ef57c2b709f2dad9c5f6acf3111d9dfac309c484801e0152edbca89ed61fa", +> deprecated=True, +> ) +> version( +> "5.22.3", +> sha256="1b351fb4df7e62ec3c8b2a9f516103595b2601291f659fef1bbe3917e8410083", +> deprecated=True, +> ) +> version( +> "5.22.2", +> sha256="81ad196385aa168cb8bd785031850e808c583ed18a7901d33e02d4f70ada83c2", +> deprecated=True, +> ) +> version( +> "5.22.1", +> sha256="2b475d0849d54c4250e9cba4241b7b7291cffb45dfd083b677ca7b5d38118f27", +> deprecated=True, +> ) +> version( +> "5.22.0", +> sha256="0c690807f5426bbd1db038e833a917ff00b988bf03cbf2447fa9ffdb34a2ab3c", +> deprecated=True, +> ) +> version( +> "5.20.3", +> sha256="3524e3a76b71650ab2f794fd68e45c366ec375786d2ad2dca767da424bbb9b4a", +> deprecated=True, +> ) +> version( +> "5.18.4", +> sha256="01a4e11a9a34616396c4a77b3cef51f76a297e1a2c2c490ae6138bf0351eb29f", +> deprecated=True, +> ) +> version( +> "5.16.3", +> sha256="69cf08dca0565cec2c5c6c2f24b87f986220462556376275e5431cc2204dedb6", +> deprecated=True, +102,119c143,170 +< version("5.37.9", sha256="9884fa8a4958bf9434b50f01cbfd187f9e2738f38fe1ae37f844e9950c5117c1") +< version("5.35.0", sha256="d6c0eb4763d1c73c1d18730664d43fcaf6100c31573c3b81e1504ec8f5b22708") +< version("5.33.3", sha256="4f4ba0aceb932e6cf7c05674d05e51ef759d1c97f0685dee65a8f3d190f737cd") +< version("5.31.7", sha256="d05c4e72128f95ef6ffad42728ecbbd0d9437290bf0f88268b51af011f26b57d") +< version("5.31.4", sha256="418a7e6fe6485cc713a86d1227ef112f0bb3f80322e3b715ffe42851d97804a5") +< +< # End of life releases +< version("5.28.0", sha256="7e929f64d4cb0e9d1159d4a59fc89394e27fa1f7004d0836ca0d514685406ea8") +< version("5.26.2", sha256="572f9cea625d6062f8a63b5cee9d3ee840800a001d2bb201a41b9a177ab7f70d") +< version("5.24.1", sha256="e6c185c9b09bdb3f1b13f678999050c639859a7ef39c8cad418448075f5918af") +< version("5.22.4", sha256="ba9ef57c2b709f2dad9c5f6acf3111d9dfac309c484801e0152edbca89ed61fa") +< version("5.22.3", sha256="1b351fb4df7e62ec3c8b2a9f516103595b2601291f659fef1bbe3917e8410083") +< version("5.22.2", sha256="81ad196385aa168cb8bd785031850e808c583ed18a7901d33e02d4f70ada83c2") +< version("5.22.1", sha256="2b475d0849d54c4250e9cba4241b7b7291cffb45dfd083b677ca7b5d38118f27") +< version("5.22.0", sha256="0c690807f5426bbd1db038e833a917ff00b988bf03cbf2447fa9ffdb34a2ab3c") +< version("5.20.3", sha256="3524e3a76b71650ab2f794fd68e45c366ec375786d2ad2dca767da424bbb9b4a") +< version("5.18.4", sha256="01a4e11a9a34616396c4a77b3cef51f76a297e1a2c2c490ae6138bf0351eb29f") +< version("5.16.3", sha256="69cf08dca0565cec2c5c6c2f24b87f986220462556376275e5431cc2204dedb6") +--- +> version("5.39.10", sha256="4b7ffb3e068583fa5c8413390c998b2c15214f205ce737acc485b40932b9f419") +> version( +> "5.37.9", +> sha256="9884fa8a4958bf9434b50f01cbfd187f9e2738f38fe1ae37f844e9950c5117c1", +> deprecated=True, +> ) +> version( +> "5.35.0", +> sha256="d6c0eb4763d1c73c1d18730664d43fcaf6100c31573c3b81e1504ec8f5b22708", +> deprecated=True, +> ) +> version( +> "5.33.3", +> sha256="4f4ba0aceb932e6cf7c05674d05e51ef759d1c97f0685dee65a8f3d190f737cd", +> deprecated=True, +> ) +> version( +> "5.31.7", +> sha256="d05c4e72128f95ef6ffad42728ecbbd0d9437290bf0f88268b51af011f26b57d", +> deprecated=True, +> ) +> version( +> "5.31.4", +> sha256="418a7e6fe6485cc713a86d1227ef112f0bb3f80322e3b715ffe42851d97804a5", +> deprecated=True, +> ) +> +> depends_on("c", type="build") # generated +123a175 +> depends_on("gmake", type="build") +289c341 +< args.append("INST_TOP=%s" % self.prefix.replace("/", "\\")) +--- +> args.append("INST_TOP=%s" % windows_sfn(self.prefix.replace("/", "\\"))) +369a422 +> win32_dir = windows_sfn(win32_dir) +377a431 +> win32_dir = windows_sfn(win32_dir) +410a465 +> cpan_dir = windows_sfn(cpan_dir) +453,456d507 +< # Make the site packages directory for extensions, +< # if it does not exist already. +< mkdirp(module.perl_lib_dir) +< +579,586d629 +< +< def flag_handler(self, name, flags): +< if name == "cflags": +< if self.spec.satisfies("%cce"): +< flags.append("-Wno-error=implicit-int -Wno-error=implicit-function-declaration -Wno-error=incompatible-function-pointer-types -Wno-error=int-conversion") +< return flags, None, None +< +< +###### DIFF pocl +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5c5 +< #added versioon 4.0 +--- +> +21a22,23 +> license("MIT") +> +23,24c25 +< version("4.0", sha256="7f4e8ab608b3191c2b21e3f13c193f1344b40aba7738f78762f7b88f45e8ce03") +< version("3.0", sha256="5f6bbc391ba144bc7becc3b90888b25468460d5aa6830f63a3b066137e7bfac3") +--- +> version("3.0", sha256="a3fd3889ef7854b90b8e4c7899c5de48b7494bf770e39fba5ad268a5cbcc719d") +34a36,38 +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> +51d54 +< depends_on("llvm @14:15", when="@4.0") +###### DIFF presto +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5a6 +> +9,34c10,27 +< class Presto(MesonPackage): +< """ +< PRESTO is a large suite of pulsar search and analysis software developed primarily by Scott +< Ransom mostly from scratch, and released under the GPL (v2). It was primarily designed to +< efficiently search for binary millisecond pulsars from long observations of globular +< clusters (although it has since been used in several surveys with short integrations and to +< process a lot of X-ray data as well). It is written primarily in ANSI C, with many of the +< recent routines in Python. According to Steve Eikenberry, PRESTO stands for: PulsaR +< Exploration and Search TOolkit! +< """ +< homepage = "http://www.cv.nrao.edu/~sransom/presto" +< git = "https://github.com/scottransom/presto.git" +< +< maintainers("dipietrantonio") +< +< license("GPL-2") +< +< version("5.0.1", tag="v5.0.1") +< +< depends_on("glib") +< depends_on("fftw-api@3:") +< depends_on("pgplot") +< depends_on("cfitsio") +< depends_on("libpng") +< depends_on("python@3.6:") +< +--- +> class Presto(MavenPackage): +> """Presto is a distributed SQL query engine for big data.""" +> +> homepage = "https://prestodb.io/" +> url = "https://github.com/prestodb/presto/archive/0.239.tar.gz" +> +> license("Apache-2.0") +> +> version("0.239", sha256="cff738eecf9e4e0bb58a9b0366053a328c4ac4e72d3e8209e8c654f6e1b8985f") +> version("0.238.2", sha256="cb79311cb27695e00108c84c6e135c0b1f8ffb631013c2b25ed8565f9cf1b71f") +> version("0.238.1", sha256="4b811af887fc2dd38cfa36355d6a47c234a600f51e908dc9b59e24a5407b3620") +> version("0.238", sha256="89733c79eac750d401007bc4d1eb2d61aba725b3eaaa3421782443553799e7c9") +> version("0.237.2", sha256="3547328e1757956f8c46d4f5ad12d903f71da1ffed41bb39e6f24c4d4b056040") +> version("0.237.1", sha256="c613c04ef97cf90eb390379cc6efa9ec65aac41a3d8f4863f9567597c6a2ec21") +> version("0.237", sha256="4a19b384eb6bd8ecb020a18b8fa8f6f2105489d1891a2909f53f4e2c20c12699") +> version("0.236.1", sha256="571c74c0b84ee515750c129eb5de1fbac09cd4d028943d9df99c8e89909c83f4") +> version("0.236", sha256="6d4c1d79216d2530b64a7737a54c35e698ca738e42d77d086f036224b42b508e") +> version("0.235.1", sha256="1353b2b8526bc2a365f70e9af7005e294cfff11d53285279b2f67048bb5511a0") +###### DIFF psrfits-utils +###### DIFF py-archspec +1c1 +< # Copyright 2013-2022 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5d4 +< # Can be removed +15c14 +< pypi = "archspec/archspec-0.1.1.tar.gz" +--- +> pypi = "archspec/archspec-0.2.0.tar.gz" +17c16 +< maintainers = ["alalazo"] +--- +> maintainers("alalazo") +19,22c18 +< version("0.1.3", sha256="a1aa7abde4d4ce38d115dfd572584906fa8e192e3272b8897e7b4fa1213ec27c") +< version("0.1.2", sha256="8bb998370f0dc3e509d57c13724ab4109d761fd74af20da26fbe513b0fe01c46") +< version("0.1.1", sha256="34bafad493b41208857232e21776216d716de37ab051a6a4a1cc1653f7e26423") +< version("0.1.0", sha256="a4431d0bbe9c9dd7b293c39d8e7590034d512ce5f5a1278a6cbdf61b33f7202d") +--- +> license("Apache-2.0") +24c20,24 +< depends_on("python@2.7:2.8,3.5:", type=("build", "run")) +--- +> version("0.2.4", sha256="eabbae22f315d24cc2ce786a092478ec8e245208c9877fb213c2172a6ecb9302") +> version("0.2.3", sha256="d07deb5b6e2ab3b74861e217523d02e69be8522f6e6565f4cc5d2062eb1a5d2c") +> version("0.2.2", sha256="d922c9fd80a5234d8cef883fbe0e146b381c449062c0405f91714ebad1edc035") +> version("0.2.1", sha256="0974a8a95831d2d43cce906c5b79a35d5fd2bf9be478b0e3b7d83ccc51ac815e") +> version("0.2.0", sha256="6aaba5ebdb5c3633c400d8c221a6a18716da0c64b367a8509f4217b22e91a5f5") +26,29d25 +< depends_on("py-click@7.1.2:7", type=("build", "run")) +< depends_on("py-six@1.13.0:1", type=("build", "run")) +< +< depends_on("py-setuptools", type="build") +31,37c27 +< +< def patch(self): +< # See https://python-poetry.org/docs/pyproject/#poetry-and-pep-517 +< with working_dir(self.stage.source_path): +< if self.spec.satisfies("@:0.1.3"): +< filter_file("poetry>=0.12", "poetry_core>=1.0.0", "pyproject.toml") +< filter_file("poetry.masonry.api", "poetry.core.masonry.api", "pyproject.toml") +--- +> depends_on("py-click@8", type=("build", "run"), when="@:0.2.0") +###### DIFF py-astropy +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,52d4 +< # Differences for the 'py-astropy' package +< # 8c8 +< # < from spack.package import * +< # --- +< # > from spack import * +< # 19,20d18 +< # < version('5.1', sha256='1db1b2c7eddfc773ca66fa33bd07b25d5b9c3b5eee2b934e0ca277fa5b1b7b7e') +< # < version('4.2.1', sha256='ed483e472241153daec45f4b0c318c2c63d9f47305b78e6e63d32fc388c18427') +< # 44,46d41 +< # < depends_on('py-extension-helpers', when='@4.1:', type=('build', 'run')) +< # < depends_on('py-jinja2', when='@4.1:', type=('build', 'run')) +< # < depends_on('py-erfa', type=('build', 'run')) +< # 73,80c68,73 +< # < #def patch(self, spec): +< # < # # forces the rebuild of files with cython +< # < # # avoids issues with PyCode_New() in newer +< # < # # versions of python in the distributed +< # < # # cython-ized files +< # < # #if spec.satisifies('@1.0:4.0.1'): +< # < # # os.remove('astropy/cython_version.py') +< # < # #os.remove('astropy/cython_version.py') +< # --- +< # > def patch(self): +< # > # forces the rebuild of files with cython +< # > # avoids issues with PyCode_New() in newer +< # > # versions of python in the distributed +< # > # cython-ized files +< # > os.remove('astropy/cython_version.py') +< # 83,91c76,82 +< # < args = [] +< # < if spec.satisfies('@1:4.0'): +< # < args.extend([ +< # < '--use-system-libraries', +< # < '--use-system-erfa', +< # < '--use-system-wcslib', +< # < '--use-system-cfitsio', +< # < '--use-system-expat', +< # < ]) +< # --- +< # > args = [ +< # > '--use-system-libraries', +< # > '--use-system-erfa', +< # > '--use-system-wcslib', +< # > '--use-system-cfitsio', +< # > '--use-system-expat' +< # > ] +< # 94a86 +< # > +54d5 +< # Contribute dependency on py-erfa and spec.statisfies +65,66c16,30 +< homepage = 'https://astropy.org/' +< pypi = 'astropy/astropy-4.0.1.post1.tar.gz' +--- +> homepage = "https://astropy.org/" +> pypi = "astropy/astropy-4.0.1.post1.tar.gz" +> git = "https://github.com/astropy/astropy.git" +> +> license("BSD-3-Clause") +> +> version("6.1.0", sha256="6c3b915f10b1576190730ddce45f6245f9927dda3de6e3f692db45779708950f") +> version("5.1", sha256="1db1b2c7eddfc773ca66fa33bd07b25d5b9c3b5eee2b934e0ca277fa5b1b7b7e") +> version( +> "4.0.1.post1", sha256="5c304a6c1845ca426e7bc319412b0363fccb4928cb4ba59298acd1918eec44b5" +> ) +> version("3.2.1", sha256="706c0457789c78285e5464a5a336f5f0b058d646d60f4e5f5ba1f7d5bf424b28") +> version("2.0.14", sha256="618807068609a4d8aeb403a07624e9984f566adc0dc0f5d6b477c3658f31aeb6") +> version("1.1.2", sha256="6f0d84cd7dfb304bb437dda666406a1d42208c16204043bc920308ff8ffdfad1") +> version("1.1.post1", sha256="64427ec132620aeb038e4d8df94d6c30df4cc8b1c42a6d8c5b09907a31566a21") +68,74c32 +< version('5.1', sha256='1db1b2c7eddfc773ca66fa33bd07b25d5b9c3b5eee2b934e0ca277fa5b1b7b7e') +< version('4.2.1', sha256='ed483e472241153daec45f4b0c318c2c63d9f47305b78e6e63d32fc388c18427') +< version('4.0.1.post1', sha256='5c304a6c1845ca426e7bc319412b0363fccb4928cb4ba59298acd1918eec44b5') +< version('3.2.1', sha256='706c0457789c78285e5464a5a336f5f0b058d646d60f4e5f5ba1f7d5bf424b28') +< version('2.0.14', sha256='618807068609a4d8aeb403a07624e9984f566adc0dc0f5d6b477c3658f31aeb6') +< version('1.1.2', sha256='6f0d84cd7dfb304bb437dda666406a1d42208c16204043bc920308ff8ffdfad1') +< version('1.1.post1', sha256='64427ec132620aeb038e4d8df94d6c30df4cc8b1c42a6d8c5b09907a31566a21') +--- +> depends_on("c", type="build") # generated +76c34 +< variant('extras', default=False, description='Enable extra functionality') +--- +> variant("all", default=False, when="@3.2:", description="Enable all functionality") +79,95c37,70 +< depends_on('python@3.6:', when='@4.0:', type=('build', 'run')) +< depends_on('python@3.5:', when='@3.0:', type=('build', 'run')) +< depends_on('python@2.7:2.8,3.4:', when='@2.0:', type=('build', 'run')) +< depends_on('python@2.7:2.8,3.3:', when='@1.2:', type=('build', 'run')) +< depends_on('python@2.6:', type=('build', 'run')) +< depends_on('py-setuptools', type='build') +< depends_on('py-cython@0.29.13:', type='build') +< depends_on('py-numpy@1.16:', when='@4.0:', type=('build', 'run')) +< depends_on('py-numpy@1.13:', when='@3.1:', type=('build', 'run')) +< depends_on('py-numpy@1.10:', when='@3.0:', type=('build', 'run')) +< depends_on('py-numpy@1.9:', when='@2.0:', type=('build', 'run')) +< depends_on('py-numpy@1.7:', when='@1.2:', type=('build', 'run')) +< depends_on('py-numpy', type=('build', 'run')) +< depends_on('pkgconfig', type='build') +< depends_on('py-extension-helpers', when='@4.1:', type=('build', 'run')) +< depends_on('py-jinja2', when='@4.1:', type=('build', 'run')) +< depends_on('py-erfa', type=('build', 'run')) +--- +> depends_on("python@3.10:", when="@6.1.0:", type=("build", "run")) +> depends_on("python@3.8:", when="@5.1:", type=("build", "run")) +> depends_on("py-setuptools", type="build") +> depends_on("py-cython@0.29.13:", type="build") +> depends_on("py-cython@0.29.30", when="@5.1:6.0", type="build") +> depends_on("py-cython@3.0.0", when="@6.1.0:", type="build") +> +> # in newer pip versions --install-option does not exist +> depends_on("py-pip@:23.0", type="build") +> +> depends_on("py-astropy-iers-data", when="@6:", type=("build", "run")) +> depends_on("py-numpy@1.23:", when="@6.1:", type=("build", "run")) +> depends_on("py-numpy@1.18:", when="@5.1:", type=("build", "run")) +> depends_on("py-numpy@1.16:", when="@4.0:", type=("build", "run")) +> depends_on("py-numpy@1.13:", when="@3.1:", type=("build", "run")) +> depends_on("py-numpy@1.10:", when="@3.0:", type=("build", "run")) +> depends_on("py-numpy@1.9:", when="@2.0:", type=("build", "run")) +> depends_on("py-numpy@1.7:", when="@1.2:", type=("build", "run")) +> depends_on("py-numpy", type=("build", "run")) +> # https://github.com/astropy/astropy/issues/16200 +> depends_on("py-numpy@:1", when="@:6.0") +> depends_on("py-packaging@19.0:", when="@5.1:", type=("build", "run")) +> depends_on("py-pyyaml@3.13:", when="@5.1:", type=("build", "run")) +> depends_on("py-pyerfa@2.0:", when="@5.1:", type=("build", "run")) +> depends_on("py-pyerfa@2.0.1.1:", when="@6.1.0:", type=("build", "run")) +> depends_on("py-setuptools-scm@6.2:", when="@5.1:", type="build") +> depends_on("py-extension-helpers", when="@5.1:", type="build") +> depends_on("pkgconfig", type="build") +> +> depends_on("py-pytest@7:", type="test") +> depends_on("py-pytest-doctestplus@0.12:", type="test") +> depends_on("py-pytest-astropy-header@0.2.1:", type="test") +> depends_on("py-pytest-astropy@0.10:", type="test") +> depends_on("py-pytest-xdist", type="test") +98,114c73,110 +< depends_on('py-scipy@0.18:', when='+extras', type=('build', 'run')) +< depends_on('py-h5py', when='+extras', type=('build', 'run')) +< depends_on('py-beautifulsoup4', when='+extras', type=('build', 'run')) +< depends_on('py-html5lib', when='+extras', type=('build', 'run')) +< depends_on('py-bleach', when='+extras', type=('build', 'run')) +< depends_on('py-pyyaml', when='+extras', type=('build', 'run')) +< depends_on('py-pandas', when='+extras', type=('build', 'run')) +< depends_on('py-bintrees', when='+extras', type=('build', 'run')) +< depends_on('py-sortedcontainers', when='+extras', type=('build', 'run')) +< depends_on('py-pytz', when='+extras', type=('build', 'run')) +< depends_on('py-jplephem', when='+extras', type=('build', 'run')) +< depends_on('py-matplotlib@2.0:', when='+extras', type=('build', 'run')) +< depends_on('py-scikit-image', when='+extras', type=('build', 'run')) +< depends_on('py-mpmath', when='+extras', type=('build', 'run')) +< depends_on('py-asdf@2.3:', when='+extras', type=('build', 'run')) +< depends_on('py-bottleneck', when='+extras', type=('build', 'run')) +< depends_on('py-pytest', when='+extras', type=('build', 'run')) +--- +> with when("+all"): +> depends_on("py-scipy@1.8:", when="@6:", type=("build", "run")) +> depends_on("py-scipy@1.3:", when="@5:", type=("build", "run")) +> depends_on("py-scipy@0.18:", type=("build", "run")) +> depends_on("py-matplotlib@3.3:", when="@6:", type=("build", "run")) +> depends_on("py-matplotlib@3.1:", when="@5:", type=("build", "run")) +> depends_on("py-matplotlib@2.1:", when="@4:", type=("build", "run")) +> depends_on("py-matplotlib@2.0:", type=("build", "run")) +> depends_on("py-certifi", when="@4.3:", type=("build", "run")) +> depends_on("py-dask+array", when="@4.1:", type=("build", "run")) +> depends_on("py-h5py", type=("build", "run")) +> depends_on("py-pyarrow@5:", when="@5:", type=("build", "run")) +> depends_on("py-beautifulsoup4", type=("build", "run")) +> depends_on("py-html5lib", type=("build", "run")) +> depends_on("py-bleach", type=("build", "run")) +> depends_on("py-pandas", type=("build", "run")) +> depends_on("py-sortedcontainers", type=("build", "run")) +> depends_on("py-pytz", type=("build", "run")) +> depends_on("py-jplephem", type=("build", "run")) +> depends_on("py-mpmath", type=("build", "run")) +> depends_on("py-asdf@2.10:", when="@5.1:", type=("build", "run")) +> depends_on("py-asdf@2.5:", when="@4.0.1post1:", type=("build", "run")) +> depends_on("py-asdf@2.3:", type=("build", "run")) +> depends_on("py-bottleneck", type=("build", "run")) +> depends_on("py-ipython@4.2:", when="@4.3:", type=("build", "run")) +> depends_on("py-ipython", type=("build", "run")) +> depends_on("py-pytest@7:", when="@5.0.2:", type=("build", "run")) +> depends_on("py-pytest", type=("build", "run")) +> depends_on("py-fsspec+http@2023.4:", when="@6.1:", type=("build", "run")) +> depends_on("py-s3fs@2023.4:", when="@6.1:", type=("build", "run")) +> depends_on("py-typing-extensions@3.10.0.1:", when="@5.0.2:", type=("build", "run")) +> +> # Historical optional dependencies +> depends_on("py-pyyaml", when="@:5", type=("build", "run")) +> depends_on("py-scikit-image", when="@:4.0", type=("build", "run")) +> depends_on("py-bintrees", when="@:3.2.1", type=("build", "run")) +> +> conflicts("^py-matplotlib@3.4.0,3.5.2") +117,140c113,133 +< depends_on('erfa') +< depends_on('wcslib') +< depends_on('cfitsio') +< depends_on('expat') +< +< #def patch(self, spec): +< # # forces the rebuild of files with cython +< # # avoids issues with PyCode_New() in newer +< # # versions of python in the distributed +< # # cython-ized files +< # #if spec.satisifies('@1.0:4.0.1'): +< # # os.remove('astropy/cython_version.py') +< # #os.remove('astropy/cython_version.py') +< +< def build_args(self, spec, prefix): +< args = [] +< if spec.satisfies('@1:4.0'): +< args.extend([ +< '--use-system-libraries', +< '--use-system-erfa', +< '--use-system-wcslib', +< '--use-system-cfitsio', +< '--use-system-expat', +< ]) +--- +> depends_on("erfa") +> depends_on("wcslib") +> depends_on("cfitsio@:3") +> depends_on("expat") +> +> def patch(self): +> # forces the rebuild of files with cython +> # avoids issues with PyCode_New() in newer +> # versions of python in the distributed +> # cython-ized files +> if os.path.exists("astropy/cython_version.py"): +> os.remove("astropy/cython_version.py") +> +> def install_options(self, spec, prefix): +> args = [ +> "--use-system-libraries", +> "--use-system-erfa", +> "--use-system-wcslib", +> "--use-system-cfitsio", +> "--use-system-expat", +> ] +142,143d134 +< if spec.satisfies('^python@3:'): +< args.extend(['-j', str(make_jobs)]) +146c137 +< @run_after('install') +--- +> @run_after("install") +149,150c140,150 +< with working_dir('spack-test', create=True): +< python('-c', 'import astropy; astropy.test()') +--- +> with working_dir("spack-test", create=True): +> python("-c", "import astropy; astropy.test()") +> +> @property +> def skip_modules(self): +> modules = [] +> +> if self.spec.satisfies("~extras"): +> modules.append("astropy.visualization.wcsaxes") +> +> return modules +###### DIFF py-erfa +###### DIFF py-funcsigs +###### DIFF py-gevent +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5d4 +< #PAWSEY Additions to handle cce compiler in flag_handler +16a16,17 +> license("MIT") +> +21a23,24 +> depends_on("c", type="build") # generated +> +40a44,49 +> # https://github.com/gevent/gevent/issues/2031 +> conflicts( +> "^py-cython@3.0.10", +> when="@:23.9.0", +> msg="py-gevent fails to build when using cython@3.0.10", +> ) +43c52 +< patch("icc.patch", when="%intel") +--- +> patch("icc.patch", when="@:21.12.0 %intel") +56c65 +< if self.spec.satisfies("%oneapi@2023:") or self.spec.satisfies("%cce"): +--- +> if self.spec.satisfies("%oneapi@2023:"): +57a67,68 +> if self.spec.compiler.name in ["intel", "oneapi"]: +> flags.append("-we147") +###### DIFF py-h5py +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5d4 +< #PAWSEY Additions to handle cce compiler in flag_handler +18a18,19 +> license("BSD-3-Clause") +> +19a21,23 +> version("3.11.0", sha256="7b7e8f78072a2edec87c9836f25f34203fd492a4475709a18b417a33cfb21fa9") +> version("3.10.0", sha256="d93adc48ceeb33347eb24a634fb787efc7ae4644e6ea4ba733d099605045c049") +> version("3.9.0", sha256="e604db6521c1e367c6bd7fad239c847f53cc46646f2d2651372d05ae5e95f817") +38a43,44 +> depends_on("c", type="build") # generated +> +43,44d48 +< depends_on("python@3.6:", type=("build", "run"), when="@3:3.1") +< depends_on("python@3.7:", type=("build", "run"), when="@3.2:") +47,49c51,53 +< depends_on("py-cython@0.23:0", type="build", when="@:2") +< depends_on("py-cython@0.29:0", type=("build"), when="@3:") +< depends_on("py-cython@0.29.14:0", type=("build"), when="@3:3.7 ^python@3.8.0:3.8") +--- +> # h5py@3.11 can build with cython@3.x +> depends_on("py-cython@0.29.31:3", type="build", when="@3.11:") +> depends_on("py-cython@0.29.31:0", type="build", when="@3.9:3.10") +50a55,57 +> depends_on("py-cython@0.29.14:0", type=("build"), when="@3:3.7 ^python@3.8.0:3.8") +> depends_on("py-cython@0.29:0", type=("build"), when="@3.0:3.10") +> depends_on("py-cython@0.23:0", type="build", when="@:2") +52d58 +< depends_on("py-setuptools", type="build") +54c60 +< depends_on("py-wheel", type="build", when="@3:") +--- +> depends_on("py-setuptools", type="build") +57,60c63 +< depends_on("py-cached-property@1.5:", type=("build", "run"), when="@:3.6 ^python@:3.7") +< depends_on("py-numpy@1.7:", type=("build", "run"), when="@:2") +< depends_on("py-numpy@1.14.5:", type=("build", "run"), when="@3:") +< depends_on("py-numpy@1.17.5:", type=("build", "run"), when="@3:3.5 ^python@3.8.0:3.8") +--- +> depends_on("py-numpy@1.17.3:", type=("build", "run"), when="@3.9:") +62c65,69 +< depends_on("py-six", type=("build", "run"), when="@:2") +--- +> depends_on("py-numpy@1.17.5:", type=("build", "run"), when="@3:3.5 ^python@3.8.0:3.8") +> depends_on("py-numpy@1.14.5:", type=("build", "run"), when="@3:") +> depends_on("py-numpy@1.7:", type=("build", "run"), when="@:2") +> # https://github.com/h5py/h5py/issues/2353 +> depends_on("py-numpy@:1", when="@:3.10", type=("build", "run")) +66c73,74 +< depends_on("hdf5@1.8.4:1.11 +hl", when="@:2") +--- +> depends_on("hdf5@1.10.4:1.14 +hl", when="@3.10:") +> depends_on("hdf5@1.8.4:1.14 +hl", when="@3.8:3.9") +68c76 +< depends_on("hdf5@1.8.4:1.14 +hl", when="@3.8:") +--- +> depends_on("hdf5@1.8.4:1.11 +hl", when="@:2") +73c81 +< depends_on("py-mpi4py", when="@:2 +mpi", type=("build", "run")) +--- +> depends_on("py-mpi4py@3.1.1:", when="@3.8: +mpi", type=("build", "run")) +74a83,87 +> depends_on("py-mpi4py", when="@:2 +mpi", type=("build", "run")) +> +> # Historical dependencies +> depends_on("py-cached-property@1.5:", type=("build", "run"), when="@:3.6 ^python@:3.7") +> depends_on("py-six", type=("build", "run"), when="@:2") +78c91 +< if self.spec.satisfies("%oneapi@2023.0.0:") or self.spec.satisfies("%cce"): +--- +> if self.spec.satisfies("%oneapi@2023.0.0:"): +###### DIFF py-healpy +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,13c5 +< # Differences for the 'py-healpy' package +< # 6c6 +< # < from spack.package import * +< # --- +< # > from spack import * +< # 28,29d27 +< # < +< # < patch('cfitsio_version_check.patch', when='@1.13:') +< # contribute the patch +--- +> +23,35c15 +< version('1.14.0', sha256='2720b5f96c314bdfdd20b6ffc0643ac8091faefcf8fd20a4083cedff85a66c5e') +< version('1.13.0', sha256='d0ae02791c2404002a09c643e9e50bc58e3d258f702c736dc1f39ce1e6526f73') +< version('1.7.4', sha256='3cca7ed7786ffcca70e2f39f58844667ffb8521180ac890d4da651b459f51442') +< +< depends_on('py-setuptools@3.2:', type='build') +< depends_on('py-pkgconfig', type='build') +< depends_on('py-numpy@1.13:', type=('build', 'run')) +< depends_on('py-scipy', type=('build', 'run')) +< depends_on('py-astropy', type=('build', 'run')) +< depends_on('py-matplotlib', type=('build', 'run')) +< depends_on('py-six', type=('build', 'run')) +< depends_on('cfitsio', type=('build', 'run')) +< depends_on('healpix-cxx', type=('build', 'run')) +--- +> license("GPL-2.0-only") +37c17,33 +< patch('cfitsio_version_check.patch', when='@1.13:') +--- +> version("1.14.0", sha256="2720b5f96c314bdfdd20b6ffc0643ac8091faefcf8fd20a4083cedff85a66c5e") +> version("1.13.0", sha256="d0ae02791c2404002a09c643e9e50bc58e3d258f702c736dc1f39ce1e6526f73") +> version("1.7.4", sha256="3cca7ed7786ffcca70e2f39f58844667ffb8521180ac890d4da651b459f51442") +> +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> depends_on("fortran", type="build") # generated +> +> depends_on("py-setuptools@3.2:", type="build") +> depends_on("py-pkgconfig", type="build") +> depends_on("py-numpy@1.13:", type=("build", "run")) +> depends_on("py-scipy", type=("build", "run")) +> depends_on("py-astropy", type=("build", "run")) +> depends_on("py-matplotlib", type=("build", "run")) +> depends_on("py-six", type=("build", "run")) +> depends_on("cfitsio", type=("build", "run")) +> depends_on("healpix-cxx", type=("build", "run")) +###### DIFF py-maturin +1,3c1 +< +< +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +18a17,23 +> maintainers("teaguesterling") +> +> license("Apache-2.0") +> +> version("1.6.0", sha256="b955025c24c8babc808db49e0ff90db8b4b1320dcc16b14eb26132841737230d") +> version("1.5.1", sha256="3dd834ece80edb866af18cbd4635e0ecac40139c726428d5f1849ae154b26dca") +> version("1.4.0", sha256="ed12e1768094a7adeafc3a74ebdb8dc2201fa64c4e7e31f14cfc70378bf93790") +23,30c28,46 +< depends_on("py-setuptools", type="build") +< depends_on("py-wheel@0.36.2:", type="build") +< depends_on("py-setuptools-rust@1.4:", type="build") +< depends_on("py-tomli@1.1:", when="^python@:3.10", type=("build", "run")) +< depends_on("rust", type=("build", "run")) +< +< def setup_build_environment(self, env): +< env.set("CARGO_HOME", f"{self.stage.source_path}/.cargo") +--- +> with default_args(type="build"): +> depends_on("py-setuptools") +> depends_on("py-wheel@0.36.2:") +> depends_on("py-setuptools-rust@1.4:") +> +> with default_args(type=("build", "run")): +> depends_on("py-tomli@1.1:", when="^python@:3.10") +> for rust, maturin in [ +> ("1.70", "1.5.0"), +> ("1.64", "1.0.0"), +> ("1.62", "0.14.3"), +> ("1.59", "0.13.3"), +> ]: +> depends_on(f"rust@{rust}:", when=f"@{maturin}:") +> +> # May be an accidental dependency, remove in the future +> # https://git.alpinelinux.org/aports/commit/?id=7ad298b467403b96a6b97d050170e367f147a75f +> # https://patchwork.yoctoproject.org/project/oe-core/patch/8803dc101b641c948805cab9e5784c38f43b0e51.1702791173.git.tim.orling@konsulko.com/ +> depends_on("bzip2", when="platform=darwin") +###### DIFF quantum-espresso +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,6d4 +< +< #Added version 7.2 +23c21 +< maintainers("ye-luo", "danielecesarini", "bellenlau") +--- +> maintainers("ye-luo", "bellenlau", "tgorni") +26a25,26 +> license("GPL-2.0-only") +> +27a28,29 +> version("7.3.1", sha256="2c58b8fadfe4177de5a8b69eba447db5e623420b070dea6fd26c1533b081d844") +> version("7.3", sha256="edc2a0f3315c69966df4f82ec86ab9f682187bc9430ef6d2bacad5f27f08972c") +48a51,54 +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> depends_on("fortran", type="build") # generated +> +75,81c81,87 +< depends_on("fftw+openmp", when="^fftw") +< depends_on("amdfftw+openmp", when="^amdfftw") +< depends_on("openblas threads=openmp", when="^openblas") +< depends_on("amdblis threads=openmp", when="^amdblis") +< depends_on("intel-mkl threads=openmp", when="^intel-mkl") +< depends_on("armpl-gcc threads=openmp", when="^armpl-gcc") +< depends_on("acfl threads=openmp", when="^acfl") +--- +> depends_on("fftw+openmp", when="^[virtuals=fftw-api] fftw") +> depends_on("amdfftw+openmp", when="^[virtuals=fftw-api] amdfftw") +> depends_on("openblas threads=openmp", when="^[virtuals=blas] openblas") +> depends_on("amdblis threads=openmp", when="^[virtuals=blas] amdblis") +> depends_on("intel-mkl threads=openmp", when="^[virtuals=blas] intel-mkl") +> depends_on("armpl-gcc threads=openmp", when="^[virtuals=blas] armpl-gcc") +> depends_on("acfl threads=openmp", when="^[virtuals=blas] acfl") +106a113,115 +> # CLOCK variant to display program time in seconds +> variant("clock", default=False, description="Display program time in seconds") +> +129c138 +< depends_on("elpa+openmp", when="+openmp") +--- +> depends_on("elpa", when="+openmp") +136a146,149 +> variant("fox", default=False, description="Enables FoX library") +> with when("+fox"): +> conflicts("@:7.1", msg="+fox variant requires QE >= 7.2") +> +232d244 +< when="build_system=generic", +235,238d246 +< with when("+gipaw"): +< conflicts( +< "@:6.3", msg="gipaw standard support available for QE 6.3 or grater version only" +< ) +246a255,259 +> # If the Intel suite is used for Lapack, it must be used for fftw and vice-versa +> for _intel_pkg in INTEL_MATH_LIBRARIES: +> requires(f"^[virtuals=fftw-api] {_intel_pkg}", when=f"^[virtuals=lapack] {_intel_pkg}") +> requires(f"^[virtuals=lapack] {_intel_pkg}", when=f"^[virtuals=fftw-api] {_intel_pkg}") +> +259a273,281 +> # gipaw +> conflicts( +> "@:6.2", +> when="+gipaw", +> msg="gipaw standard support available for QE 6.3 or greater version only", +> ) +> conflicts("~fox", when="@7.2: +gipaw", msg="gipaw plugin requires FoX") +> conflicts("+gipaw build_system=cmake", when="@:7.1") +> +280a303,307 +> # 7.3 - a compile-time problem fixed in 7.3.1 +> patch_url = "https://gitlab.com/QEF/q-e/-/commit/b98ff7539e5731728d2d49ac01021a57f2594027.diff" +> patch_checksum = "04c125d249d1f076abe04bc4de39bd3b44a41a78d6233b638a17bd96f91443d5" +> patch(patch_url, sha256=patch_checksum, when="@=7.3+elpa build_system=cmake") +> +285c312 +< patch(patch_url, sha256=patch_checksum, when="@:7.1 build_system=cmake") +--- +> patch(patch_url, sha256=patch_checksum, when="@7.1 build_system=cmake") +291c318 +< patch(patch_url, sha256=patch_checksum, when="@:7.1 build_system=cmake") +--- +> patch(patch_url, sha256=patch_checksum, when="@7.1 build_system=cmake") +316c343 +< patch(patch_url, sha256=patch_checksum, when="@6.4:6.4.0+qmcpack") +--- +> patch(patch_url, sha256=patch_checksum, when="@=6.4+qmcpack") +352c379 +< when="+patch@6.3:6.3.0", +--- +> when="+patch@=6.3", +359c386 +< when="+patch@6.3:6.3.0", +--- +> when="+patch@=6.3", +399a427,429 +> # gipaw.x will only be installed with cmake if the qe-gipaw version is >= 5c4a4ce. +> patch("gipaw-eccee44.patch", when="@7.2+gipaw build_system=cmake") +> +412a443 +> self.define_from_variant("QE_CLOCK_SECONDS", "clock"), +415a447,454 +> plugins = [] +> +> if "+fox" in spec: +> cmake_args.append(self.define("QE_ENABLE_FOX", True)) +> +> if "+gipaw" in spec: +> plugins.append("gipaw") +> +428c467,470 +< cmake_args.append(self.define("QE_ENABLE_PW2QMCPACK", True)) +--- +> if spec.satisfies("@:7.0"): +> cmake_args.append(self.define("QE_ENABLE_PW2QMCPACK", True)) +> else: +> plugins.append("pw2qmcpack") +436a479,480 +> if plugins: +> cmake_args.append(self.define("QE_ENABLE_PLUGINS", plugins)) +494c538,539 +< if "^mkl" in spec: +--- +> is_using_intel_libraries = spec["lapack"].name in INTEL_MATH_LIBRARIES +> if is_using_intel_libraries: +536c581 +< if not spec.satisfies("^mkl"): +--- +> if not is_using_intel_libraries: +540c585 +< if "^mkl" in spec: +--- +> if is_using_intel_libraries: +587a633,635 +> if "+fox" in spec: +> options.append("--with-fox=yes") +> +607,608c655,656 +< zlib_libs = spec["zlib"].prefix.lib + " -lz" +< filter_file(zlib_libs, format(spec["zlib"].libs.ld_flags), make_inc) +--- +> zlib_libs = spec["zlib-api"].prefix.lib + " -lz" +> filter_file(zlib_libs, format(spec["zlib-api"].libs.ld_flags), make_inc) +###### DIFF rust +5c5 +< # Latest recipe from spack - fixes ssl certs issue +--- +> +38a39 +> version("1.78.0", sha256="ff544823a5cb27f2738128577f1e7e00ee8f4c83f2a348781ae4fc355e91d5a9") +46a48,50 +> depends_on("c", type="build") +> depends_on("cxx", type="build") +> +56d59 +< depends_on("cmake@3.13.4:", type="build") +58a62 +> depends_on("libssh2") +62a67,73 +> depends_on("zlib-api") +> +> # cmake dependency comes from LLVM. Rust has their own fork of LLVM, with tags corresponding +> # to each Rust release, so it's easy to loop through tags and grep for "cmake_minimum_required" +> depends_on("cmake@3.4.3:", type="build", when="@:1.51") +> depends_on("cmake@3.13.4:", type="build", when="@1.52:1.72") +> depends_on("cmake@3.20.0:", type="build", when="@1.73:") +74a86 +> depends_on("rust-bootstrap", type="build") +80a93,98 +> depends_on("rust-bootstrap@1.77:1.78", type="build", when="@1.78") +> +> # src/llvm-project/llvm/cmake/modules/CheckCompilerVersion.cmake +> conflicts("%gcc@:7.3", when="@1.73:", msg="Host GCC version must be at least 7.4") +> # https://github.com/rust-lang/llvm-project/commit/4d039a7a71899038b3bc6ed6fe5a8a48d915caa0 +> conflicts("%gcc@13:", when="@:1.63", msg="Rust<1.64 not compatible with GCC>=13") +88,89c106,112 +< def determine_version(csl, exe): +< output = Executable(exe)("--version", output=str, error=str) +--- +> def determine_spec_details(cls, prefix, exes_in_prefix): +> rustc_candidates = [x for x in exes_in_prefix if os.path.basename(x) == "rustc"] +> cargo_candidates = [x for x in exes_in_prefix if os.path.basename(x) == "cargo"] +> # Both rustc and cargo must be present +> if not (rustc_candidates and cargo_candidates): +> return +> output = Executable(rustc_candidates[0])("--version", output=str, error=str) +91c114,116 +< return match.group(1) if match else None +--- +> if match: +> version_str = match.group(1) +> return Spec.from_detection(f"rust@{version_str}") +96a122,126 +> # Manually instruct Cargo dependency libssh2-sys to build with +> # the Spack installed libssh2 package. For more info see +> # https://github.com/alexcrichton/ssh2-rs/issues/173 +> env.set("LIBSSH2_SYS_USE_PKG_CONFIG", "1") +> +###### DIFF singularity +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5,35d4 +< # ======================================================================= +< # PAWSEY ADDITIONS +< # ======================================================================= +< # Differences for the 'singularity' package +< # 6c6 +< # < from spack.package import * +< # --- +< # > from spack import * +< # 29,32d28 +< # < version('3.8.7', sha256='3329f2e583f84a8343cb2c0380a1d6cbceafae7d1e633b5cbcadf7143eac859b') +< # < version('3.8.6', sha256='bb5a3b7670ac9c7a4b3ce5b2c9f3d6b5be60e21b08d338c9dfdabb7b2a99f528') +< # < version('3.8.5', sha256='7fff78b5c07b5d4d08269bd267ac5e994390f933321e54efd6b7c86683153ce4') +< # < version('3.8.4', sha256='cb95e6d68b0d20f2b87d60f23a3bf707b7d3e87cee0dd4aa4380f8f481a57ebc') +< # 53,69d48 +< # < +< # < @run_after('install') +< # < def set_pawsey_configuration(self): +< # < configuration_file = join_path(self.spec.prefix.etc, 'singularity', 'singularity.conf') +< # < # do not allow execution of encrypted containers +< # < filter_file(r'^ *allow *container *encrypted *=.*', +< # < 'allow container encrypted = no', +< # < configuration_file) +< # < # do not mount home by default at runtime +< # < filter_file(r'^ *mount *home *=.*', +< # < 'mount home = no', +< # < configuration_file) +< # < # # Cray: use RAMFS +< # < # # beyond CLE6up05, this is not needed any more +< # < # filter_file(r'^ *memory *fs *type *=.*', +< # < # 'memory fs type = ramfs', +< # < # configuration_file) +37d5 +< # For the next spack, move to singularityce package +43,50c11,21 +< '''Singularity is a container technology focused on building portable +< encapsulated environments to support "Mobility of Compute" For older +< versions of Singularity (pre 3.0) you should use singularity-legacy, +< which has a different install base (Autotools). +< +< Needs post-install chmod/chown steps to enable full functionality. +< See package definition or `spack-build-out.txt` build log for details, +< e.g. +--- +> """Singularity is a container technology focused on building portable +> encapsulated environments to support "Mobility of Compute" For older +> versions of Singularity (pre 3.0) you should use singularity-legacy, +> which has a different install base (Autotools). +> +> Needs post-install chmod/chown steps to enable full functionality. +> See package definition or `spack-build-out.txt` build log for details, +> e.g. +> +> tail -15 $(spack location -i singularity)/.spack/spack-build-out.txt +> """ +52,53d22 +< tail -15 $(spack location -i singularity)/.spack/spack-build-out.txt +< ''' +55,56c24,133 +< git = "https://github.com/hpcng/singularity.git" +< url = "https://github.com/hpcng/singularity/releases/download/v3.8.3/singularity-3.8.3.tar.gz" +--- +> git = "https://github.com/hpcng/singularity.git" +> url = "https://github.com/hpcng/singularity/releases/download/v3.8.5/singularity-3.8.5.tar.gz" +> +> license("BSD-3-Clause AND BSD-3-Clause-LBNL") +> +> version( +> "3.8.7", +> sha256="3329f2e583f84a8343cb2c0380a1d6cbceafae7d1e633b5cbcadf7143eac859b", +> deprecated=True, +> ) +> version( +> "3.8.6", +> sha256="bb5a3b7670ac9c7a4b3ce5b2c9f3d6b5be60e21b08d338c9dfdabb7b2a99f528", +> deprecated=True, +> ) +> version( +> "3.8.5", +> sha256="7fff78b5c07b5d4d08269bd267ac5e994390f933321e54efd6b7c86683153ce4", +> deprecated=True, +> ) +> version( +> "3.8.3", +> sha256="2e22eb9ee1b73fdd51b8783149f0e4d83c0d2d8a0c1edf6034157d50eeefb835", +> deprecated=True, +> ) +> version( +> "3.8.0", +> sha256="e9608b0e0a8c805218bbe795e9176484837b2f7fcb95e5469b853b3809a2412e", +> deprecated=True, +> ) +> version( +> "3.7.4", +> sha256="c266369a8bf2747f44e0759858c3fc3b2325b975a8818b2668f0b97b124d0164", +> deprecated=True, +> ) +> version( +> "3.7.3", +> sha256="6667eb8875d2b66d73504f40c956b42b1351744f488d164204376215d885da5c", +> deprecated=True, +> ) +> version( +> "3.7.2", +> sha256="36916222e26fb934404f0766e0ff368edac36d7fc31ca571f5f609466609066b", +> deprecated=True, +> ) +> version( +> "3.7.1", +> sha256="82d2c65063560195ec34551931be3c325b95e8e2009e92755fd7daad346e083c", +> deprecated=True, +> ) +> version( +> "3.7.0", +> sha256="fb96aaf5f462a56a4a5bd2951287bcbbefe8cf543e228e4e955428f386a8d478", +> deprecated=True, +> ) +> version( +> "3.6.4", +> sha256="71233a81d6bb4d686d8dc636b3e3e962a372f54001921c89a12b062cefd9e79f", +> deprecated=True, +> ) +> version( +> "3.6.3", +> sha256="b1a985757a9907d8db0f102fc170a25387e715f7ff31957be964bf47914ea2fd", +> deprecated=True, +> ) +> version( +> "3.6.2", +> sha256="dfd7ec7376ca0321c47787388fb3e781034edf99068f66efc36109e516024d9b", +> deprecated=True, +> ) +> version( +> "3.6.1", +> sha256="6cac56106ee7f209150aaee9f8788d03b58796af1b767245d343f0b8a691121c", +> deprecated=True, +> ) +> version( +> "3.5.3", +> sha256="0c76f1e3808bf4c10e92b17150314b2b816be79f8101be448a6e9d7a96c9e486", +> deprecated=True, +> ) +> version( +> "3.5.2", +> sha256="f9c21e289377a4c40ed7a78a0c95e1ff416dec202ed49a6c616dd2c37700eab8", +> deprecated=True, +> ) +> version( +> "3.4.1", +> sha256="638fd7cc5ab2a20e779b8768f73baf21909148339d6c4edf6ff61349c53a70c2", +> deprecated=True, +> ) +> version( +> "3.4.0", +> sha256="eafb27f1ffbed427922ebe2b5b95d1c9c09bfeb897518867444fe230e3e35e41", +> deprecated=True, +> ) +> version( +> "3.3.0", +> sha256="070530a472e7e78492f1f142c8d4b77c64de4626c4973b0589f0d18e1fcf5b4f", +> deprecated=True, +> ) +> version( +> "3.2.1", +> sha256="d4388fb5f7e0083f0c344354c9ad3b5b823e2f3f27980e56efa7785140c9b616", +> deprecated=True, +> ) +> version( +> "3.1.1", +> sha256="7f0df46458d8894ba0c2071b0848895304ae6b1137d3d4630f1600ed8eddf1a4", +> deprecated=True, +> ) +58c135 +< maintainers = ['alalazo'] +--- +> depends_on("c", type="build") # generated +60,101c137 +< version('master', branch='master') +< version('3.8.7', sha256='3329f2e583f84a8343cb2c0380a1d6cbceafae7d1e633b5cbcadf7143eac859b') +< version('3.8.6', sha256='bb5a3b7670ac9c7a4b3ce5b2c9f3d6b5be60e21b08d338c9dfdabb7b2a99f528') +< version('3.8.5', sha256='7fff78b5c07b5d4d08269bd267ac5e994390f933321e54efd6b7c86683153ce4') +< version('3.8.4', sha256='cb95e6d68b0d20f2b87d60f23a3bf707b7d3e87cee0dd4aa4380f8f481a57ebc') +< version('3.8.3', sha256='2e22eb9ee1b73fdd51b8783149f0e4d83c0d2d8a0c1edf6034157d50eeefb835') +< version('3.8.0', sha256='e9608b0e0a8c805218bbe795e9176484837b2f7fcb95e5469b853b3809a2412e') +< version('3.7.4', sha256='c266369a8bf2747f44e0759858c3fc3b2325b975a8818b2668f0b97b124d0164') +< version('3.7.3', sha256='6667eb8875d2b66d73504f40c956b42b1351744f488d164204376215d885da5c') +< version('3.7.2', sha256='36916222e26fb934404f0766e0ff368edac36d7fc31ca571f5f609466609066b') +< version('3.7.1', sha256='82d2c65063560195ec34551931be3c325b95e8e2009e92755fd7daad346e083c') +< version('3.7.0', sha256='fb96aaf5f462a56a4a5bd2951287bcbbefe8cf543e228e4e955428f386a8d478') +< version('3.6.4', sha256='71233a81d6bb4d686d8dc636b3e3e962a372f54001921c89a12b062cefd9e79f') +< version('3.6.3', sha256='b1a985757a9907d8db0f102fc170a25387e715f7ff31957be964bf47914ea2fd') +< version('3.6.2', sha256='dfd7ec7376ca0321c47787388fb3e781034edf99068f66efc36109e516024d9b') +< version('3.6.1', sha256='6cac56106ee7f209150aaee9f8788d03b58796af1b767245d343f0b8a691121c') +< version('3.5.3', sha256='0c76f1e3808bf4c10e92b17150314b2b816be79f8101be448a6e9d7a96c9e486') +< version('3.5.2', sha256='f9c21e289377a4c40ed7a78a0c95e1ff416dec202ed49a6c616dd2c37700eab8') +< version('3.4.1', sha256='638fd7cc5ab2a20e779b8768f73baf21909148339d6c4edf6ff61349c53a70c2') +< version('3.4.0', sha256='eafb27f1ffbed427922ebe2b5b95d1c9c09bfeb897518867444fe230e3e35e41') +< version('3.3.0', sha256='070530a472e7e78492f1f142c8d4b77c64de4626c4973b0589f0d18e1fcf5b4f') +< version('3.2.1', sha256='d4388fb5f7e0083f0c344354c9ad3b5b823e2f3f27980e56efa7785140c9b616') +< version('3.1.1', sha256='7f0df46458d8894ba0c2071b0848895304ae6b1137d3d4630f1600ed8eddf1a4') +< +< patch('singularity_v3.4.0_remove_root_check.patch', level=0, when='@3.4.0:3.4.1') +< +< @run_after('install') +< def set_pawsey_configuration(self): +< configuration_file = join_path(self.spec.prefix.etc, 'singularity', 'singularity.conf') +< # do not allow execution of encrypted containers +< filter_file(r'^ *allow *container *encrypted *=.*', +< 'allow container encrypted = no', +< configuration_file) +< # do not mount home by default at runtime +< filter_file(r'^ *mount *home *=.*', +< 'mount home = no', +< configuration_file) +< # # Cray: use RAMFS +< # # beyond CLE6up05, this is not needed any more +< # filter_file(r'^ *memory *fs *type *=.*', +< # 'memory fs type = ramfs', +< # configuration_file) +--- +> patch("singularity_v3.4.0_remove_root_check.patch", level=0, when="@3.4.0:3.4.1") +###### DIFF singularityce +220a221,222 +> +> depends_on("c", type="build") # generated +###### DIFF slate +7d6 +< from spack.util.prefix import Prefix +30a30,32 +> "2024.05.31", sha256="9c5d4d6779d8935b6fe41031b46e11ab92102f13c5f684022287c8616661b775" +> ) +> version( +54a57,60 +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> depends_on("fortran", type="build") # generated +> +67c73 +< depends_on("mpi", when="+mpi") +--- +> depends_on("mpi") +85a92 +> depends_on("lapackpp@2024.05.31:", when="@2024.05.31:") +100a108,109 +> requires("+mpi", msg="MPI is required (use of the 'mpi' variant is deprecated)") +> requires("+openmp", msg="OpenMP is required (use of the 'openmp' variant is deprecated)") +132d140 +< "-Duse_openmp=%s" % ("+openmp" in spec), +135d142 +< "-Duse_mpi=%s" % ("+mpi" in spec), +154c161 +< self.cache_extra_test_sources(["examples"]) +--- +> cache_extra_test_sources(self, ["examples"]) +165c172,174 +< def test(self): +--- +> def test_example(self): +> """build and run slate example""" +> +167,168c176 +< print("Skipping: stand-alone tests") +< return +--- +> raise SkipTest("Package must be installed with +mpi and version @2021.05.01 or later") +172c180,181 +< cmake_bin = join_path(self.spec["cmake"].prefix.bin, "cmake") +--- +> cmake = self.spec["cmake"].command +> +179c188,190 +< self.run_test(cmake_bin, ["-DCMAKE_PREFIX_PATH=" + prefixes, ".."]) +--- +> +> cmake("-DCMAKE_PREFIX_PATH=" + prefixes, "..") +> make = which("make") +181d191 +< test_args = ["-n", "4", "./ex05_blas"] +183,233c193,194 +< if not launcher: +< raise RuntimeError("Cannot run tests due to absence of MPI launcher") +< self.run_test(launcher.command, test_args, purpose="SLATE smoke test") +< make("clean") +< +< def get_paths(self): +< rocm_spec = self.spec["hip"] +< rocm_prefix = Prefix(rocm_spec.prefix) +< +< paths = { +< "hip-path": rocm_spec.prefix, +< "rocm-path": rocm_spec.prefix, +< "rocm-device-libs": rocm_spec.prefix, #rocm_prefix, #elf.spec["llvm-amdgpu"].prefix, +< "llvm-amdgpu": rocm_prefix.llvm, +< "hsa-rocr-dev": rocm_prefix.hsa, +< } +< paths["bitcode"] = paths["rocm-device-libs"].amdgcn.bitcode +< +< return paths +< +< def set_variables(self, env): +< if self.spec.satisfies("+rocm"): +< # Note: do not use self.spec[name] here, since not all dependencies +< # have defined prefixes when hip is marked as external. +< paths = self.get_paths() +< +< # Used in hipcc, but only useful when hip is external, since only then +< # there is a common prefix /opt/rocm-x.y.z. +< env.set("ROCM_PATH", paths["rocm-path"]) +< # Just the prefix of hip (used in hipcc) +< env.set("HIP_PATH", paths["hip-path"]) +< env.set("HIP_DEVICE_LIB_PATH", paths["bitcode"]) +< env.set("HIP_CLANG_PATH", paths["llvm-amdgpu"].bin) +< env.set("HSA_PATH", paths["hsa-rocr-dev"]) +< env.set("DEVICE_LIB_PATH", paths["bitcode"]) +< env.set("LLVM_PATH", paths["llvm-amdgpu"]) +< +< env.append_path( +< "HIPCC_COMPILE_FLAGS_APPEND", +< "--rocm-path={0}".format(paths["rocm-path"]), +< separator=" ", +< ) +< +< +< def setup_build_environment(self, env): +< if self.spec.satisfies("+rocm"): +< self.set_variables(env) +< +< def setup_run_environment(self, env): +< if self.spec.satisfies("+rocm"): +< self.set_variables(env) +--- +> assert launcher is not None, "Cannot run tests due to absence of MPI launcher" +> launcher("-n", "4", "./ex05_blas") +###### DIFF tar +1c1 +< # Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +6,12d5 +< #pawsey additions +< # def flag_handler(self, name, flags): +< # if name == "cflags": +< # if self.spec.satisfies("%cce"): +< # flags.append("-Wno-error=incompatible-function-pointer-types") +< # return (flags, None, None) +< +16d8 +< from spack.util.environment import is_system_path +29a22,23 +> license("GPL-3.0-or-later") +> +36a31,32 +> depends_on("c", type="build") # generated +> +72,77d67 +< def flag_handler(self, name, flags): +< if name == "cflags": +< if self.spec.satisfies("%cce"): +< flags.append("-Wno-error=incompatible-function-pointer-types") +< return (flags, None, None) +< +88c78,80 +< if spec["iconv"].name == "libc": +--- +> if spec["iconv"].name == "libiconv": +> args.append(f"--with-libiconv-prefix={spec['iconv'].prefix}") +> else: +90,91d81 +< elif not is_system_path(spec["iconv"].prefix): +< args.append("--with-libiconv-prefix={0}".format(spec["iconv"].prefix)) +###### DIFF trilinos +5,11c5 +< # Latest recipe from spack +< #Pawsey additions: +< #updated flag_handler to handle cce/16.0.1 +< # if name == "cflags": +< # if spec.satisfies("%cce"): +< # flags.append("-Wno-error=implicit-function-declaration") +< # comment out lines 786-793 +--- +> +13a8 +> import re +43c38 +< maintainers("keitat", "sethrj", "kuberry", "jwillenbring", "psakievich") +--- +> maintainers("keitat", "kuberry", "jwillenbring", "psakievich") +50a46 +> version("16.0.0", sha256="46bfc40419ed2aa2db38c144fb8e61d4aa8170eaa654a88d833ba6b92903f309") +78a75,78 +> depends_on("c", type="build") +> depends_on("cxx", type="build") +> depends_on("fortran", type="build", when="+fortran") +> +409c409,411 +< depends_on("kokkos@4.2.01", when="@15.1.0: +kokkos") +--- +> depends_on("kokkos@4.3.01", when="@master: +kokkos") +> depends_on("kokkos@4.3.01", when="@16.0.0 +kokkos") +> depends_on("kokkos@4.2.01", when="@15.1.0:15.1.1 +kokkos") +433c435 +< for plat in ["cray", "darwin", "linux"]: +--- +> for plat in ["darwin", "linux"]: +457c459 +< depends_on("suite-sparse", when="+suite-sparse") +--- +> depends_on("suite-sparse@:7.3.1", when="+suite-sparse") +525,528d526 +< if name == "cflags": +< if spec.satisfies("%cce"): +< flags.append("-Wno-error=implicit-function-declaration") +< +616a615,638 +> if self.spec.satisfies("@master: +kokkos"): +> with open( +> os.path.join(self.stage.source_path, "packages", "kokkos", "CMakeLists.txt") +> ) as f: +> all_txt = f.read() +> r = dict( +> re.findall(r".*set\s?\(\s?Kokkos_VERSION_(MAJOR|MINOR|PATCH)\s?(\d+)", all_txt) +> ) +> kokkos_version_in_trilinos_source = Version( +> ".".join([r["MAJOR"], r["MINOR"], r["PATCH"].zfill(2)]) +> ) +> kokkos_version_specified = spec["kokkos"].version +> if kokkos_version_in_trilinos_source != kokkos_version_specified: +> raise InstallError( +> "For Trilinos@[master,develop], ^kokkos version in spec must " +> "match version in Trilinos source code. Specify ^kokkos@{0} ".format( +> kokkos_version_in_trilinos_source +> ) +> + "for trilinos@[master,develop] instead of ^kokkos@{0}.\n".format( +> kokkos_version_specified +> ) +> + "Trilinos recipe maintainers, please update the ^kokkos version range" +> ) +> +786,793c808,815 +< # if "@15: +python" in spec: +< # binder = spec["binder"].prefix.bin.binder +< # clang_include_dirs = spec["binder"].clang_include_dirs +< # libclang_include_dir = spec["binder"].libclang_include_dir +< # options.append(define("PyTrilinos2_BINDER_EXECUTABLE", binder)) +< # options.append(define("PyTrilinos2_BINDER_clang_include_dirs", clang_include_dirs)) +< # options.append(define("PyTrilinos2_BINDER_LibClang_include_dir", libclang_include_dir)) +< # options.append(define_from_variant("PyTrilinos2_ENABLE_TESTS", "test")) +--- +> if "@15: +python" in spec: +> binder = spec["binder"].prefix.bin.binder +> clang_include_dirs = spec["binder"].clang_include_dirs +> libclang_include_dir = spec["binder"].libclang_include_dir +> options.append(define("PyTrilinos2_BINDER_EXECUTABLE", binder)) +> options.append(define("PyTrilinos2_BINDER_clang_include_dirs", clang_include_dirs)) +> options.append(define("PyTrilinos2_BINDER_LibClang_include_dir", libclang_include_dir)) +> options.append(define_from_variant("PyTrilinos2_ENABLE_TESTS", "test")) +###### DIFF unzip +5c5 +< # latest recipe from spack - removing clang condition in patch and cflags +--- +> +13c13 +< url = "http://downloads.sourceforge.net/infozip/unzip60.tar.gz" +--- +> url = "https://downloads.sourceforge.net/infozip/unzip60.tar.gz" +18a19,21 +> depends_on("c", type="build") # generated +> depends_on("cxx", type="build") # generated +> +23,27d25 +< # The Cray cc wrapper doesn't handle the '-s' flag (strip) cleanly. +< @when("platform=cray") +< def patch(self): +< filter_file(r"^LFLAGS2=.*", "LFLAGS2=", join_path("unix", "configure")) +< +36c34 +< make_args.append('LOC="{}"'.format(" ".join(cflags))) +--- +> make_args.append(f"LOC=\"{' '.join(cflags)}\"") +45c43 +< return "http://downloads.sourceforge.net/infozip/unzip{0}.tar.gz".format(version.joined) +--- +> return f"http://downloads.sourceforge.net/infozip/unzip{version.joined}.tar.gz" +49c47 +< return self.get_make_args() + ["prefix={0}".format(self.prefix), "install"] +--- +> return self.get_make_args() + [f"prefix={self.prefix}", "install"] +###### DIFF vasp +1c1 +< # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other +--- +> # Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +5c5 +< # Pawsey additions: vaspsol, vtst and dftd4 support. +--- +> +7,8d6 +< import grp +< import shutil +13c11 +< class Vasp(MakefilePackage): +--- +> class Vasp(MakefilePackage, CudaPackage): +22c20,21 +< url = "file://{0}/vasp.5.4.4.tgz".format(os.getcwd()) +--- +> url = "file://{0}/vasp.5.4.4.pl2.tgz".format(os.getcwd()) +> maintainers("snehring") +25,104c24,102 +< version('6.3.0', sha256='adcf83bdfd98061016baae31616b54329563aa2739573f069dd9df19c2071ad3') +< version('6.2.1', sha256='d25e2f477d83cb20fce6a2a56dcee5dccf86d045dd7f76d3ae19af8343156a13') +< version('6.1.1', sha256='e37a4dfad09d3ad0410833bcd55af6b599179a085299026992c2d8e319bf6927') +< version('5.4.4', sha256='5bd2449462386f01e575f9adf629c08cb03a13142806ffb6a71309ca4431cfb3') +< # version('5.4.4.pl2', sha256='98f75fd75399a23d76d060a6155f4416b340a1704f256a00146f89024035bc8e') +< +< resource(name='vaspsol', +< git='https://github.com/henniggroup/VASPsol.git', +< tag='V1.0', +< when='+vaspsol') +< +< resource(name='vtst', +< url='http://theory.cm.utexas.edu/code/vtstcode-197.tgz', +< sha256='2017f5129a10e48ef2d928932eb48156dde7b8a9a26e6d0f5c086eae3ee0cb5a', +< when='+vtst') +< +< variant('scalapack', default=False, +< description='Enables build with SCALAPACK') +< +< variant('cuda', default=False, +< description='Enables running on Nvidia GPUs') +< +< variant('vaspsol', default=False, +< description='Enable VASPsol implicit solvation model\n' +< 'https://github.com/henniggroup/VASPsol') +< +< variant('vtst', default=False, +< description='Incorporate VTST extensions\n' +< 'https://theory.cm.utexas.edu/vtsttools/index.html') +< +< variant('dftd4', default=False) +< +< depends_on('rsync', type='build') +< depends_on('openblas') +< depends_on('lapack') +< depends_on('fftw') +< depends_on('mpi', type=('build', 'link', 'run')) +< depends_on('netlib-scalapack', when='+scalapack') +< depends_on('cuda', when='+cuda') +< depends_on('qd', when='%nvhpc') +< depends_on('dftd4', when='+dftd4') +< +< conflicts('%gcc@:8', msg='GFortran before 9.x does not support all features needed to build VASP') +< conflicts('+vaspsol', when='+cuda', msg='+vaspsol only available for CPU') +< conflicts('~scalapack', when='@6.3.0:', msg='scalapack is mandatory for vasp 6.3.0 and later') +< +< # Patch is adapted from patch provided in master branch of vaspsol: +< # https://github.com/henniggroup/VASPsol/raw/master/src/patches/pbz_patch_610 +< # This may have to be further modified for later vasp versions. +< # +< # Note that this patch edits the solvation.F source under the VASPsol directory, +< # which in turn will be copied into the vasp source in the edit stage below. +< patch('vaspsol-6.2.1.patch.1', when='@6.0:+vaspsol') +< +< # VTST patches for src/main.F src/makefile and src/.objects +< patch('vtst-5:6.1.patch', when='@5:6.1+vtst') +< patch('vtst-6.3:.patch', when='@6.3:+vtst') +< conflicts('+vtst', when='@6.2', msg='missing correct VTST patch/sources for VASP 6.2') +< +< parallel = False +< +< # Copy/overwrite vasp sources from vtst or vapsol extensions. +< def patch(self): +< if self.spec.satisfies('+vaspsol'): +< shutil.copy('VASPsol/src/solvation.F', 'src/') +< +< vtst_pfx = 'vtstcode-197/vtstcode' +< vtst_sfx = None +< +< if self.spec.satisfies('@5+vtst'): +< vtst_sfx = '5' +< elif self.spec.satisfies('@6.1+vtst'): +< vtst_sfx = '6.1' +< elif self.spec.satisfies('@6.3+vtst'): +< vtst_sfx = '6.3' +< elif self.spec.satisfies('@6.4+vtst'): +< vtst_sfx = '6.4' +< +< if vtst_sfx: +< shutil.copytree(vtst_pfx+vtst_sfx, 'src/', dirs_exist_ok=True) +--- +> version("6.4.3", sha256="fe30e773f2a3e909b5e0baa9654032dfbdeff7ec157bc348cee7681a7b6c24f4") +> version("6.3.2", sha256="f7595221b0f9236a324ea8afe170637a578cdd5a837cc7679e7f7812f6edf25a") +> version("6.3.0", sha256="adcf83bdfd98061016baae31616b54329563aa2739573f069dd9df19c2071ad3") +> version( +> "6.2.0", +> sha256="49e7ba351bd634bc5f5f67a8ef1e38e64e772857a1c02f602828898a84197e25", +> deprecated=True, +> ) +> version( +> "6.1.1", +> sha256="e37a4dfad09d3ad0410833bcd55af6b599179a085299026992c2d8e319bf6927", +> deprecated=True, +> ) +> version( +> "5.4.4.pl2", +> sha256="98f75fd75399a23d76d060a6155f4416b340a1704f256a00146f89024035bc8e", +> deprecated=True, +> ) +> version( +> "5.4.4", +> sha256="5bd2449462386f01e575f9adf629c08cb03a13142806ffb6a71309ca4431cfb3", +> deprecated=True, +> ) +> +> resource( +> name="vaspsol", +> git="https://github.com/henniggroup/VASPsol.git", +> tag="V1.0", +> when="+vaspsol", +> ) +> +> variant("openmp", default=False, when="@6:", description="Enable openmp build") +> +> variant("scalapack", default=False, when="@:5", description="Enables build with SCALAPACK") +> +> variant("cuda", default=False, description="Enables running on Nvidia GPUs") +> variant("fftlib", default=True, when="@6.2: +openmp", description="Enables fftlib build") +> +> variant( +> "vaspsol", +> default=False, +> when="@:6.2", +> description="Enable VASPsol implicit solvation model\n" +> "https://github.com/henniggroup/VASPsol", +> ) +> variant("shmem", default=True, description="Enable use_shmem build flag") +> variant("hdf5", default=False, when="@6.2:", description="Enabled HDF5 support") +> +> depends_on("rsync", type="build") +> depends_on("blas") +> depends_on("lapack") +> depends_on("fftw-api") +> depends_on("fftw+openmp", when="+openmp ^[virtuals=fftw-api] fftw") +> depends_on("amdfftw+openmp", when="+openmp ^[virtuals=fftw-api] amdfftw") +> depends_on("amdblis threads=openmp", when="+openmp ^[virtuals=blas] amdblis") +> depends_on("openblas threads=openmp", when="+openmp ^[virtuals=blas] openblas") +> depends_on("mpi", type=("build", "link", "run")) +> # fortran oddness requires the below +> depends_on("openmpi%aocc", when="%aocc ^[virtuals=mpi] openmpi") +> depends_on("openmpi%gcc", when="%gcc ^[virtuals=mpi] openmpi") +> depends_on("scalapack", when="+scalapack") +> # wiki (and makefiles) suggest scalapack is expected in 6: +> depends_on("scalapack", when="@6:") +> depends_on("nccl", when="@6.3: +cuda") +> depends_on("hdf5+fortran+mpi", when="+hdf5") +> # at the very least the nvhpc mpi seems required +> depends_on("nvhpc+mpi+lapack+blas", when="%nvhpc") +> +> conflicts( +> "%gcc@:8", msg="GFortran before 9.x does not support all features needed to build VASP" +> ) +> conflicts("+vaspsol", when="+cuda", msg="+vaspsol only available for CPU") +> requires("%nvhpc", when="@6.3: +cuda", msg="vasp requires nvhpc to build the openacc build") +> # the mpi compiler wrappers in nvhpc assume nvhpc is the underlying compiler, seemingly +> conflicts("^[virtuals=mpi] nvhpc", when="%gcc", msg="nvhpc mpi requires nvhpc compiler") +> conflicts("^[virtuals=mpi] nvhpc", when="%aocc", msg="nvhpc mpi requires nvhpc compiler") +> conflicts( +> "cuda_arch=none", when="@6.3: +cuda", msg="CUDA arch required when building openacc port" +> ) +107,120c105,158 +< # Modify the platform specific arch/makefile.include.xxx file, then +< # copy to makefile.include in the top level directory. +< +< # Following has been adapted from spack development branch, and special casing +< # 6.3.0 for gcc as we're not needing nvhpc support for setonix and aocc is currently +< # broken. +< +< if spec.satisfies('@6.3.0:'): +< makefile_base = 'makefile.include.' +< if '%gcc' in spec: +< if '+openmp' in spec: +< make_include = join_path('arch', 'makefile.include.gnu_omp') +< else: +< make_include = join_path('arch', 'makefile.include.gnu') +--- +> cpp_options = [ +> "-DMPI", +> "-DMPI_BLOCK=8000", +> "-Duse_collective", +> "-DCACHE_SIZE=4000", +> "-Davoidalloc", +> "-Duse_bse_te", +> "-Dtbdyn", +> "-Dfock_dblbuf", +> ] +> objects_lib = ["linpack_double.o"] +> llibs = list(self.compiler.stdcxx_libs) +> cflags = ["-fPIC", "-DAAD_"] +> fflags = ["-w"] +> incs = [spec["fftw-api"].headers.include_flags] +> +> if self.spec.satisfies("@6:"): +> cpp_options.append("-Dvasp6") +> +> llibs.extend([spec["blas"].libs.ld_flags, spec["lapack"].libs.ld_flags]) +> +> fc = [spec["mpi"].mpifc] +> fcl = [spec["mpi"].mpifc] +> +> include_prefix = "" +> omp_flag = "-fopenmp" +> +> if spec.satisfies("+shmem"): +> cpp_options.append("-Duse_shmem") +> objects_lib.append("getshmem.o") +> +> if spec.satisfies("@:6.2"): +> include_prefix = "linux_" +> include_string = f"makefile.include.{include_prefix}" +> +> # gcc +> if spec.satisfies("%gcc"): +> include_string += "gnu" +> if spec.satisfies("+openmp"): +> include_string += "_omp" +> make_include = join_path("arch", include_string) +> # nvhpc +> elif spec.satisfies("%nvhpc"): +> qd_root = join_path( +> spec["nvhpc"].prefix, +> f"Linux_{spec['nvhpc'].target.family.name}", +> str(spec["nvhpc"].version.dotted), +> "compilers", +> "extras", +> "qd", +> ) +> nvroot = join_path(spec["nvhpc"].prefix, f"Linux_{spec['nvhpc'].target.family.name}") +> if spec.satisfies("@6.3:"): +> cpp_options.extend(['-DHOST=\\"LinuxNV\\"', "-Dqd_emulate"]) +122,124c160 +< suffix = '' +< if '+openmp' in spec: +< suffix = '_omp' +--- +> cpp_options.extend(['-DHOST=\\"LinuxPGI\\"', "-DPGI16", "-Dqd_emulate", "-Mfree"]) +126,131c162,191 +< make_include = join_path('arch', 'makefile.include.{0}{1}'. +< format(spec.compiler.name), suffix) +< else: +< if '%gcc' in spec: +< if '+openmp' in spec: +< make_include = join_path('arch', 'makefile.include.linux_gnu_omp') +--- +> fflags.extend(["-Mnoupcase", "-Mbackslash", "-Mlarge_arrays"]) +> incs.append(f"-I{join_path(qd_root, 'include', 'qd')}") +> llibs.extend([f"-L{join_path(qd_root, 'lib')}", "-lqdmod", "-lqd"]) +> +> if spec.satisfies("@:6.2"): +> make_include = join_path("arch", f"{include_string}pgi") +> filter_file("pgcc", spack_cc, make_include) +> filter_file("pgc++", spack_cxx, make_include, string=True) +> filter_file("pgfortran", spack_fc, make_include) +> else: +> include_string += "nvhpc" +> if spec.satisfies("+openmp"): +> include_string += "_omp" +> if spec.satisfies("+cuda"): +> include_string += "_acc" +> make_include = join_path("arch", include_string) +> omp_flag = "-mp" +> filter_file(r"^QD[ \t]*\??=.*$", f"QD = {qd_root}", make_include) +> filter_file("NVROOT[ \t]*=.*$", f"NVROOT = {nvroot}", make_include) +> # aocc +> elif spec.satisfies("%aocc"): +> cpp_options.extend(['-DHOST=\\"LinuxAMD\\"', "-Dshmem_bcast_buffer", "-DNGZhalf"]) +> fflags.extend(["-fno-fortran-main", "-Mbackslash", "-ffunc-args-alias"]) +> if spec.satisfies("@6.3.0: ^amdfftw@4.0:"): +> cpp_options.extend(["-Dfftw_cache_plans", "-Duse_fftw_plan_effort"]) +> if spec.satisfies("+openmp"): +> if spec.satisfies("@6.3.2:"): +> include_string += "aocc_ompi_aocl_omp" +> elif spec.satisfies("@=6.3.0"): +> include_string += "gnu_ompi_aocl_omp" +133,150c193,198 +< make_include = join_path('arch', 'makefile.include.linux_gnu') +< elif '%nvhpc' in spec: +< make_include = join_path('arch', 'makefile.include.linux_pgi') +< filter_file('-pgc++libs', '-c++libs', make_include, string=True) +< filter_file('pgcc', spack_cc, make_include) +< filter_file('pgc++', spack_cxx, make_include, string=True) +< filter_file('pgfortran', spack_fc, make_include) +< filter_file('/opt/pgi/qd-2.3.17/install/include', +< spec['qd'].prefix.include, make_include) +< filter_file('/opt/pgi/qd-2.3.17/install/lib', +< spec['qd'].prefix.lib, make_include) +< elif '%aocc' in spec: +< if '+openmp' in spec: +< copy( +< join_path('arch', 'makefile.include.linux_gnu_omp'), +< join_path('arch', 'makefile.include.linux_aocc_omp') +< ) +< make_include = join_path('arch', 'makefile.include.linux_aocc_omp') +--- +> include_string += "gnu_omp" +> else: +> if spec.satisfies("@6.3.2:"): +> include_string += "aocc_ompi_aocl" +> elif spec.satisfies("@=6.3.0"): +> include_string += "gnu_ompi_aocl" +152,156c200,204 +< copy( +< join_path('arch', 'makefile.include.linux_gnu'), +< join_path('arch', 'makefile.include.linux_aocc') +< ) +< make_include = join_path('arch', 'makefile.include.linux_aocc') +--- +> include_string += "gnu" +> make_include = join_path("arch", include_string) +> filter_file("^CC_LIB[ ]{0,}=.*$", f"CC_LIB={spack_cc}", make_include) +> if spec.satisfies("@6:6.3.0"): +> filter_file("gcc", f"{spack_fc} -Mfree", make_include, string=True) +158,159c206 +< 'gcc', '{0} {1}'.format(spack_cc, '-Mfree'), +< make_include, string=True +--- +> "-fallow-argument-mismatch", " -fno-fortran-main", make_include, string=True +161,222c208,219 +< filter_file('g++', spack_cxx, make_include, string=True) +< filter_file('^CFLAGS_LIB[ ]{0,}=.*$', +< 'CFLAGS_LIB = -O3', make_include) +< filter_file('^FFLAGS_LIB[ ]{0,}=.*$', +< 'FFLAGS_LIB = -O2', make_include) +< filter_file('^OFLAG[ ]{0,}=.*$', +< 'OFLAG = -O3', make_include) +< filter_file('^FC[ ]{0,}=.*$', +< 'FC = {0}'.format(spec['mpi'].mpifc), +< make_include, string=True) +< filter_file('^FCL[ ]{0,}=.*$', +< 'FCL = {0}'.format(spec['mpi'].mpifc), +< make_include, string=True) +< else: +< suffix = '' +< if '+openmp' in spec: +< suffix = '_omp' +< +< make_include = join_path('arch', 'makefile.include.linux_{0}{1}'. +< format(spec.compiler.name), suffix) +< +< shutil.copy(make_include, 'makefile.include') +< +< # This bunch of 'filter_file()' is to make these options settable +< # as environment variables +< filter_file('^CPP_OPTIONS[ ]{0,}=[ ]{0,}', +< 'CPP_OPTIONS ?= ', +< 'makefile.include') +< filter_file('^FFLAGS[ ]{0,}=[ ]{0,}', +< 'FFLAGS ?= ', +< 'makefile.include') +< +< filter_file('^LIBDIR *=.*$', '', 'makefile.include') +< filter_file('^BLAS *=.*$', 'BLAS ?=', 'makefile.include') +< filter_file('^LAPACK *=.*$', 'LAPACK ?=', 'makefile.include') +< filter_file('^FFTW *\?=.*$', 'FFTW ?=', 'makefile.include') +< filter_file('^MPI_INC *=.*$', 'MPI_INC ?=', 'makefile.include') +< filter_file('-DscaLAPACK.*$\n', '', 'makefile.include') +< filter_file('^SCALAPACK.*$', '', 'makefile.include') +< filter_file('^OBJECTS_LIB *= *', 'OBJECTS_LIB = getshmem.o ', 'makefile.include') +< +< if "+dftd4" in spec: +< with open("makefile.include", "a") as fp: +< fp.write(f"LLIBS += -L{self.spec['dftd4'].prefix.lib} -ldftd4\n") +< fp.write(f"INCS += -I{self.spec['dftd4'].prefix.include}\n") +< fp.write(f"INCS += -I{self.spec['dftd4'].prefix.include}/dftd4/{self.compiler.name}-{self.compiler.version}\n") +< +< if '+cuda' in spec: +< filter_file('^OBJECTS_GPU[ ]{0,}=.*$', +< 'OBJECTS_GPU ?=', +< 'makefile.include') +< +< filter_file('^CPP_GPU[ ]{0,}=.*$', +< 'CPP_GPU ?=', +< 'makefile.include') +< +< filter_file('^CFLAGS[ ]{0,}=.*$', +< 'CFLAGS ?=', +< 'makefile.include') +< +< def setup_build_environment(self, spack_env): +< spec = self.spec +--- +> # fj +> elif spec.satisfies("@6.4.3: %fj target=a64fx"): +> include_string += "fujitsu_a64fx" +> omp_flag = "-Kopenmp" +> fc.extend(["simd_nouse_multiple_structures", "-X03"]) +> fcl.append("simd_nouse_multiple_structures") +> cpp_options.append('-DHOST=\\"FJ-A64FX\\"') +> fflags.append("-Koptmsg=2") +> llibs.extend(["-SSL2BLAMP", "-SCALAPACK"]) +> if spec.satisfies("+openmp"): +> include_string += "_omp" +> make_include = join_path("arch", include_string) +224,230d220 +< cpp_options = ['-DMPI -DMPI_BLOCK=8000', +< '-Duse_collective', '-DCACHE_SIZE=4000', +< '-Davoidalloc', '-Duse_bse_te', +< '-Dtbdyn', '-Duse_shmem'] +< if '%nvhpc' in self.spec: +< cpp_options.extend(['-DHOST=\\"LinuxPGI\\"', '-DPGI16', +< '-Dqd_emulate']) +231a222,232 +> if spec.satisfies("+openmp"): +> make_include = join_path("arch", f"{include_string}{spec.compiler.name}_omp") +> # if the above doesn't work, fallback to gnu +> if not os.path.exists(make_include): +> make_include = join_path("arch", f"{include_string}.gnu_omp") +> else: +> make_include = join_path( +> "arch", f"{include_string}{include_prefix}" + spec.compiler.name +> ) +> if not os.path.exists(make_include): +> make_include = join_path("arch", f"{include_string}.gnu") +233,280c234,328 +< if self.spec.satisfies('@6:'): +< cpp_options.append('-Dvasp6') +< if self.spec.satisfies('+dftd4'): +< cpp_options.append('-DDFTD4') +< +< cflags = ['-fPIC', '-DADD_'] +< fflags = [] +< if '%gcc' in spec or '%intel' in spec: +< fflags.append('-w') +< elif '%nvhpc' in spec: +< fflags.extend(['-Mnoupcase', '-Mbackslash', '-Mlarge_arrays']) +< +< spack_env.set('BLAS', spec['blas'].libs.ld_flags) +< spack_env.set('LAPACK', spec['lapack'].libs.ld_flags) +< spack_env.set('FFTW', spec['fftw'].prefix) +< spack_env.set('FFTW_ROOT', spec['fftw'].prefix) +< spack_env.set('MPI_INC', spec['mpi'].prefix.include) +< +< if '%nvhpc' in spec: +< spack_env.set('QD', spec['qd'].prefix) +< +< if '+scalapack' in spec or spec.satisfies('@6.3.0:'): +< cpp_options.append('-DscaLAPACK') +< spack_env.set('SCALAPACK', spec['netlib-scalapack'].libs.ld_flags) +< +< if '+cuda' in spec: +< cpp_gpu = ['-DCUDA_GPU', '-DRPROMU_CPROJ_OVERLAP', +< '-DCUFFT_MIN=28', '-DUSE_PINNED_MEMORY'] +< +< objects_gpu = ['fftmpiw.o', 'fftmpi_map.o', 'fft3dlib.o', +< 'fftw3d_gpu.o', 'fftmpiw_gpu.o'] +< +< cflags.extend(['-DGPUSHMEM=300', '-DHAVE_CUBLAS']) +< +< spack_env.set('CUDA_ROOT', spec['cuda'].prefix) +< spack_env.set('CPP_GPU', ' '.join(cpp_gpu)) +< spack_env.set('OBJECTS_GPU', ' '.join(objects_gpu)) +< +< if '+vaspsol' in spec: +< cpp_options.append('-Dsol_compat') +< +< if spec.satisfies('%gcc@10:'): +< fflags.append('-fallow-argument-mismatch') +< +< # Finally +< spack_env.set('CPP_OPTIONS', ' '.join(cpp_options)) +< spack_env.set('CFLAGS', ' '.join(cflags)) +< spack_env.set('FFLAGS', ' '.join(fflags)) +--- +> +> if spec.satisfies("+openmp"): +> cpp_options.extend(["-Dsysv", "-D_OPENMP"]) +> llibs.extend(["-ldl", spec["fftw-api:openmp"].libs.ld_flags]) +> fc.append(omp_flag) +> fcl.append(omp_flag) +> else: +> llibs.append(spec["fftw-api"].libs.ld_flags) +> +> if spec.satisfies("^scalapack"): +> cpp_options.append("-DscaLAPACK") +> if spec.satisfies("%nvhpc"): +> llibs.append("-Mscalapack") +> else: +> llibs.append(spec["scalapack"].libs.ld_flags) +> +> if spec.satisfies("+cuda"): +> if spec.satisfies("@6.3:"): +> # openacc +> cpp_options.extend(["-D_OPENACC", "-DUSENCCL"]) +> llibs.extend(["-cudalib=cublas,cusolver,cufft,nccl", "-cuda"]) +> fc.append("-acc") +> fcl.append("-acc") +> cuda_flags = [f"cuda{str(spec['cuda'].version.dotted[0:2])}", "rdc"] +> for f in spec.variants["cuda_arch"].value: +> cuda_flags.append(f"cc{f}") +> fc.append(f"-gpu={','.join(cuda_flags)}") +> fcl.append(f"-gpu={','.join(cuda_flags)}") +> fcl.extend(list(self.compiler.stdcxx_libs)) +> cc = [spec["mpi"].mpicc, "-acc"] +> if spec.satisfies("+openmp"): +> cc.append(omp_flag) +> filter_file("^CC[ \t]*=.*$", f"CC = {' '.join(cc)}", make_include) +> +> else: +> # old cuda thing +> cflags.extend(["-DGPUSHMEM=300", "-DHAVE_CUBLAS"]) +> filter_file(r"^CUDA_ROOT[ \t]*\?=.*$", spec["cuda"].prefix, make_include) +> +> if spec.satisfies("+vaspsol"): +> cpp_options.append("-Dsol_compat") +> copy("VASPsol/src/solvation.F", "src/") +> +> if spec.satisfies("+hdf5"): +> cpp_options.append("-DVASP_HDF5") +> llibs.append(spec["hdf5:fortran"].libs.ld_flags) +> incs.append(spec["hdf5"].headers.include_flags) +> +> if spec.satisfies("%gcc@10:"): +> fflags.append("-fallow-argument-mismatch") +> +> filter_file(r"^VASP_TARGET_CPU[ ]{0,}\?=.*", "", make_include) +> +> if spec.satisfies("@:5"): +> filter_file("-DscaLAPACK.*$\n", "", make_include) +> +> if spec.satisfies("+fftlib"): +> cxxftlib = ( +> f"CXX_FFTLIB = {spack_cxx} {omp_flag}" +> f" -DFFTLIB_THREADSAFE{' '.join(list(self.compiler.stdcxx_libs))}" +> ) +> filter_file("^#FCL[ ]{0,}=fftlib.o", "FCL += fftlib/fftlib.o", make_include) +> filter_file("^#CXX_FFTLIB.*$", cxxftlib, make_include) +> filter_file( +> "^#INCS_FFTLIB.*$", +> f"INCS_FFTLIB = -I./include {spec['fftw-api'].headers.include_flags}", +> make_include, +> ) +> filter_file(r"#LIBS[ \t]*\+=.*$", "LIBS = fftlib", make_include) +> llibs.append("-ldl") +> fcl.append(join_path("fftlib", "fftlib.o")) +> +> # clean multiline CPP options at begining of file +> filter_file(r"^[ \t]+(-D[a-zA-Z0-9_=]+[ ]*)+[ ]*\\*$", "", make_include) +> # replace relevant variables in the makefile.include +> filter_file("^FFLAGS[ \t]*=.*$", f"FFLAGS = {' '.join(fflags)}", make_include) +> filter_file(r"^FFLAGS[ \t]*\+=.*$", "", make_include) +> filter_file( +> "^CPP_OPTIONS[ \t]*=.*$", f"CPP_OPTIONS = {' '.join(cpp_options)}", make_include +> ) +> filter_file(r"^INCS[ \t]*\+?=.*$", f"INCS = {' '.join(incs)}", make_include) +> filter_file(r"^LLIBS[ \t]*\+?=.*$", f"LLIBS = {' '.join(llibs)}", make_include) +> filter_file(r"^LLIBS[ \t]*\+=[ ]*-.*$", "", make_include) +> filter_file("^CFLAGS[ \t]*=.*$", f"CFLAGS = {' '.join(cflags)}", make_include) +> filter_file( +> "^OBJECTS_LIB[ \t]*=.*$", f"OBJECTS_LIB = {' '.join(objects_lib)}", make_include +> ) +> filter_file("^FC[ \t]*=.*$", f"FC = {' '.join(fc)}", make_include) +> filter_file("^FCL[ \t]*=.*$", f"FCL = {' '.join(fcl)}", make_include) +> +> os.rename(make_include, "makefile.include") +> +> def setup_build_environment(self, spack_env): +> if self.spec.satisfies("%nvhpc +cuda"): +> spack_env.set("NVHPC_CUDA_HOME", self.spec["cuda"].prefix) +283,284c331,335 +< if '+cuda' in self.spec: +< make('gpu', 'gpu_ncl') +--- +> if spec.satisfies("@:6.2"): +> if spec.satisfies("+cuda"): +> make("DEPS=1", "all") +> else: +> make("DEPS=1", "std", "gam", "ncl") +286c337 +< make('std', 'gam', 'ncl') +--- +> make("DEPS=1, all") +289,298c340 +< install_tree('bin/', prefix.bin) +< +< newgrp = "vasp" +< if spec.satisfies('@6:'): +< newgrp = "vasp6" +< +< gid = grp.getgrnam(newgrp).gr_gid +< for dpath, dnames, fnames in os.walk(prefix.bin): +< for fn in fnames: +< os.chown(os.path.join(dpath, fn), -1, gid) +--- +> install_tree("bin/", prefix.bin) +###### DIFF vdifio +###### DIFF wcstools +###### DIFF wsclean diff --git a/repo/packages/not_in_spack.txt b/repo/packages/not_in_spack.txt new file mode 100644 index 00000000..4c465faa --- /dev/null +++ b/repo/packages/not_in_spack.txt @@ -0,0 +1,16 @@ +diff: ../../../spack/var/spack/repos/builtin/packages/amdgromacs/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/ansys-fluids/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/ansys-fluidstructures/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/ansys-structures/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/birli/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/calceph/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/everybeam/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/giant-squid/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/hyperbeam/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/mwalib/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/psrfits-utils/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/py-erfa/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/py-funcsigs/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/vdifio/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/wcstools/package.py: No such file or directory +diff: ../../../spack/var/spack/repos/builtin/packages/wsclean/package.py: No such file or directory From 3f96f4b6cf992340c70aaf825a64aa695f269756 Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Thu, 31 Oct 2024 10:27:51 +0800 Subject: [PATCH 20/21] Removes Amber recipe. Customisations have been merged to main Spack. https://github.com/spack/spack/pull/45844 --- repo/packages/amber/aarch64.patch | 24 - .../amber/ambertools_configure2.patch | 294 ----------- .../ambertools_configure2_cray_shasta.patch | 475 ------------------ .../ambertools_configure2_for_netcdf.patch | 225 --------- repo/packages/amber/ambertools_makefile.patch | 50 -- repo/packages/amber/cpptraj_configure.patch | 58 --- .../amber/cpptraj_configure_netcdf.patch | 127 ----- repo/packages/amber/nvhpc-boost.patch | 61 --- repo/packages/amber/nvhpc.patch | 20 - repo/packages/amber/package.py | 253 ---------- repo/packages/amber/pmemd_nfe.patch | 20 - repo/packages/amber/ppc64le.patch | 24 - repo/packages/amber/sander_mt19937.patch | 20 - repo/packages/amber/sander_sebomd.patch | 76 --- repo/packages/amber/sebomd_fix.patch | 78 --- 15 files changed, 1805 deletions(-) delete mode 100644 repo/packages/amber/aarch64.patch delete mode 100644 repo/packages/amber/ambertools_configure2.patch delete mode 100644 repo/packages/amber/ambertools_configure2_cray_shasta.patch delete mode 100644 repo/packages/amber/ambertools_configure2_for_netcdf.patch delete mode 100644 repo/packages/amber/ambertools_makefile.patch delete mode 100644 repo/packages/amber/cpptraj_configure.patch delete mode 100644 repo/packages/amber/cpptraj_configure_netcdf.patch delete mode 100644 repo/packages/amber/nvhpc-boost.patch delete mode 100644 repo/packages/amber/nvhpc.patch delete mode 100644 repo/packages/amber/package.py delete mode 100644 repo/packages/amber/pmemd_nfe.patch delete mode 100644 repo/packages/amber/ppc64le.patch delete mode 100644 repo/packages/amber/sander_mt19937.patch delete mode 100644 repo/packages/amber/sander_sebomd.patch delete mode 100644 repo/packages/amber/sebomd_fix.patch diff --git a/repo/packages/amber/aarch64.patch b/repo/packages/amber/aarch64.patch deleted file mode 100644 index f73e3ce7..00000000 --- a/repo/packages/amber/aarch64.patch +++ /dev/null @@ -1,24 +0,0 @@ ---- a/ambertools_tmpdir/AmberTools/src/fftw-3.3/config.guess 2020-09-30 13:28:45.035344970 -0700 -+++ b/ambertools_tmpdir/AmberTools/src/fftw-3.3/config.guess 2020-09-30 13:28:55.534923364 -0700 -@@ -858,6 +858,9 @@ - i*86:Minix:*:*) - echo ${UNAME_MACHINE}-pc-minix - exit ;; -+ aarch64:Linux:*:*) -+ echo aarch64-unknown-linux-gnu -+ exit ;; - alpha:Linux:*:*) - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in - EV5) UNAME_MACHINE=alphaev5 ;; ---- a/ambertools_tmpdir/AmberTools/src/xblas/config/config.guess 2020-09-30 15:30:11.573779015 -0700 -+++ b/ambertools_tmpdir/AmberTools/src/xblas/config/config.guess 2020-09-30 15:30:46.932366326 -0700 -@@ -863,6 +863,9 @@ - i*86:Minix:*:*) - echo ${UNAME_MACHINE}-pc-minix - exit ;; -+ aarch64:Linux:*:*) -+ echo aarch64-unknown-linux-gnu -+ exit ;; - alpha:Linux:*:*) - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in - EV5) UNAME_MACHINE=alphaev5 ;; diff --git a/repo/packages/amber/ambertools_configure2.patch b/repo/packages/amber/ambertools_configure2.patch deleted file mode 100644 index 27ee359f..00000000 --- a/repo/packages/amber/ambertools_configure2.patch +++ /dev/null @@ -1,294 +0,0 @@ ---- a/ambertools_tmpdir/AmberTools/src/configure2 2022-01-17 13:00:06.000000000 +0800 -+++ b/ambertools_tmpdir/AmberTools/src/configure2 2022-01-14 15:59:29.000000000 +0800 -@@ -11,7 +11,7 @@ - cat<' flag to" -+ echo " specify system NetCDF to use. On cray systems you can usually" -+ echo " load the system NetCDF with 'module load cray-netcdf' or" -+ echo " 'module load netcdf'." -+ exit 1 -+ fi -+ # For some reason if static linking of NetCDF is not forced you end up -+ # with lots of missing symbols. -+ netcdfstatic='yes' -+ -+ # Currently xleap on cray will not build due to errors like -+ #/usr/lib64/libX11.a(ClDisplay.o): In function `XCloseDisplay': -+ #/usr/src/packages/BUILD/libX11-1.1.5/src/ClDisplay.c:78: undefined reference to `xcb_disconnect' -+ if [ "$noX11" = 'false' ] ; then -+ echo "Error: Cannot build XLEaP with cray compilers." -+ echo " Please re-run configure with the '-noX11' flag to use this compiler." -+ exit 1 -+ fi -+ -+ freeformat_flag="-ffree-form" -+ -+ #PMEMD Specifics -+ # PMEMD right now with cray requires external FFTW3 library -+ cat > conftest.f90 < /dev/null -+ status=$? -+ if [ $status -gt 0 ]; then -+ echo "Error: FFTW3 library not found." -+ echo " Ensure FFTW3 library can be found by your compiler." -+ echo " On cray systems this can usually be done with 'module load fftw'" -+ exit 1 -+ fi -+ echo "OK" -+ /bin/rm -f conftest.f90 conftest$objsuffix conftest$suffix -+ -+ #pmemd_fpp_flags='-DPUBFFT' -+ pmemd_fpp_flags='-DFFTW_FFT' -+ pmemd_foptflags="$foptflags $cray_omp_flag" -+ pmemd_coptflags="$coptflags $cray_omp_flag" -+ -+ if [ "$debug" = 'yes' ]; then -+ pmemd_foptflags="-g $pmemd_foptflags" -+ pmemd_coptflags="-g $pmemd_coptflags" -+ fi -+ -+ #CUDA Specifics -+ if [ "$cuda" = 'yes' ]; then -+ pmemd_cu_includes='-I$(CUDA_HOME)/include -IB40C' -+ pmemd_cu_defines='-DCUDA' -+ pmemd_cu_libs="./cuda/cuda.a -L\$(CUDA_HOME)/lib64 -L\$(CUDA_HOME)/lib -lcurand -lcufft -lcudart $fc_cxx_link_flag" -+ pbsa_cu_libs="-L\$(CUDA_HOME)/lib64 -L\$(CUDA_HOME)/lib -lcublas -lcusparse -lcudart $fc_cxx_link_flag" -+ if [ "$optimise" = 'no' ]; then -+ nvcc="$nvcc -use_fast_math -O0 " -+ else -+ nvcc="$nvcc -use_fast_math -O3 " -+ fi -+ if [ "$mpi" = 'yes' ]; then -+ mpi_inc=`(mpicc -show 2>&1) | awk 'BEGIN{i=0} {while (i < NF) {if ( substr($i, 1, 2) == "-I" ) {printf("%s ", $i);}; i++;}}'` -+ pmemd_cu_includes="$pmemd_cu_includes $mpi_inc" -+ pmemd_cu_defines="$pmemd_cu_defines -DMPI -DMPICH_IGNORE_CXX_SEEK" -+ pmemd_coptflags="$coptflags -DMPICH_IGNORE_CXX_SEEK" -+ fi -+ fi -+ ;; -+ -+ - #################### clang #### - clang) - if [ "$intelmpi" = 'yes' ]; then -@@ -2324,7 +2489,7 @@ - fi - fi - -- extract_and_emit_compiler_versions "-v" -+ extract_and_emit_compiler_versions "--version" - ;; - #################### unknown choice ####### - *) -@@ -2534,7 +2699,9 @@ - - echo "" - echo "Testing the $cc compiler:" --echo " $cc $cflags $cnooptflags -o testp$suffix testp.c" -+echo " $cc with testp$suffix testp.c" -+echo " cflags $cflags " -+echo " nooptflags $cnooptflags " - $cc $cflags $cnooptflags -o testp$suffix testp.c - $wine ./testp$suffix | grep "testing a C program" > /dev/null - status=$? -@@ -3183,6 +3350,9 @@ - if [ "$intelmpi" = "yes" ]; then - mpicc="MPICC=mpiicc" - fi -+ if [ "$craympi" = "yes" ]; then -+ mpicc="MPICC=cc" -+ fi - if [ "$debug" = "yes" ]; then - enable_debug="--enable-debug=yes --enable-debug-malloc=yes --enable-debug-alignment=yes" - fi -@@ -3381,6 +3551,10 @@ - if [ -z "$MPICC" ]; then cc="mpiicc"; else cc="$MPICC"; fi - if [ -z "$MPICXX" ]; then cplusplus="mpiicpc"; else cplusplus="$MPICXX"; fi - if [ -z "$MPIF90" ]; then fc="mpiifort"; else fc="$MPIF90"; fi -+ elif [ "$craympi" = 'yes' ]; then -+ if [ -z "$MPICC" ]; then cc="cc"; else cc="$MPICC"; fi -+ if [ -z "$MPICXX" ]; then cplusplus="CC"; else cplusplus="$MPICXX"; fi -+ if [ -z "$MPIF90" ]; then fc="ftn"; else fc="$MPIF90"; fi - else - if [ -z "$MPICC" ]; then cc="mpicc"; else cc="$MPICC"; fi - if [ -z "$MPICXX" ]; then cplusplus="mpicxx"; else cplusplus="$MPICXX"; fi diff --git a/repo/packages/amber/ambertools_configure2_cray_shasta.patch b/repo/packages/amber/ambertools_configure2_cray_shasta.patch deleted file mode 100644 index a9a03a3a..00000000 --- a/repo/packages/amber/ambertools_configure2_cray_shasta.patch +++ /dev/null @@ -1,475 +0,0 @@ ---- a/ambertools_tmpdir/AmberTools/src/configure2 2020-04-28 09:19:43.000000000 +0800 -+++ b/ambertools_tmpdir/AmberTools/src/configure2 2022-02-14 11:13:05.0000000 +0800 -@@ -11,7 +11,7 @@ - cat< -+ Specify an external NetCDF C build to use. -+ -+ --with-netcdf-fortran -+ Specify an external NetCDF Fortran build to use. -+ - -netcdfstatic Force static linking to the external NetCDF specified via - the --with-netcdf option. - -@@ -488,6 +494,7 @@ - has_boost='' - installtype='serial' - intelmpi='no' -+craympi='no' - is_mac='no' - ldflags='' - ld='ld ' -@@ -509,6 +516,8 @@ - mpinab='' - mpi='no' - netcdf_dir='' -+netcdfc_dir='' -+netcdff_dir='' - netcdf_flag='' - netcdfstatic='no' - pmemd_gem='no' -@@ -607,6 +616,8 @@ - --skip-python) skippython='yes' ;; - --with-python) shift; python="$1";; - --with-netcdf) shift; netcdf_dir="$1";; -+ --with-netcdf-c) shift; netcdfc_dir="$1";; -+ --with-netcdf-fortran) shift; netcdff_dir="$1";; - --with-pnetcdf) shift; pnetcdf_dir="$1" ;; - --python-install) shift; python_install="$1";; - --miniconda) answer='y';; -@@ -1375,7 +1386,7 @@ - fflags="$fflags -g" - fi - -- extract_and_emit_compiler_versions '-v' -+ extract_and_emit_compiler_versions '--version' - - if [ $cc_version_major -ge 4 -a $cc_version_minor -ge 2 -a "$optimise" = "yes" ]; then - if [ $sse = 'yes' ]; then -@@ -1590,7 +1601,7 @@ - fflags="$fflags -g -debug all" - fi - -- extract_and_emit_compiler_versions '-v' -+ extract_and_emit_compiler_versions '--version' - - # Intel 18.0.x not ready for prime time; srb mar 26, 2018; see - # [AMBER-Developers] Intel compilers and Amber18 -@@ -2044,21 +2055,18 @@ - #################### cray ####### - cray) - test -z "$pic" && pic="-fpic" -- if [ "$intelmpi" = 'yes' ]; then -- echo "Intel MPI requires the intel compilers." -- exit 1 -- fi -+ craympi='yes' - ld='ftn' - flibs_arch="" - flibsf_arch= - cc=cc -- cflags="$pic" -+ cflags="$pic -O3" - ambercflags="" - cplusplus=CC -- cxxflags="$pic" -+ cxxflags="$pic -O3" - ambercxxflags="" - fc=ftn -- fflags="$pic" -+ fflags="$pic -O3" - # The -lstdc++ flag gives lots of duplicate symbol errors with cray - fc_cxx_link_flag="" - -@@ -2083,6 +2091,7 @@ - # -D_FILE_OFFSET_BITS etc.) cray compilers need '-h gnu'. - # Also, the fortran compile requires '-emf' to force - # the build of module files with all-lowercase names. -+ # old cray compilers - if [ "$optimise" = 'no' ]; then - cflags="$cflags -O0 $cray_omp_flag -h gnu" - cnooptflags="" -@@ -2113,7 +2122,7 @@ - fflags="$fflags -g" - fi - -- extract_and_emit_compiler_versions '-V' -+ extract_and_emit_compiler_versions '--version' - - # Set alignment of fortran compiler - fcreal8="-s real64" -@@ -2208,6 +2217,169 @@ - fi - ;; - -+#################### cray-shasta-gnu ####### -+cray-shasta-gnu) -+ test -z "$pic" && pic="-fpic" -+ craympi='yes' -+ ld='ftn' -+ flibs_arch="-lgfortran -w" -+ flibsf_arch= -+ cc=cc -+ cflags="$pic -O3" -+ ambercflags="" -+ cplusplus=CC -+ cxxflags="$pic -O3" -+ ambercxxflags="" -+ fc=ftn -+ fflags="$pic -O3 -fallow-argument-mismatch -fallow-invalid-boz" -+ # The -lstdc++ flag gives lots of duplicate symbol errors with cray -+ fc_cxx_link_flag="-lstdc++" -+ -+ -+ if [ "$openmp" = 'yes' ]; then -+ omp_flag="-DOPENMP" -+ #flibs_arch="$flibs_arch -fopenmp" -+ #flibsf_arch="$flibsf_arch -fopenmp -+ cray_omp_flag=" -fopenmp " -+ elif [ "$mpi" = 'no' ]; then -+ #Note OMP is required for PMEMD MPI now so leave it on if mpi is true. -+ # OMP is enabled by default. Disable. -+ cray_omp_flag="" -+ fi -+ -+ # If -noopt has been requested, force lack of optimisation; -+ # otherwise, use the default levels. Since cflags, cxxflags -+ # and fflags are used everywhere, and *optflags and -+ # *nooptflags are not (some parts of Amber and AmberTools use -+ # neither *optflags nor *nooptflags), we'll put -O0 in cflags -+ # and so forth instead. -+ # NOTE: In order for GNU-like defines to work (e.g. -+ # -D_FILE_OFFSET_BITS etc.) cray compilers need '-h gnu'. -+ # Also, the fortran compile requires '-emf' to force -+ # the build of module files with all-lowercase names. -+ if [ "$optimise" = 'no' ]; then -+ cflags="$cflags -O0 $cray_omp_flag " -+ cnooptflags="" -+ coptflags="" -+ cxxflags="$cxxflags -O0 $cray_omp_flag " -+ cxxnooptflags="" -+ cxxoptflags="$pic" -+ fflags="$fflags -O0 $cray_omp_flag" -+ fnooptflags="" -+ foptflags="" -+ else -+ cflags="$cflags -O3 $cray_omp_flag " -+ cnooptflags="" -+ coptflags="" -+ cxxflags="$cxxflags -O3 $cray_omp_flag " -+ cxxnooptflags="" -+ cxxoptflags="$pic" -+ fflags="$fflags -O3 $cray_omp_flag" -+ fnooptflags="" -+ foptflags="" -+ fi -+ -+ # Debugging options -+ if [ "$debug" = 'yes' ]; then -+ cflags="$cflags -g" -+ cxxflags="$cxxflags -g" -+ fflags="$fflags -g" -+ fi -+ -+ extract_and_emit_compiler_versions '--version' -+ -+ # Set alignment of fortran compiler -+ fcreal8="-s real64" -+ -+ # For now, fftw3 is not compiled and rism is disabled. -+ # if [ "$rism" != 'no' ]; then -+ # echo "Error: RISM currently not built with cray compilers." -+ # echo " Please re-run configure with the '-nofftw3' flag to use this compiler:" -+ # echo " `mod_command_args '-rism' '-nofftw3'`" -+ # exit 1 -+ # fi -+ -+ if [ "$cygwin" = 'yes' -o "$windows" = 'yes' ]; then -+ echo "Error: cygwin not supported with cray compilers." -+ exit 1 -+ fi -+ -+ # The bundled NetCDF will not build with cray compilers. Require external. -+ if [ "$bintraj" = 'yes' -a -z "$netcdfc_dir" -a -z "$netcdff_dir" ] ; then -+ echo "Error: Bundled NetCDF cannot be used with cray compilers." -+ echo " Please re-run configure with the '--with-netcdf-c ' flag to" -+ echo " specify system NetCDF C to use. " -+ echo " Please re-run configure with the '--with-netcdf-fortran ' flag to" -+ echo " specify system NetCDF Fortran to use. " -+ exit 1 -+ fi -+ # For some reason if static linking of NetCDF is not forced you end up -+ # with lots of missing symbols. -+ # looks like netcdfstatic is also used to indicate use external netcdf -+ #netcdfstatic='yes' -+ -+ # Currently xleap on cray will not build due to errors like -+ #/usr/lib64/libX11.a(ClDisplay.o): In function `XCloseDisplay': -+ #/usr/src/packages/BUILD/libX11-1.1.5/src/ClDisplay.c:78: undefined reference to `xcb_disconnect' -+ if [ "$noX11" = 'false' ] ; then -+ echo "Error: Cannot build XLEaP with cray compilers." -+ echo " Please re-run configure with the '-noX11' flag to use this compiler." -+ exit 1 -+ fi -+ -+ freeformat_flag="-ffree-form" -+ -+# #PMEMD Specifics -+# cat > conftest.f90 < /dev/null -+# status=$? -+# if [ $status -gt 0 ]; then -+# echo "Error: FFTW3 library not found." -+# echo " Ensure FFTW3 library can be found by your compiler." -+# exit 1 -+# fi -+# echo "OK" -+# /bin/rm -f conftest.f90 conftest$objsuffix conftest$suffix -+ -+ pmemd_fpp_flags='-DPUBFFT -DGNU_HACKS' -+ pmemd_foptflags="$foptflags $cray_omp_flag -fallow-invalid-boz -fallow-argument-mismatch" -+ pmemd_coptflags="$coptflags $cray_omp_flag" -+ -+ if [ "$debug" = 'yes' ]; then -+ pmemd_foptflags="-g $pmemd_foptflags" -+ pmemd_coptflags="-g $pmemd_coptflags" -+ fi -+ -+ #CUDA Specifics -+ if [ "$cuda" = 'yes' ]; then -+ pmemd_cu_includes='-I$(CUDA_HOME)/include -IB40C' -+ pmemd_cu_defines='-DCUDA' -+ pmemd_cu_libs="./cuda/cuda.a -L\$(CUDA_HOME)/lib64 -L\$(CUDA_HOME)/lib -lcurand -lcufft -lcudart $fc_cxx_link_flag" -+ pbsa_cu_libs="-L\$(CUDA_HOME)/lib64 -L\$(CUDA_HOME)/lib -lcublas -lcusparse -lcudart $fc_cxx_link_flag" -+ if [ "$optimise" = 'no' ]; then -+ nvcc="$nvcc -use_fast_math -O0 " -+ else -+ nvcc="$nvcc -use_fast_math -O3 " -+ fi -+ if [ "$mpi" = 'yes' ]; then -+ mpi_inc=`(mpicc -show 2>&1) | awk 'BEGIN{i=0} {while (i < NF) {if ( substr($i, 1, 2) == "-I" ) {printf("%s ", $i);}; i++;}}'` -+ pmemd_cu_includes="$pmemd_cu_includes $mpi_inc" -+ pmemd_cu_defines="$pmemd_cu_defines -DMPI -DMPICH_IGNORE_CXX_SEEK" -+ pmemd_coptflags="$coptflags -DMPICH_IGNORE_CXX_SEEK" -+ fi -+ fi -+ ;; -+ -+ - #################### clang #### - clang) - if [ "$intelmpi" = 'yes' ]; then -@@ -2324,7 +2496,7 @@ - fi - fi - -- extract_and_emit_compiler_versions "-v" -+ extract_and_emit_compiler_versions "--version" - ;; - #################### unknown choice ####### - *) -@@ -2534,7 +2706,9 @@ - - echo "" - echo "Testing the $cc compiler:" --echo " $cc $cflags $cnooptflags -o testp$suffix testp.c" -+echo " $cc with testp$suffix testp.c" -+echo " cflags $cflags " -+echo " nooptflags $cnooptflags " - $cc $cflags $cnooptflags -o testp$suffix testp.c - $wine ./testp$suffix | grep "testing a C program" > /dev/null - status=$? -@@ -2751,11 +2925,12 @@ - cflags="$cflags -DBINTRAJ" - pmemd_coptflags="$pmemd_coptflags -DBINTRAJ" - fppflags="$fppflags -DBINTRAJ" -- if [ "$netcdf_dir" = '' ]; then -+ if [ "$netcdf_dir" = '' -a "$netcdfc_dir" = '' -a "$netcdff_dir" = '' ]; then - # Use bundled NetCDF library. - if [ "$netcdfstatic" != 'no' ] ; then - echo "Error: -netcdfstatic requires an external NetCDF specified via" - echo " the --with-netcdf option." -+ echo " Or --with-netcdf-c and --with-netcdf-fortran option." - exit 1 - fi - # Initially set full paths for use with test_netcdf_compile. -@@ -2893,38 +3068,77 @@ - netcdf="\$(INCDIR)/netcdf.mod" - else - # A NetCDF directory was specified. Check that library exists and compiles -- printf "\tUsing external NetCDF in '$netcdf_dir'\n" -- netcdfinc="-I"$netcdf_dir"/include" -- if [ "${netcdf_dir}" != '/usr' -a "$netcdf_dir" != '/usr/' ]; then -- netcdf_flag="-L${netcdf_dir}/lib $netcdf_flag" -- fi -- netcdf=$netcdf_dir"/include/netcdf.mod" -- if [ "$netcdfstatic" = 'no' ] ; then -- if [ "${netcdf_dir}" != '/usr' -a "${netcdf_dir}" != '/usr/' ]; then -- netcdfflagc="-L${netcdf_dir}/lib -lnetcdf" -- netcdfflagf="-L${netcdf_dir}/lib -lnetcdff -lnetcdf" -- else -- netcdfflagc="-lnetcdf" -- netcdfflagf="-lnetcdff -lnetcdf" -- fi -- else # Force static linking to netcdf -- printf "\tForcing static linking to external NetCDF\n" -- netcdfflagc=$netcdf_dir"/lib/libnetcdf.a" -- if [ ! -e "$netcdfflagc" ]; then -- echo "Error: '$netcdfflagc' not found." -- exit 1 -+ printf "\tUsing external NetCDF in '$netcdf_dir' or " -+ printf "NetCDF-C '$netcdfc_dir' with NetCDF-Fortran '$netcdff_dir' \n" -+ -+ # if individual netcdfc and fortran passed -+ if [ "$netcdf_dir" = '' ]; then -+ netcdfinc="-I"$netcdfc_dir"/include " -+ netcdfinc+="-I"$netcdff_dir"/include" -+ # netcdf c and fortran directories passed -+ if [ "${netcdfc_dir}" != '/usr' -a "$netcdfc_dir" != '/usr/' ]; then -+ netcdf_flag="-L${netcdfc_dir}/lib $netcdf_flag" -+ fi -+ if [ "${netcdff_dir}" != '/usr' -a "$netcdff_dir" != '/usr/' ]; then -+ netcdf_flag="-L${netcdff_dir}/lib $netcdf_flag" -+ fi -+ netcdf=$netcdff_dir"/include/netcdf.mod" -+ if [ "$netcdfstatic" = 'no' ] ; then -+ if [ "${netcdfc_dir}" != '/usr' -a "${netcdfc_dir}" != '/usr/' ]; then -+ netcdfflagc="-L${netcdfc_dir}/lib -lnetcdf" -+ netcdfflagf="-L${netcdff_dir}/lib -lnetcdff -lnetcdf" -+ else -+ netcdfflagc="-lnetcdf" -+ netcdfflagf="-lnetcdff -lnetcdf" -+ fi -+ else # Force static linking to netcdf -+ printf "\tForcing static linking to external NetCDF\n" -+ netcdfflagc=$netcdfc_dir"/lib/libnetcdf.a" -+ if [ ! -e "$netcdfflagc" ]; then -+ echo "Error: '$netcdfflagc' not found." -+ exit 1 -+ fi -+ netcdfflagf=$netcdff_dir"/lib/libnetcdff.a" -+ if [ ! -e "$netcdfflagf" ]; then -+ echo "Error: '$netcdfflagf' not found." -+ exit 1 -+ fi -+ netcdfflagf="$netcdfflagf $netcdfflagc" - fi -- netcdfflagf=$netcdf_dir"/lib/libnetcdff.a" -- if [ ! -e "$netcdfflagf" ]; then -- echo "Error: '$netcdfflagf' not found." -- exit 1 -+ else -+ netcdfinc="-I"$netcdf_dir"/include" -+ if [ "${netcdf_dir}" != '/usr' -a "$netcdf_dir" != '/usr/' ]; then -+ netcdf_flag="-L${netcdf_dir}/lib $netcdf_flag" -+ fi -+ netcdf=$netcdf_dir"/include/netcdf.mod" -+ if [ "$netcdfstatic" = 'no' ] ; then -+ if [ "${netcdf_dir}" != '/usr' -a "${netcdf_dir}" != '/usr/' ]; then -+ netcdfflagc="-L${netcdf_dir}/lib -lnetcdf" -+ netcdfflagf="-L${netcdf_dir}/lib -lnetcdff -lnetcdf" -+ else -+ netcdfflagc="-lnetcdf" -+ netcdfflagf="-lnetcdff -lnetcdf" -+ fi -+ else # Force static linking to netcdf -+ printf "\tForcing static linking to external NetCDF\n" -+ netcdfflagc=$netcdf_dir"/lib/libnetcdf.a" -+ if [ ! -e "$netcdfflagc" ]; then -+ echo "Error: '$netcdfflagc' not found." -+ exit 1 -+ fi -+ netcdfflagf=$netcdf_dir"/lib/libnetcdff.a" -+ if [ ! -e "$netcdfflagf" ]; then -+ echo "Error: '$netcdfflagf' not found." -+ exit 1 -+ fi -+ netcdfflagf="$netcdfflagf $netcdfflagc" - fi -- netcdfflagf="$netcdfflagf $netcdfflagc" - fi - # Test netcdf compilation - test_netcdf_compile verbose - if [ $? -gt 0 ]; then -- echo "Error: Could not compile using NetCDF in '$netcdf_dir'" -+ echo "Error: Could not compile using NetCDF in '$netcdf_dir' or " -+ echo "NetCDF-C in '$netcdfc_dir' and NetCDF-Fortran in '$netcdff_dir'" - exit 1 - fi - echo "OK" -@@ -3183,6 +3397,9 @@ - if [ "$intelmpi" = "yes" ]; then - mpicc="MPICC=mpiicc" - fi -+ if [ "$craympi" = "yes" ]; then -+ mpicc="MPICC=cc" -+ fi - if [ "$debug" = "yes" ]; then - enable_debug="--enable-debug=yes --enable-debug-malloc=yes --enable-debug-alignment=yes" - fi -@@ -3381,6 +3598,10 @@ - if [ -z "$MPICC" ]; then cc="mpiicc"; else cc="$MPICC"; fi - if [ -z "$MPICXX" ]; then cplusplus="mpiicpc"; else cplusplus="$MPICXX"; fi - if [ -z "$MPIF90" ]; then fc="mpiifort"; else fc="$MPIF90"; fi -+ elif [ "$craympi" = 'yes' ]; then -+ if [ -z "$MPICC" ]; then cc="cc"; else cc="$MPICC"; fi -+ if [ -z "$MPICXX" ]; then cplusplus="CC"; else cplusplus="$MPICXX"; fi -+ if [ -z "$MPIF90" ]; then fc="ftn"; else fc="$MPIF90"; fi - else - if [ -z "$MPICC" ]; then cc="mpicc"; else cc="$MPICC"; fi - if [ -z "$MPICXX" ]; then cplusplus="mpicxx"; else cplusplus="$MPICXX"; fi -@@ -3574,6 +3795,8 @@ - fi - if [ ! -z "$netcdf_dir" ] ; then - CPPTRAJOPTS="$CPPTRAJOPTS --with-netcdf=$netcdf_dir" -+elif [ ! -z "$netcdfc_dir" ]; then -+ CPPTRAJOPTS="$CPPTRAJOPTS --with-netcdf-c=$netcdfc_dir --with-netcdf-fortran=$netcdff_dir" - else - CPPTRAJOPTS="$CPPTRAJOPTS --with-netcdf=$CPPTRAJHOME" - fi -@@ -3799,6 +4022,16 @@ - elif [ "$installtype" = 'openmp' ] ; then - installtype='cray_openmp' - fi -+elif [ "$compiler" = 'cray-shasta-gnu' ] ; then -+ echo "Warning: Currently PBSA and related programs (MMPBSA, Sander, etc)" -+ echo " do not build with cray compilers." -+ if [ "$installtype" = 'serial' ] ; then -+ installtype='cray_serial' -+ elif [ "$installtype" = 'parallel' ] ; then -+ installtype='cray_parallel' -+ elif [ "$installtype" = 'openmp' ] ; then -+ installtype='cray_openmp' -+ fi - fi - - #------------------------------------------------------------------------------ -@@ -4049,7 +4282,7 @@ - PYTHON=$python - PYTHON_INSTALL=$python_install_string - SKIP_PYTHON=$skippython --PYTHONPATH=\$(AMBER_PREFIX)/lib/python$python_ver/site-packages -+PYTHONPATH=$PYTHONPATH:\$(AMBER_PREFIX)/lib/python$python_ver/site-packages - PYTHONLOG=$pythonlog - - PYSANDER=$pysander diff --git a/repo/packages/amber/ambertools_configure2_for_netcdf.patch b/repo/packages/amber/ambertools_configure2_for_netcdf.patch deleted file mode 100644 index 602ad05c..00000000 --- a/repo/packages/amber/ambertools_configure2_for_netcdf.patch +++ /dev/null @@ -1,225 +0,0 @@ ---- /home/pelahi/tmp/build_stage/spack-stage-amber-20-32owemucowv2n7wep65uirrn6qcuwvcz/spack-src/AmberTools/src/configure2 2022-02-11 16:22:21.000000000 +0800 -+++ /home/pelahi/amber20_src/AmberTools/src/configure2 2022-02-11 16:35:52.000000000 +0800 -@@ -191,6 +191,12 @@ - have both C and Fortran interfaces. Required for Cray - compilers. - -+ --with-netcdf-c -+ Specify an external NetCDF C build to use. -+ -+ --with-netcdf-fortran -+ Specify an external NetCDF Fortran build to use. -+ - -netcdfstatic Force static linking to the external NetCDF specified via - the --with-netcdf option. - -@@ -510,6 +516,8 @@ - mpinab='' - mpi='no' - netcdf_dir='' -+netcdfc_dir='' -+netcdff_dir='' - netcdf_flag='' - netcdfstatic='no' - pmemd_gem='no' -@@ -608,6 +616,8 @@ - --skip-python) skippython='yes' ;; - --with-python) shift; python="$1";; - --with-netcdf) shift; netcdf_dir="$1";; -+ --with-netcdf-c) shift; netcdfc_dir="$1";; -+ --with-netcdf-fortran) shift; netcdff_dir="$1";; - --with-pnetcdf) shift; pnetcdf_dir="$1" ;; - --python-install) shift; python_install="$1";; - --miniconda) answer='y';; -@@ -1251,24 +1261,40 @@ - sm30flags='-gencode arch=compute_30,code=sm_30' - - cudaversion=`$nvcc --version | grep 'release' | cut -d' ' -f5 | cut -d',' -f1` -- if [ "$cudaversion" = "9.0" -o "$cudaversion" = "9.1" -o "$cudaversion" = "9.2" -o \ -- "$cudaversion" = "10.0" -o "$cudaversion" = "10.1" -o "$cudaversion" = "10.2" ]; then -+ if [ "$cudaversion" = "11.0" -o "$cudaversion" = "11.1" ]; then -+ # Implement the standard, not warp synchronous, compilation -+ sm80flags='-gencode arch=compute_80,code=sm_80' -+ sm75flags='-gencode arch=compute_75,code=sm_75' -+ sm70flags='-gencode arch=compute_70,code=sm_70' -+ echo "CUDA Version $cudaversion detected" -+ echo "Configuring for SM5.0, SM5.2, SM5.3, SM6.0, SM6.1, SM7.0, SM7.5 and SM8.0" -+ nvccflags="$sm50flags $sm52flags $sm53flags $sm60flags $sm61flags $sm70flags $sm75flags $sm80flags -Wno-deprecated-declarations" -+ -+ elif [ "$cudaversion" = "10.0" -o "$cudaversion" = "10.1" -o "$cudaversion" = "10.2" ]; then -+ echo "CUDA Version $cudaversion detected" -+ echo "Configuring for SM3.0, SM3.5, SM3.7, SM5.0, SM5.2, SM5.3, SM6.0, SM6.1, SM7.0 and SM7.5" -+ nvccflags="$sm30flags $sm35flags $sm37flags $sm50flags $sm52flags $sm53flags $sm60flags $sm61flags $sm70flags $sm75flags -Wno-deprecated-declarations" -+ -+ elif [ "$cudaversion" = "9.0" -o "$cudaversion" = "9.1" -o "$cudaversion" = "9.2" ]; then - echo "CUDA Version $cudaversion detected" - echo "Configuring for SM3.0, SM3.5, SM3.7, SM5.0, SM5.2, SM5.3, SM6.0, SM6.1 and SM7.0" - nvccflags="$sm30flags $sm35flags $sm37flags $sm50flags $sm52flags $sm53flags $sm60flags $sm61flags $sm70flags -Wno-deprecated-declarations" -+ - elif [ "$cudaversion" = "8.0" ]; then - echo "CUDA Version $cudaversion detected" - echo "Configuring for SM3.0, SM3.5, SM3.7, SM5.0, SM5.2, SM5.3, SM6.0 and SM6.1" - echo "BE AWARE: CUDA 8.0 does not support V100, GV100, Titan-V or later GPUs." - nvccflags="$sm30flags $sm35flags $sm37flags $sm50flags $sm52flags $sm53flags $sm60flags $sm61flags" -+ - elif [ "$cudaversion" = "7.5" ]; then - echo "CUDA Version $cudaversion detected" - echo "Configuring for SM3.0, SM3.5, SM3.7, SM5.0, SM5.2 and SM5.3" - echo "BE AWARE: CUDA 7.5 does not support GTX-1080, Titan-XP, DGX-1, V100 or other Pascal/Volta based or later GPUs." - nvccflags="$sm30flags $sm35flags $sm37flags $sm50flags $sm52flags $sm53flags" -+ - else - echo "Error: Unsupported CUDA version $cudaversion detected." -- echo " Amber requires CUDA version 7.5, 8.0, 9.0-9.2, or 10.0-10.2" -+ echo " Amber requires CUDA version 7.5, 8.0, 9.0-9.2, 10.0-10.2 or 11.0-11.1" - exit 1 - fi - nvcc="$nvcc $nvccflags" -@@ -2280,16 +2306,17 @@ - fi - - # The bundled NetCDF will not build with cray compilers. Require external. -- if [ "$bintraj" = 'yes' -a -z "$netcdf_dir" ] ; then -+ if [ "$bintraj" = 'yes' -a -z "$netcdfc_dir" -a -z "$netcdff_dir" ] ; then - echo "Error: Bundled NetCDF cannot be used with cray compilers." -- echo " Please re-run configure with the '--with-netcdf ' flag to" -- echo " specify system NetCDF to use. On cray systems you can usually" -- echo " load the system NetCDF with 'module load cray-netcdf' or" -- echo " 'module load netcdf'." -+ echo " Please re-run configure with the '--with-netcdf-c ' flag to" -+ echo " specify system NetCDF C to use. " -+ echo " Please re-run configure with the '--with-netcdf-fortran ' flag to" -+ echo " specify system NetCDF Fortran to use. " - exit 1 - fi - # For some reason if static linking of NetCDF is not forced you end up - # with lots of missing symbols. -+ # looks like netcdfstatic is also used to indicate use external netcdf - netcdfstatic='yes' - - # Currently xleap on cray will not build due to errors like -@@ -2902,11 +2929,12 @@ - cflags="$cflags -DBINTRAJ" - pmemd_coptflags="$pmemd_coptflags -DBINTRAJ" - fppflags="$fppflags -DBINTRAJ" -- if [ "$netcdf_dir" = '' ]; then -+ if [ "$netcdf_dir" = '' -a "$netcdfc_dir" = '' -a "$netcdff_dir" = '' ]; then - # Use bundled NetCDF library. - if [ "$netcdfstatic" != 'no' ] ; then - echo "Error: -netcdfstatic requires an external NetCDF specified via" - echo " the --with-netcdf option." -+ echo " Or --with-netcdf-c and --with-netcdf-fortran option." - exit 1 - fi - # Initially set full paths for use with test_netcdf_compile. -@@ -3044,38 +3072,75 @@ - netcdf="\$(INCDIR)/netcdf.mod" - else - # A NetCDF directory was specified. Check that library exists and compiles -- printf "\tUsing external NetCDF in '$netcdf_dir'\n" -- netcdfinc="-I"$netcdf_dir"/include" -- if [ "${netcdf_dir}" != '/usr' -a "$netcdf_dir" != '/usr/' ]; then -- netcdf_flag="-L${netcdf_dir}/lib $netcdf_flag" -- fi -- netcdf=$netcdf_dir"/include/netcdf.mod" -- if [ "$netcdfstatic" = 'no' ] ; then -- if [ "${netcdf_dir}" != '/usr' -a "${netcdf_dir}" != '/usr/' ]; then -- netcdfflagc="-L${netcdf_dir}/lib -lnetcdf" -- netcdfflagf="-L${netcdf_dir}/lib -lnetcdff -lnetcdf" -- else -- netcdfflagc="-lnetcdf" -- netcdfflagf="-lnetcdff -lnetcdf" -- fi -- else # Force static linking to netcdf -- printf "\tForcing static linking to external NetCDF\n" -- netcdfflagc=$netcdf_dir"/lib/libnetcdf.a" -- if [ ! -e "$netcdfflagc" ]; then -- echo "Error: '$netcdfflagc' not found." -- exit 1 -+ printf "\tUsing external NetCDF in '$netcdf_dir' or '$netcdfc_dir' with '$netcdff_dir' \n" -+ -+ # if individual netcdfc and fortran passed -+ if [ "$netcdf_dir" = '' ] -+ netcdfcinc="-I"$netcdfc_dir"/include" -+ netcdffinc="-I"$netcdff_dir"/include" -+ # netcdf c and fortran directories passed -+ if [ "${netcdfc_dir}" != '/usr' -a "$netcdfc_dir" != '/usr/' ]; then -+ netcdf_flag="-L${netcdfc_dir}/lib $netcdf_flag" -+ fi -+ if [ "${netcdff_dir}" != '/usr' -a "$netcdff_dir" != '/usr/' ]; then -+ netcdf_flag="-L${netcdff_dir}/lib $netcdf_flag" -+ fi -+ netcdf=$netcdff_dir"/include/netcdf.mod" -+ if [ "$netcdfstatic" = 'no' ] ; then -+ if [ "${netcdfc_dir}" != '/usr' -a "${netcdfc_dir}" != '/usr/' ]; then -+ netcdfflagc="-L${netcdfc_dir}/lib -lnetcdf" -+ netcdfflagf="-L${netcdff_dir}/lib -lnetcdff -lnetcdf" -+ else -+ netcdfflagc="-lnetcdf" -+ netcdfflagf="-lnetcdff -lnetcdf" -+ fi -+ else # Force static linking to netcdf -+ printf "\tForcing static linking to external NetCDF\n" -+ netcdfflagc=$netcdfc_dir"/lib/libnetcdf.a" -+ if [ ! -e "$netcdfflagc" ]; then -+ echo "Error: '$netcdfflagc' not found." -+ exit 1 -+ fi -+ netcdfflagf=$netcdff_dir"/lib/libnetcdff.a" -+ if [ ! -e "$netcdfflagf" ]; then -+ echo "Error: '$netcdfflagf' not found." -+ exit 1 -+ fi -+ netcdfflagf="$netcdfflagf $netcdfflagc" - fi -- netcdfflagf=$netcdf_dir"/lib/libnetcdff.a" -- if [ ! -e "$netcdfflagf" ]; then -- echo "Error: '$netcdfflagf' not found." -- exit 1 -+ else -+ netcdfinc="-I"$netcdf_dir"/include" -+ if [ "${netcdf_dir}" != '/usr' -a "$netcdf_dir" != '/usr/' ]; then -+ netcdf_flag="-L${netcdf_dir}/lib $netcdf_flag" -+ fi -+ netcdf=$netcdf_dir"/include/netcdf.mod" -+ if [ "$netcdfstatic" = 'no' ] ; then -+ if [ "${netcdf_dir}" != '/usr' -a "${netcdf_dir}" != '/usr/' ]; then -+ netcdfflagc="-L${netcdf_dir}/lib -lnetcdf" -+ netcdfflagf="-L${netcdf_dir}/lib -lnetcdff -lnetcdf" -+ else -+ netcdfflagc="-lnetcdf" -+ netcdfflagf="-lnetcdff -lnetcdf" -+ fi -+ else # Force static linking to netcdf -+ printf "\tForcing static linking to external NetCDF\n" -+ netcdfflagc=$netcdf_dir"/lib/libnetcdf.a" -+ if [ ! -e "$netcdfflagc" ]; then -+ echo "Error: '$netcdfflagc' not found." -+ exit 1 -+ fi -+ netcdfflagf=$netcdf_dir"/lib/libnetcdff.a" -+ if [ ! -e "$netcdfflagf" ]; then -+ echo "Error: '$netcdfflagf' not found." -+ exit 1 -+ fi -+ netcdfflagf="$netcdfflagf $netcdfflagc" - fi -- netcdfflagf="$netcdfflagf $netcdfflagc" - fi - # Test netcdf compilation - test_netcdf_compile verbose - if [ $? -gt 0 ]; then -- echo "Error: Could not compile using NetCDF in '$netcdf_dir'" -+ echo "Error: Could not compile using NetCDF in '$netcdf_dir' or '$netcdfc_dir' and '$netcdff_dir'" - exit 1 - fi - echo "OK" -@@ -3732,6 +3797,8 @@ - fi - if [ ! -z "$netcdf_dir" ] ; then - CPPTRAJOPTS="$CPPTRAJOPTS --with-netcdf=$netcdf_dir" -+elif [ ! -z "$netcdfc_dir" ]; then -+ CPPTRAJOPTS="$CPPTRAJOPTS --with-netcdf-c=$netcdfc_dir --with-netcdf-fortran=$netcdff_dir" - else - CPPTRAJOPTS="$CPPTRAJOPTS --with-netcdf=$CPPTRAJHOME" - fi diff --git a/repo/packages/amber/ambertools_makefile.patch b/repo/packages/amber/ambertools_makefile.patch deleted file mode 100644 index 90c19191..00000000 --- a/repo/packages/amber/ambertools_makefile.patch +++ /dev/null @@ -1,50 +0,0 @@ ---- a/ambertools_tmpdir/AmberTools/src/Makefile 2022-07-20 13:06:23.000000000 +0800 -+++ b/ambertools_tmpdir/AmberTools/src/Makefile 2022-07-20 14:35:33.000000000 +0800 -@@ -131,7 +131,7 @@ - (cd blas && $(MAKE) $(BLAS) ) - (cd c9x-complex && $(MAKE) $(C9XCOMPLEX) ) - (cd cifparse && $(MAKE) install ) -- (cd antechamber && $(MAKE) install ) -+# (cd antechamber && $(MAKE) install ) - (cd sqm && $(MAKE) install ) - (cd reduce && $(MAKE) install ) - (cd leap && $(MAKE) install ) -@@ -139,7 +139,7 @@ - (cd addles && $(MAKE) install) - (cd nmode && $(MAKE) install) - $(MAKE) build_cpptraj -- (cd ambpdb && $(MAKE) install) -+# (cd ambpdb && $(MAKE) install) - (cd sff && $(MAKE) install ) - (cd rism && $(MAKE) $(RISM) ) - (cd nab && $(MAKE) install ) -@@ -153,6 +153,7 @@ - (cd FEW && $(MAKE) install) - (cd paramfit && $(MAKE) install) - (cd cphstats && $(MAKE) install) -+ (cd sander && $(MAKE) serial) - (if [ "$(SKIP_PYTHON)" = 'no' ]; then \ - $(MAKE) python_serial ;\ - fi ;\ -@@ -181,6 +182,7 @@ - $(MAKE) python_parallel ;\ - fi ;\ - ) -+ - @echo "" - @echo "Installation of ${AMBERTOOLS} MPI (cray) is complete at `date`." - @echo "" -@@ -487,8 +489,11 @@ - #Rule for building python code - #all_python: parmed pymsmt pytraj pysander - --python_serial:: parmed mmpbsa_py pysander pymsmt $(PYTRAJ) pdb4amber packmol-memgen -- $(PYTHON) fix_conda_fortran.py -+#python_serial:: parmed mmpbsa_py pysander pymsmt $(PYTRAJ) pdb4amber packmol-memgen -+# $(PYTHON) fix_conda_fortran.py -+ -+python_serial:: parmed pysander pymsmt $(PYTRAJ) pdb4amber packmol-memgen -+# $(PYTHON) fix_conda_fortran.py - - python_parallel:: parmed mmpbsa_py_parallel - diff --git a/repo/packages/amber/cpptraj_configure.patch b/repo/packages/amber/cpptraj_configure.patch deleted file mode 100644 index f153c0b2..00000000 --- a/repo/packages/amber/cpptraj_configure.patch +++ /dev/null @@ -1,58 +0,0 @@ ---- AmberTools/src/cpptraj/configure 2020-04-28 09:19:43.000000000 +0800 -+++ AmberTools/src/cpptraj/configure 2022-01-14 16:00:05.000000000 +0800 -@@ -10,7 +10,7 @@ - #------------------------------------------------------------------------------- - # Print simple help message - UsageSimple() { -- echo "Usage: ./configure [gnu | intel | pgi | clang | cray]" -+ echo "Usage: ./configure [gnu | intel | pgi | clang | cray | cray-shasta-gnu | cray-shasta-cray | cray-shasta-aocc]" - echo " OPTIONS:" - echo " --help : Display this message." - echo " --prefix : Install CPPTRAJ to specified directory (default is this directory)." -@@ -1104,13 +1104,35 @@ - if [ $USE_OPENMP -eq 0 ] ; then - commonflags='-h noomp' - fi -+ PLATFORM='cray' -+ ;; -+ "cray-shasta-gnu" ) -+ if [ -z "$CC" ]; then CC=cc; fi -+ if [ -z "$CXX" ]; then CXX=CC; fi -+ if [ -z "$FC" ]; then FC=ftn; fi -+ CXXFLAGS="-O3 $CXXFLAGS" -+ CFLAGS="-O3 $CFLAGS" -+ hostflags='' -+ optflags='' -+ ompflag='-fopenmp' -+ warnflag='-Wall' # This will also print cautions -+ fwarnflag='-Wall' -+ freefmtflag='-fallow-argument-mismatch -ffree-form' -+ foptflags='' -+ FLINK='-lgfortran' -+ picflag='-fpic' -+ C11FLAG='-std=c++11' -+ if [ $USE_OPENMP -eq 0 ] ; then -+ commonflags='' -+ fi -+ PLATFORM='cray' - ;; - * ) Err "Unknown compilers: $1" ;; - esac - # Unless specified fortran warnflag is same as C/C++ - if [ -z "$fwarnflag" ] ; then fwarnflag=$warnflag ; fi - # Change to MPI compiler wrappers if specified. Not needed for cray. -- if [ $USE_MPI -ne 0 -a "$COMPILERS" != 'cray' ] ; then -+ if [ $USE_MPI -ne 0 -a "$COMPILERS" != 'cray' -a "$COMPILERS" != 'cray-shasta-gnu' -a "$COMPILERS" != 'cray-shasta-cray' -a "$COMPILERS" != 'cray-shasta-aocc' ] ; then - if [ $USE_MPI -eq 1 ] ; then - mpi_cc='mpicc' - mpi_cxx='mpicxx' -@@ -1817,6 +1839,9 @@ - 'intel' ) COMPILERS=$KEY ;; - 'pgi' ) COMPILERS=$KEY ;; - 'cray' ) COMPILERS=$KEY ;; -+ 'cray-shasta-gnu' ) COMPILERS=$KEY ;; -+ 'cray-shasta-cray' ) COMPILERS=$KEY ;; -+ 'cray-shasta-aocc' ) COMPILERS=$KEY ;; - 'CXX' ) CXX="$VALUE" ;; - 'CC' ) CC="$VALUE" ;; - 'FC' ) FC="$VALUE" ;; diff --git a/repo/packages/amber/cpptraj_configure_netcdf.patch b/repo/packages/amber/cpptraj_configure_netcdf.patch deleted file mode 100644 index 59d386a9..00000000 --- a/repo/packages/amber/cpptraj_configure_netcdf.patch +++ /dev/null @@ -1,127 +0,0 @@ ---- a/ambertools_tmpdir/AmberTools/src/cpptraj/configure 2020-04-28 09:19:43.000000000 +0800 -+++ b/ambertools_tmpdir/AmberTools/src/cpptraj/configure 2022-02-14 11:29:02.000000000 +0800 -@@ -10,7 +10,7 @@ - #------------------------------------------------------------------------------- - # Print simple help message - UsageSimple() { -- echo "Usage: ./configure [gnu | intel | pgi | clang | cray]" -+ echo "Usage: ./configure [gnu | intel | pgi | clang | cray | cray-shasta-gnu | cray-shasta-cray | cray-shasta-aocc]" - echo " OPTIONS:" - echo " --help : Display this message." - echo " --prefix : Install CPPTRAJ to specified directory (default is this directory)." -@@ -142,12 +142,14 @@ - - # ----- External Libraries ----------------------- - # Total number of external libraries --NLIB=14 -+NLIB=16 - # Library indices --# Original: FFT ARPACK LAPACK BLAS NETCDF PARANC BZIP ZIP READLINE XDRFILE -+# Original: FFT ARPACK LAPACK BLAS NETCDF NETCDFC NETCDFFORTRAN PARANC BZIP ZIP READLINE XDRFILE - # Libraries containing definition of a function should appear *after* - # any source files or object files which use it. - LNETCDF=0 -+LNETCDFC=14 # for separate netcdf fortran and c paths -+LNETCDFFORTRAN=15 # for separate netcdf fortran and c paths - LPARANC=1 # Parallel NetCDF - LBZIP=2 - LTNGFILE=3 # This has to come before ZLIB since it depends on ZLIB -@@ -179,6 +181,26 @@ - LIB_LINK[$LNETCDF]='dynamic' # How to link the library - LIB_TYPE[$LNETCDF]='ld' # ld = LDFLAGS, cpp = cpptraj, blank = special - -+LIB_STAT[$LNETCDFC]='disabled' # off, enabled, specified, amberopt, bundled, direct -+LIB_CKEY[$LNETCDFC]='netcdf-c' # Command-line key for '-', '--with-' and '-no' -+LIB_HOME[$LNETCDFC]='' # Library home directory (-L) -+LIB_FLAG[$LNETCDFC]='-lnetcdf' # Library linker flag -+LIB_STTC[$LNETCDFC]='libnetcdf.a' # Expected static location relative to home -+LIB_D_ON[$LNETCDFC]='-DBINTRAJ' # Directive if library on -+LIB_DOFF[$LNETCDFC]='' # Directive if library off -+LIB_LINK[$LNETCDFC]='dynamic' # How to link the library -+LIB_TYPE[$LNETCDFC]='ld' # ld = LDFLAGS, cpp = cpptraj, blank = special -+ -+LIB_STAT[$LNETCDFFORTRAN]='disabled' # off, enabled, specified, amberopt, bundled, direct -+LIB_CKEY[$LNETCDFFORTRAN]='netcdf-fortran' # Command-line key for '-', '--with-' and '-no' -+LIB_HOME[$LNETCDFFORTRAN]='' # Library home directory (-L) -+LIB_FLAG[$LNETCDFFORTRAN]='-lnetcdff' # Library linker flag -+LIB_STTC[$LNETCDFFORTRAN]='libnetcdff.a' # Expected static location relative to home -+LIB_D_ON[$LNETCDFFORTRAN]='' # Directive if library on -+LIB_DOFF[$LNETCDFFORTRAN]='' # Directive if library off -+LIB_LINK[$LNETCDFFORTRAN]='dynamic' # How to link the library -+LIB_TYPE[$LNETCDFFORTRAN]='ld' # ld = LDFLAGS, cpp = cpptraj, blank = special -+ - LIB_STAT[$LPARANC]='off' - LIB_CKEY[$LPARANC]='pnetcdf' - LIB_HOME[$LPARANC]='' -@@ -433,6 +455,16 @@ - TestProgram " Checking NetCDF" "$CXX" "$CXXFLAGS ${LIB_INCL[$LNETCDF]}" testp.cpp "${LIB_FLAG[$LNETCDF]}" - } - -+TestNetcdfc() { -+ cat > testp.cpp < -+#include "netcdf.h" -+void unused() {int ncid; nc_open("foo.nc", 0, &ncid);} -+int main() { printf("Testing\n"); printf("%s\n",nc_strerror(0)); return 0; } -+EOF -+ TestProgram " Checking NetCDF-C" "$CXX" "$CXXFLAGS ${LIB_INCL[$LNETCDFC]}" testp.cpp "${LIB_FLAG[$LNETCDFC]}" -+} -+ - TestPnetcdf() { - cat > testp.cpp < -@@ -661,6 +693,7 @@ - if [ "${LIB_TEST[$LBZIP]}" = 'yes' ] ; then TestBzlib ; fi - if [ "${LIB_TEST[$LZIP]}" = 'yes' ] ; then TestZlib ; fi - if [ "${LIB_TEST[$LNETCDF]}" = 'yes' ] ; then TestNetcdf ; fi -+ if [ "${LIB_TEST[$LNETCDFC]}" = 'yes' ] ; then TestNetcdfc ; fi - if [ "${LIB_TEST[$LPARANC]}" = 'yes' ] ; then TestPnetcdf ; fi - if [ "${LIB_TEST[$LBLAS]}" = 'yes' ] ; then TestMathlib ; fi - if [ "${LIB_TEST[$LARPACK]}" = 'yes' ] ; then TestArpack ; fi -@@ -1104,13 +1137,35 @@ - if [ $USE_OPENMP -eq 0 ] ; then - commonflags='-h noomp' - fi -+ PLATFORM='cray' -+ ;; -+ "cray-shasta-gnu" ) -+ if [ -z "$CC" ]; then CC=cc; fi -+ if [ -z "$CXX" ]; then CXX=CC; fi -+ if [ -z "$FC" ]; then FC=ftn; fi -+ CXXFLAGS="-O3 $CXXFLAGS" -+ CFLAGS="-O3 $CFLAGS" -+ hostflags='' -+ optflags='' -+ ompflag='-fopenmp' -+ warnflag='-Wall' # This will also print cautions -+ fwarnflag='-Wall' -+ freefmtflag='-fallow-argument-mismatch -ffree-form' -+ foptflags='' -+ FLINK='-lgfortran' -+ picflag='-fpic' -+ C11FLAG='-std=c++11' -+ if [ $USE_OPENMP -eq 0 ] ; then -+ commonflags='' -+ fi -+ PLATFORM='cray' - ;; - * ) Err "Unknown compilers: $1" ;; - esac - # Unless specified fortran warnflag is same as C/C++ - if [ -z "$fwarnflag" ] ; then fwarnflag=$warnflag ; fi - # Change to MPI compiler wrappers if specified. Not needed for cray. -- if [ $USE_MPI -ne 0 -a "$COMPILERS" != 'cray' ] ; then -+ if [ $USE_MPI -ne 0 -a "$COMPILERS" != 'cray' -a "$COMPILERS" != 'cray-shasta-gnu' -a "$COMPILERS" != 'cray-shasta-cray' -a "$COMPILERS" != 'cray-shasta-aocc' ] ; then - if [ $USE_MPI -eq 1 ] ; then - mpi_cc='mpicc' - mpi_cxx='mpicxx' -@@ -1817,6 +1872,9 @@ - 'intel' ) COMPILERS=$KEY ;; - 'pgi' ) COMPILERS=$KEY ;; - 'cray' ) COMPILERS=$KEY ;; -+ 'cray-shasta-gnu' ) COMPILERS=$KEY ;; -+ 'cray-shasta-cray' ) COMPILERS=$KEY ;; -+ 'cray-shasta-aocc' ) COMPILERS=$KEY ;; - 'CXX' ) CXX="$VALUE" ;; - 'CC' ) CC="$VALUE" ;; - 'FC' ) FC="$VALUE" ;; diff --git a/repo/packages/amber/nvhpc-boost.patch b/repo/packages/amber/nvhpc-boost.patch deleted file mode 100644 index abc37577..00000000 --- a/repo/packages/amber/nvhpc-boost.patch +++ /dev/null @@ -1,61 +0,0 @@ ---- a/ambertools_tmpdir/AmberTools/src/ba/ambertools_tmpdir/oost/tools/build/src/engine/build.sh 2020-09-30 14:26:41.136036986 -0700 -+++ b/ambertools_tmpdir/AmberTools/src/boost/tools/build/src/engine/build.sh 2020-09-30 14:27:29.634090876 -0700 -@@ -95,7 +95,7 @@ - elif test -r /opt/intel/compiler50/ia32/bin/iccvars.sh ; then - BOOST_JAM_TOOLSET=intel-linux - BOOST_JAM_TOOLSET_ROOT=/opt/intel/compiler50/ia32/ -- elif test_path pgcc ; then BOOST_JAM_TOOLSET=pgi -+ elif test_path nvc ; then BOOST_JAM_TOOLSET=pgi - elif test_path pathcc ; then BOOST_JAM_TOOLSET=pathscale - elif test_path como ; then BOOST_JAM_TOOLSET=como - elif test_path KCC ; then BOOST_JAM_TOOLSET=kcc -@@ -231,7 +231,7 @@ - ;; - - pgi) -- BOOST_JAM_CC=pgcc -+ BOOST_JAM_CC=nvc - ;; - - sun*) ---- a/ambertools_tmpdir/AmberTools/src/boost/tools/build/src/tools/pgi.jam 2020-09-30 14:28:09.652483687 -0700 -+++ b/ambertools_tmpdir/AmberTools/src/boost/tools/build/src/tools/pgi.jam 2020-09-30 14:28:34.421488935 -0700 -@@ -26,11 +26,11 @@ - { - local condition = [ common.check-init-parameters pgi : version $(version) ] ; - -- local l_command = [ common.get-invocation-command pgi : pgc++ : $(command) ] ; -+ local l_command = [ common.get-invocation-command pgi : nvc++ : $(command) ] ; - - common.handle-options pgi : $(condition) : $(l_command) : $(options) ; - -- command_c = $(command_c[1--2]) $(l_command[-1]:B=pgcc) ; -+ command_c = $(command_c[1--2]) $(l_command[-1]:B=nvc) ; - - toolset.flags pgi CONFIG_C_COMMAND $(condition) : $(command_c) ; - ---- a/ambertools_tmpdir/AmberTools/src/boost/tools/build/src/engine/build.jam 2020-09-30 14:40:16.983284833 -0700 -+++ b/ambertools_tmpdir/AmberTools/src/boost/tools/build/src/engine/build.jam 2020-09-30 14:40:24.172997290 -0700 -@@ -309,7 +309,7 @@ - -I$(--python-include) -I$(--extra-include) - : -L$(--python-lib[1]) -l$(--python-lib[2]) ; - ## Portland Group Pgi 6.2 --toolset pgi pgcc : "-o " : -D -+toolset pgi nvc : "-o " : -D - : - [ opt --release : -s -O3 ] - [ opt --debug : -g ] ---- a/ambertools_tmpdir/AmberTools/src/boost/libs/filesystem/src/operations.cpp 2020-09-30 15:07:31.998097202 -0700 -+++ b/ambertools_tmpdir/AmberTools/src/boost/libs/filesystem/src/operations.cpp 2020-09-30 15:07:37.117892885 -0700 -@@ -2087,10 +2087,6 @@ - return ok; - } - --#if defined(__PGI) && defined(__USE_FILE_OFFSET64) --#define dirent dirent64 --#endif -- - error_code dir_itr_first(void *& handle, void *& buffer, - const char* dir, string& target, - fs::file_status &, fs::file_status &) - diff --git a/repo/packages/amber/nvhpc.patch b/repo/packages/amber/nvhpc.patch deleted file mode 100644 index a612b3c8..00000000 --- a/repo/packages/amber/nvhpc.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- a/ambertools_tmpdir/AmberTools/src/configure2 2020-09-10 07:37:44.380726161 -0700 -+++ b/ambertools_tmpdir/AmberTools/src/configure2 2020-09-10 07:38:22.052936370 -0700 -@@ -3190,7 +3190,7 @@ - cd fftw-3.3 && \ - ./configure --disable-doc --prefix=$amberprefix --libdir=$amberprefix/lib \ - --enable-static $enable_mpi $mpicc $enable_debug $enable_sse\ -- CC="$cc" CFLAGS="$cflags $coptflags" \ -+ CC="$cc" CFLAGS="$cflags $cnooptflags" \ - F77="$fc" FFLAGS="$fflags $foptflags" \ - FLIBS="$flibs_arch" \ - > ../fftw3_config.log 2>&1 -@@ -3287,6 +3287,8 @@ - # b2 install will use intel-linux.compile.c++ (boost_1_64_0). - ./bootstrap.sh --prefix=$amberprefix --with-toolset=intel-linux > ../boost_config.log - ncerror=$? -+ elif [ $x86_64 = 'no' ] && [ "$compiler" = 'pgi' ]; then -+ ./bootstrap.sh --prefix=$amberprefix --with-toolset=pgi > ../boost_config.log - else - ./bootstrap.sh --prefix=$amberprefix > ../boost_config.log - ncerror=$? diff --git a/repo/packages/amber/package.py b/repo/packages/amber/package.py deleted file mode 100644 index 81b6c734..00000000 --- a/repo/packages/amber/package.py +++ /dev/null @@ -1,253 +0,0 @@ -# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# CONTRIBUTE - cray patches -import os -import shutil - -from spack.package import * - - -class Amber(Package, CudaPackage): - """Amber is a suite of biomolecular simulation programs together - with Amber tools. - - A manual download is required for Ambers. Spack will search your current - directory for the download files. Alternatively, add the files to a mirror - so that Spack can find them. For instructions on how to set up a mirror, see - https://spack.readthedocs.io/en/latest/mirrors.html - - Note: Only certain versions of ambertools are compatible with amber. - Only the latter version of ambertools for each amber version is supported. - """ - - homepage = "https://ambermd.org/" - url = "file://{0}/Amber18.tar.bz2".format(os.getcwd()) - manual_download = True - - #maintainers("hseara") - - version("20", sha256="a4c53639441c8cc85adee397933d07856cc4a723c82c6bea585cd76c197ead75") - version("18", sha256="2060897c0b11576082d523fb63a51ba701bc7519ff7be3d299d5ec56e8e6e277") - version( - "16", - sha256="3b7ef281fd3c46282a51b6a6deed9ed174a1f6d468002649d84bfc8a2577ae5d", - deprecated=True, - ) - - resources = { - # [version amber, version ambertools , sha256sum] - # "20": ("21", "f55fa930598d5a8e9749e8a22d1f25cab7fcf911d98570e35365dd7f262aaafd"), - '20': ('20', 'b1e1f8f277c54e88abc9f590e788bbb2f7a49bcff5e8d8a6eacfaf332a4890f9'), - "18": ("19", "0c86937904854b64e4831e047851f504ec45b42e593db4ded92c1bee5973e699"), - "16": ("16", "7b876afe566e9dd7eb6a5aa952a955649044360f15c1f5d4d91ba7f41f3105fa"), - } - for ver, (ambertools_ver, ambertools_checksum) in resources.items(): - resource( - when="@{0}".format(ver), - name="AmberTools", - url="file://{0}/AmberTools{1}.tar.bz2".format(os.getcwd(), ambertools_ver), - sha256=ambertools_checksum, - destination="", - placement="ambertools_tmpdir", - ) - - patches = [ - ("20", "1", "10780cb91a022b49ffdd7b1e2bf4a572fa4edb7745f0fc4e5d93b158d6168e42"), - ("20", "2", "9c973e3f8f33a271d60787e8862901e8f69e94e7d80cda1695f7fad7bc396093"), - ("20", "3", "acb359dc9b1bcff7e0f1965baa9f3f3dc18eeae99c49f1103c1e2986c0bbeed8"), - ("20", "4", "fd93c74f5ec80689023648cdd12b2c5fb21a3898c81ebc3fa256ef244932562a"), - ("20", "5", "8e46d5be28c002f560050a71f4851b01ef45a3eb66ac90d7e23553fae1370e68"), - ("20", "6", "8cf9707b3d08ad9242326f02d1861831ad782c9bfb0c46e7b1f0d4640571d5c1"), - ("20", "7", "143b6a09f774aeae8b002afffb00839212020139a11873a3a1a34d4a63fa995d"), - ("20", "8", "a6fc6d5c8ba0aad3a8afe44d1539cc299ef78ab53721e28244198fd5425d14ad"), - ("20", "9", "5ce6b534bab869b1e9bfefa353d7f578750e54fa72c8c9d74ddf129d993e78cf"), - ("20", "10", "76a683435be7cbb860f5bd26f09a0548c2e77c5a481fc6d64b55a3a443ce481d"), - ("20", "11", "f40b3612bd3e59efa2fa1ec06ed6fd92446ee0f1d5d99d0f7796f66b18e64060"), - ("20", "12", "194119aed03f80677c4bab78a20fc09b0b3dc17c41a57c5eb3c912b2d73b18ab"), - ("18", "1", "3cefac9a24ece99176d5d2d58fea2722de3e235be5138a128428b9260fe922ad"), - ("18", "2", "3a0707a9a59dcbffa765dcf87b68001450095c51b96ec39d21260ba548a2f66a"), - ("18", "3", "24c2e06f71ae553a408caa3f722254db2cbf1ca4db274542302184e3d6ca7015"), - ("18", "4", "51de613e8fda20cc92979265cf7179288df8c1af4202f02794ad7327fda2657b"), - ("18", "5", "c70354bfa312603e4819efce11a242ddcc3830895453d9424f0c83f7ae98bc5b"), - ("18", "6", "3450433a8697b27e43172043be68d31515a7c7c00b2b248f84043dd70a2f59a8"), - ("18", "7", "10ba41422b7a3eb5b32bc6453231100544cf620c764ab8332c629a3b9fc749d4"), - ("18", "8", "73968dc0fd99bcbd5eae2223bd54f414879c062ac933948ba6b8b67383dc6a53"), - ("18", "9", "e7d72fa31560f1e8ea572b8c73259d9fe512f56fbeb1b58ae014c43b9b5b6290"), - ("18", "10", "1bee419a3b0b686a729aa12515b0f96a9a8f43478ca2c01ea1661cc1698c6266"), - ("18", "11", "926557f0c137ea8dbf99a0487b25e131b12dfd39977d3e515f01f49187e6a09c"), - ("18", "12", "7e2645d539d257f7064808308048622818c9083dedfa4ac0a958cd15181231ac"), - ("18", "13", "95d2e33d0d05b8f9b6d8091d1c804271ec3a69e9aef792cc3b1ab8a2165eca3e"), - ("18", "14", "a1adfb072f60ffcb67adb589df7c5578629441bee4ccb89ab635a6e8d7a35277"), - ("18", "15", "4deb3df329c05729561dcc7310e49059eaddc504c4210ad31fad11dc70f61742"), - ("18", "16", "cf02f9b949127363bad1aa700ab662a3c7cf9ce0e2e4750e066d2204b9500a99"), - ("18", "17", "480300f949e0dd6402051810a9714adb388cf96e454a55346c76954cdd69413d"), - ("16", "1.txt", "c7ef2303bb35131a48e2256c5a3c7b391efa73e2acf757d7e39760efb6320ed4"), - ("16", "2", "a4db183f7c337a67f5d6b5015e3ae0af0d0edaa56894f0e9e3469c99708fed1c"), - ("16", "3", "5b279531c42445c6f58281dd94588460218d2258ec9013c8447f3e2b7b81bf02"), - ("16", "4", "035bddd63bc9d5fd6de26beab31887e5c14c3caa4958d2424d72f3c49832bd42"), - ("16", "5", "02d8a1fcb6baa466de4e3683afa48076394acd805f490fbbe50ab19040675136"), - ("16", "6", "69a3e64d75255d9179c98a2b3a63fe76d5be08c9fc41f27ac197663c97915113"), - ("16", "7", "0d674c907758e90a168345e6b35b7a0de79c2ead390ab372465a354fcab67d17"), - ("16", "8", "d722c0db46af905a5bd13b60e3130c4ddfb0c9da86df0a33253e5f8d53068946"), - ("16", "9", "b563e744fbc50c1240d23df369750879df2cec69fba933704b97a73a66d9c4f1"), - ("16", "10", "99affc65740080b7a1ab87c5c9119bf5be7cf47b2b2d8fc13407d35bd2ba6238"), - ("16", "11", "86b89dbcae80ef48720fd3c7da88cffbdabfd4021af5a827339b56a33ddae27a"), - ("16", "12", "c8d61d1efbd44086f88d74ad9e07dfdc3737dc7053c7d2503131ba0918973a03"), - ("16", "13", "5ce28e6e0118a4780ad72fc096e617c874cde7d140e15f87451babb25aaf2d8f"), - ("16", "14", "93703e734e76da30a5e050189a66d5a4d6bec5885752503c4c798e2f44049080"), - ("16", "15", "a156ec246cd06688043cefde24de0d715fd46b08f5c0235015c2c5c3c6e37488"), - ] - for ver, num, checksum in patches: - patch_url_str = "https://ambermd.org/bugfixes/{0}.0/update.{1}" - patch(patch_url_str.format(ver, num), sha256=checksum, level=0, when="@{0}".format(ver)) - - # Patch to move the namelist sebomd after the variable declarations - # Taken from http://archive.ambermd.org/202105/0098.html - patch("sebomd_fix.patch", when="@20") - - # Patch to add ppc64le in config.guess - patch("ppc64le.patch", when="@18: target=ppc64le:") - - # Patch to add aarch64 in config.guess - patch("aarch64.patch", when="@18: target=aarch64:") - - # Workaround to modify the AmberTools script when using the NVIDIA - # compilers - patch("nvhpc.patch", when="@18: %nvhpc") - - # Workaround to use NVIDIA compilers to build the bundled Boost - patch("nvhpc-boost.patch", when="@18: %nvhpc") - - variant("mpi", description="Build MPI executables", default=True) - variant("openmp", description="Use OpenMP pragmas to parallelize", default=False) - variant("x11", description="Build programs that require X11", default=False) - variant("update", description="Update the sources prior compilation", default=False) - - depends_on("zlib") - depends_on("bzip2") - depends_on("flex", type="build") - depends_on("bison", type="build") - depends_on("netcdf-fortran") - depends_on("parallel-netcdf", when="@20:") # when='AmberTools@21:' - depends_on("tcsh", type=("build"), when="@20") # when='AmberTools@21:' - # Potential issues with openmpi 4 - # (http://archive.ambermd.org/201908/0105.html) - depends_on("mpi", when="+mpi") - - # Cuda dependencies - # /AmberTools/src/configure2:1329 - depends_on("cuda@:11.1", when="@20:+cuda") # when='AmberTools@21:' - depends_on("cuda@:10.2.89", when="@18+cuda") - depends_on("cuda@7.5.18", when="@:16+cuda") - - # conflicts - conflicts("+x11", when="platform=cray", msg="x11 amber applications not available for cray") - conflicts("+openmp", when="%clang", msg="OpenMP not available for the clang compiler") - conflicts( - "+openmp", when="%apple-clang", msg="OpenMP not available for the Apple clang compiler" - ) - conflicts("+openmp", when="%pgi", msg="OpenMP not available for the pgi compiler") - - def url_for_version(self, version): - url = "file://{0}/Amber{1}.tar.bz2".format(os.getcwd(), version) - return url - - def setup_build_environment(self, env): - amber_src = self.stage.source_path - env.set("AMBERHOME", amber_src) - - # The bundled Boost does not detect the bzip2 package, but - # will silently fall back to a system install (if available). - # Force it to use the bzip2 package. - env.prepend_path("CPATH", self.spec["bzip2"].prefix.include) - - # CUDA - if self.spec.satisfies("+cuda"): - env.set("CUDA_HOME", self.spec["cuda"].prefix) - - def install(self, spec, prefix): - # The resource command does not allow us to expand the package in the - # root stage folder as required, as it already contains files. Here we - # install AmberTools where it should be, which results in 3 copies of - # the ambertools (~9 GB). This has to be improved in the future. - install_tree("ambertools_tmpdir", ".") - shutil.rmtree(join_path(self.stage.source_path, "ambertools_tmpdir")) - - # Select compiler style - if self.spec.satisfies("%cce"): - compiler = "cray" - elif self.spec.satisfies("%gcc"): - compiler = "gnu" - elif self.spec.satisfies("%intel"): - compiler = "intel" - elif self.spec.satisfies("%pgi"): - compiler = "pgi" - elif self.spec.satisfies("%nvhpc"): - compiler = "pgi" - elif self.spec.satisfies("%clang"): - compiler = "clang" - else: - raise InstallError("Unknown compiler, exiting!!!") - - # Alternative way to make csh/tcsh detection work with modules - filter_file( - r"-x /bin/csh", - "command -v csh &> /dev/null/", - "AmberTools/src/configure2", - string=True, - ) - - # Base configuration - conf = Executable("./configure") - base_args = ["--skip-python", "--with-netcdf", self.spec["netcdf-fortran"].prefix] - if self.spec.satisfies("~x11"): - base_args += ["-noX11"] - - # Update the sources: Apply all upstream patches - if self.spec.satisfies("+update"): - update = Executable("./update_amber") - update(*(["--update"])) - else: - base_args += ["--no-updates"] - - # Non-x86 architecture - if self.spec.target.family != "x86_64": - base_args += ["-nosse"] - - # Single core - conf(*(base_args + [compiler])) - make("install") - - # CUDA - if self.spec.satisfies("+cuda"): - conf(*(base_args + ["-cuda", compiler])) - make("install") - - # MPI - if self.spec.satisfies("+mpi"): - conf(*(base_args + ["-mpi", compiler])) - make("install") - - # Openmp - if self.spec.satisfies("+openmp"): - make("clean") - conf(*(base_args + ["-openmp", compiler])) - make("openmp") - - # CUDA + MPI - if self.spec.satisfies("+cuda") and self.spec.satisfies("+mpi"): - make("clean") - conf(*(base_args + ["-cuda", "-mpi", compiler])) - make("install") - - # just install everything that was built - install_tree(".", prefix) - - def setup_run_environment(self, env): - env.set("AMBER_PREFIX", self.prefix) - env.set("AMBERHOME", self.prefix) - # CUDA - if self.spec.satisfies("+cuda"): - env.prepend_path("LD_LIBRARY_PATH", self.spec["cuda"].prefix.lib) diff --git a/repo/packages/amber/pmemd_nfe.patch b/repo/packages/amber/pmemd_nfe.patch deleted file mode 100644 index 51895a7b..00000000 --- a/repo/packages/amber/pmemd_nfe.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- a/src/pmemd/src/nfe_bbmd.F90 2022-07-21 09:53:40.000000000 +0800 -+++ b/src/pmemd/src/nfe_bbmd.F90 2022-06-29 16:36:23.000000000 +0800 -@@ -2370,7 +2370,7 @@ - #ifndef ASSUME_GFORTRAN - data mult_a /z'6C078965'/ ! gfortran does not like this - #else -- mult_a = ieor(ishft(z'6C07', 16), z'8965') ! but this is okay -+ mult_a = ieor(ishft(int(z'6C07'), 16), z'8965') ! but this is okay - #endif /* ASSUME_GFORTRAN */ - - self%mtinit = .true._wi -@@ -2412,7 +2412,7 @@ - data mult_b /z'5D588B65'/ - data msb1_d /z'80000000'/ - #else -- mult_b = ieor(ishft(z'5D58', 16), z'8B65') -+ mult_b = ieor(ishft(int(z'5D58'), 16), z'8B65') - msb1_d = 1 - msb1_d = ishft(msb1_d, 31) - #endif /* ASSUME_GFORTRAN */ diff --git a/repo/packages/amber/ppc64le.patch b/repo/packages/amber/ppc64le.patch deleted file mode 100644 index 85f3ae0a..00000000 --- a/repo/packages/amber/ppc64le.patch +++ /dev/null @@ -1,24 +0,0 @@ ---- a/ambertools_tmpdir/AmberTools/src/fftw-3.3/config.guess 2020-09-30 13:28:45.035344970 -0700 -+++ b/ambertools_tmpdir/AmberTools/src/fftw-3.3/config.guess 2020-09-30 13:28:55.534923364 -0700 -@@ -953,6 +953,9 @@ - ppc64:Linux:*:*) - echo powerpc64-unknown-linux-gnu - exit ;; -+ ppc64le:Linux:*:*) -+ echo powerpc64le-unknown-linux-gnu -+ exit ;; - ppc:Linux:*:*) - echo powerpc-unknown-linux-gnu - exit ;; ---- a/ambertools_tmpdir/AmberTools/src/xblas/config/config.guess 2020-09-30 15:30:11.573779015 -0700 -+++ b/ambertools_tmpdir/AmberTools/src/xblas/config/config.guess 2020-09-30 15:30:46.932366326 -0700 -@@ -967,6 +967,9 @@ - ppc64:Linux:*:*) - echo powerpc64-unknown-linux-gnu - exit ;; -+ ppc64le:Linux:*:*) -+ echo powerpc64le-unknown-linux-gnu -+ exit ;; - ppc:Linux:*:*) - echo powerpc-unknown-linux-gnu - exit ;; diff --git a/repo/packages/amber/sander_mt19937.patch b/repo/packages/amber/sander_mt19937.patch deleted file mode 100644 index 1ba2554b..00000000 --- a/repo/packages/amber/sander_mt19937.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- a/ambertools_tmpdir/AmberTools/src/sander/mt19937.F90 2022-07-20 13:27:22.000000000 +0800 -+++ b/ambertools_tmpdir/AmberTools/src/sander/mt19937.F90 2022-07-20 13:27:45.000000000 +0800 -@@ -184,7 +184,7 @@ - #ifndef ASSUME_GFORTRAN - data mult_a /z'6C078965'/ ! gfortran does not like this - #else -- mult_a = ieor(ishft(z'6C07', 16), z'8965') ! but this is okay -+ mult_a = ieor(ishft(int(z'6C07'), 16), z'8965') ! but this is okay - #endif /* ASSUME_GFORTRAN */ - - self%mtinit = .true._wi -@@ -226,7 +226,7 @@ - data mult_b /z'5D588B65'/ - data msb1_d /z'80000000'/ - #else -- mult_b = ieor(ishft(z'5D58', 16), z'8B65') -+ mult_b = ieor(ishft(int(z'5D58'), 16), z'8B65') - msb1_d = 1 - msb1_d = ishft(msb1_d, 31) - #endif /* ASSUME_GFORTRAN */ diff --git a/repo/packages/amber/sander_sebomd.patch b/repo/packages/amber/sander_sebomd.patch deleted file mode 100644 index 90000c6f..00000000 --- a/repo/packages/amber/sander_sebomd.patch +++ /dev/null @@ -1,76 +0,0 @@ ---- a/ambertools_tmpdir/AmberTools/src/sander/sebomd_module.F90 2022-07-20 13:29:09.000000000 +0800 -+++ b/ambertools_tmpdir/AmberTools/src/sander/sebomd_module.F90 2022-07-20 13:43:02.000000000 +0800 -@@ -120,6 +120,36 @@ - subroutine read_sebomd_namelist() - implicit none - integer :: stat -+ character(10) :: hamiltonian -+ character(10) :: modif -+ integer :: method -+ integer :: ncore -+ _REAL_ :: dbuff1 -+ _REAL_ :: dbuff2 -+ character(256) :: charge_out -+ character(256) :: bond_order_out -+ _REAL_ :: lambda -+ _REAL_ :: peptk -+ _REAL_ :: dpmax -+ _REAL_ :: bocut -+ integer :: charge -+ integer :: longrange -+ integer :: fullscf -+ integer :: ntwc -+ integer :: ntwb -+ integer :: chtype -+ integer :: chewald -+ integer :: screen -+ integer :: guess -+ integer :: pdump -+ integer :: ipolyn -+ integer :: nresidue -+ integer :: ntwh -+ integer :: peptcorr -+ integer :: iprec -+ integer :: debugmsg -+ integer :: debugforces -+ integer :: diag_routine - - namelist /sebomd/ hamiltonian, & - modif, & -@@ -152,36 +182,6 @@ - dpmax, & - bocut - -- character(10) :: hamiltonian -- character(10) :: modif -- integer :: method -- integer :: ncore -- _REAL_ :: dbuff1 -- _REAL_ :: dbuff2 -- character(256) :: charge_out -- character(256) :: bond_order_out -- _REAL_ :: lambda -- _REAL_ :: peptk -- _REAL_ :: dpmax -- _REAL_ :: bocut -- integer :: charge -- integer :: longrange -- integer :: fullscf -- integer :: ntwc -- integer :: ntwb -- integer :: chtype -- integer :: chewald -- integer :: screen -- integer :: guess -- integer :: pdump -- integer :: ipolyn -- integer :: nresidue -- integer :: ntwh -- integer :: peptcorr -- integer :: iprec -- integer :: debugmsg -- integer :: debugforces -- integer :: diag_routine - - hamiltonian = sebomd_obj%hamiltonian - modif = sebomd_obj%modif diff --git a/repo/packages/amber/sebomd_fix.patch b/repo/packages/amber/sebomd_fix.patch deleted file mode 100644 index c2ee04a0..00000000 --- a/repo/packages/amber/sebomd_fix.patch +++ /dev/null @@ -1,78 +0,0 @@ ---- a/ambertools_tmpdir/AmberTools/src/sander/sebomd_module.F90 2019-08-01 09:29:43.000000000 -0300 -+++ b/ambertools_tmpdir/AmberTools/src/sander/sebomd_module.F90 2022-03-30 09:07:07.635303955 -0300 -@@ -121,37 +121,6 @@ - implicit none - integer :: stat - -- namelist /sebomd/ hamiltonian, & -- modif, & -- ncore, & -- dbuff1, & -- dbuff2, & -- charge_out, & -- bond_order_out, & -- lambda, & -- peptk, & -- method, & -- charge, & -- longrange, & -- fullscf, & -- ntwc, & -- ntwb, & -- chtype, & -- chewald, & -- screen, & -- guess, & -- pdump, & -- ipolyn, & -- nresidue, & -- ntwh, & -- iprec, & -- peptcorr, & -- debugmsg, & -- debugforces, & -- diag_routine, & -- dpmax, & -- bocut -- - character(10) :: hamiltonian - character(10) :: modif - integer :: method -@@ -183,6 +152,37 @@ - integer :: debugforces - integer :: diag_routine - -+ namelist /sebomd/ hamiltonian, & -+ modif, & -+ ncore, & -+ dbuff1, & -+ dbuff2, & -+ charge_out, & -+ bond_order_out, & -+ lambda, & -+ peptk, & -+ method, & -+ charge, & -+ longrange, & -+ fullscf, & -+ ntwc, & -+ ntwb, & -+ chtype, & -+ chewald, & -+ screen, & -+ guess, & -+ pdump, & -+ ipolyn, & -+ nresidue, & -+ ntwh, & -+ iprec, & -+ peptcorr, & -+ debugmsg, & -+ debugforces, & -+ diag_routine, & -+ dpmax, & -+ bocut -+ - hamiltonian = sebomd_obj%hamiltonian - modif = sebomd_obj%modif - method = sebomd_obj%method From edf6be1e98623e3fb1be57f38229e8c6ec39eacf Mon Sep 17 00:00:00 2001 From: Cristian Di Pietrantonio Date: Thu, 31 Oct 2024 10:30:23 +0800 Subject: [PATCH 21/21] Removes singularity and singularityce Customisations have been merged in main spack https://github.com/spack/spack/pull/45846 Also, `singularity` is replaced by `singularityce`. --- repo/packages/singularity/package.py | 101 -------- ...singularity_v3.4.0_remove_root_check.patch | 17 -- .../singularity/spack_perms_fix.sh.j2 | 11 - repo/packages/singularityce/package.py | 220 ------------------ .../singularityce/spack_perms_fix.sh.j2 | 11 - 5 files changed, 360 deletions(-) delete mode 100644 repo/packages/singularity/package.py delete mode 100644 repo/packages/singularity/singularity_v3.4.0_remove_root_check.patch delete mode 100644 repo/packages/singularity/spack_perms_fix.sh.j2 delete mode 100644 repo/packages/singularityce/package.py delete mode 100644 repo/packages/singularityce/spack_perms_fix.sh.j2 diff --git a/repo/packages/singularity/package.py b/repo/packages/singularity/package.py deleted file mode 100644 index 52ea67de..00000000 --- a/repo/packages/singularity/package.py +++ /dev/null @@ -1,101 +0,0 @@ -# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# ======================================================================= -# PAWSEY ADDITIONS -# ======================================================================= -# Differences for the 'singularity' package -# 6c6 -# < from spack.package import * -# --- -# > from spack import * -# 29,32d28 -# < version('3.8.7', sha256='3329f2e583f84a8343cb2c0380a1d6cbceafae7d1e633b5cbcadf7143eac859b') -# < version('3.8.6', sha256='bb5a3b7670ac9c7a4b3ce5b2c9f3d6b5be60e21b08d338c9dfdabb7b2a99f528') -# < version('3.8.5', sha256='7fff78b5c07b5d4d08269bd267ac5e994390f933321e54efd6b7c86683153ce4') -# < version('3.8.4', sha256='cb95e6d68b0d20f2b87d60f23a3bf707b7d3e87cee0dd4aa4380f8f481a57ebc') -# 53,69d48 -# < -# < @run_after('install') -# < def set_pawsey_configuration(self): -# < configuration_file = join_path(self.spec.prefix.etc, 'singularity', 'singularity.conf') -# < # do not allow execution of encrypted containers -# < filter_file(r'^ *allow *container *encrypted *=.*', -# < 'allow container encrypted = no', -# < configuration_file) -# < # do not mount home by default at runtime -# < filter_file(r'^ *mount *home *=.*', -# < 'mount home = no', -# < configuration_file) -# < # # Cray: use RAMFS -# < # # beyond CLE6up05, this is not needed any more -# < # filter_file(r'^ *memory *fs *type *=.*', -# < # 'memory fs type = ramfs', -# < # configuration_file) - -# For the next spack, move to singularityce package -from spack.package import * -from spack.pkg.builtin.singularityce import SingularityBase - - -class Singularity(SingularityBase): - '''Singularity is a container technology focused on building portable - encapsulated environments to support "Mobility of Compute" For older - versions of Singularity (pre 3.0) you should use singularity-legacy, - which has a different install base (Autotools). - - Needs post-install chmod/chown steps to enable full functionality. - See package definition or `spack-build-out.txt` build log for details, - e.g. - - tail -15 $(spack location -i singularity)/.spack/spack-build-out.txt - ''' - homepage = "https://singularity.hpcng.org/" - git = "https://github.com/hpcng/singularity.git" - url = "https://github.com/hpcng/singularity/releases/download/v3.8.3/singularity-3.8.3.tar.gz" - - maintainers = ['alalazo'] - - version('master', branch='master') - version('3.8.7', sha256='3329f2e583f84a8343cb2c0380a1d6cbceafae7d1e633b5cbcadf7143eac859b') - version('3.8.6', sha256='bb5a3b7670ac9c7a4b3ce5b2c9f3d6b5be60e21b08d338c9dfdabb7b2a99f528') - version('3.8.5', sha256='7fff78b5c07b5d4d08269bd267ac5e994390f933321e54efd6b7c86683153ce4') - version('3.8.4', sha256='cb95e6d68b0d20f2b87d60f23a3bf707b7d3e87cee0dd4aa4380f8f481a57ebc') - version('3.8.3', sha256='2e22eb9ee1b73fdd51b8783149f0e4d83c0d2d8a0c1edf6034157d50eeefb835') - version('3.8.0', sha256='e9608b0e0a8c805218bbe795e9176484837b2f7fcb95e5469b853b3809a2412e') - version('3.7.4', sha256='c266369a8bf2747f44e0759858c3fc3b2325b975a8818b2668f0b97b124d0164') - version('3.7.3', sha256='6667eb8875d2b66d73504f40c956b42b1351744f488d164204376215d885da5c') - version('3.7.2', sha256='36916222e26fb934404f0766e0ff368edac36d7fc31ca571f5f609466609066b') - version('3.7.1', sha256='82d2c65063560195ec34551931be3c325b95e8e2009e92755fd7daad346e083c') - version('3.7.0', sha256='fb96aaf5f462a56a4a5bd2951287bcbbefe8cf543e228e4e955428f386a8d478') - version('3.6.4', sha256='71233a81d6bb4d686d8dc636b3e3e962a372f54001921c89a12b062cefd9e79f') - version('3.6.3', sha256='b1a985757a9907d8db0f102fc170a25387e715f7ff31957be964bf47914ea2fd') - version('3.6.2', sha256='dfd7ec7376ca0321c47787388fb3e781034edf99068f66efc36109e516024d9b') - version('3.6.1', sha256='6cac56106ee7f209150aaee9f8788d03b58796af1b767245d343f0b8a691121c') - version('3.5.3', sha256='0c76f1e3808bf4c10e92b17150314b2b816be79f8101be448a6e9d7a96c9e486') - version('3.5.2', sha256='f9c21e289377a4c40ed7a78a0c95e1ff416dec202ed49a6c616dd2c37700eab8') - version('3.4.1', sha256='638fd7cc5ab2a20e779b8768f73baf21909148339d6c4edf6ff61349c53a70c2') - version('3.4.0', sha256='eafb27f1ffbed427922ebe2b5b95d1c9c09bfeb897518867444fe230e3e35e41') - version('3.3.0', sha256='070530a472e7e78492f1f142c8d4b77c64de4626c4973b0589f0d18e1fcf5b4f') - version('3.2.1', sha256='d4388fb5f7e0083f0c344354c9ad3b5b823e2f3f27980e56efa7785140c9b616') - version('3.1.1', sha256='7f0df46458d8894ba0c2071b0848895304ae6b1137d3d4630f1600ed8eddf1a4') - - patch('singularity_v3.4.0_remove_root_check.patch', level=0, when='@3.4.0:3.4.1') - - @run_after('install') - def set_pawsey_configuration(self): - configuration_file = join_path(self.spec.prefix.etc, 'singularity', 'singularity.conf') -# do not allow execution of encrypted containers - filter_file(r'^ *allow *container *encrypted *=.*', - 'allow container encrypted = no', - configuration_file) -# do not mount home by default at runtime - filter_file(r'^ *mount *home *=.*', - 'mount home = no', - configuration_file) -# # Cray: use RAMFS -# # beyond CLE6up05, this is not needed any more -# filter_file(r'^ *memory *fs *type *=.*', -# 'memory fs type = ramfs', -# configuration_file) diff --git a/repo/packages/singularity/singularity_v3.4.0_remove_root_check.patch b/repo/packages/singularity/singularity_v3.4.0_remove_root_check.patch deleted file mode 100644 index ee91b729..00000000 --- a/repo/packages/singularity/singularity_v3.4.0_remove_root_check.patch +++ /dev/null @@ -1,17 +0,0 @@ ---- mlocal/frags/build_runtime_suid.mk 2019-08-30 20:43:13.000000000 -0700 -+++ mlocal/frags/build_runtime_suid.mk 2019-09-10 12:21:09.120567773 -0700 -@@ -11,10 +11,10 @@ - -o $@ $(SOURCEDIR)/cmd/starter/main_linux.go - - $(starter_suid_INSTALL): $(starter_suid) -- @if [ `id -u` -ne 0 -a -z "${RPM_BUILD_ROOT}" ] ; then \ -- echo "SUID binary requires to execute make install as root, use sudo make install to finish installation"; \ -- exit 1 ; \ -- fi -+# @if [ `id -u` -ne 0 -a -z "${RPM_BUILD_ROOT}" ] ; then \ -+# echo "SUID binary requires to execute make install as root, use sudo make install to finish installation"; \ -+# exit 1 ; \ -+# fi - @echo " INSTALL SUID" $@ - $(V)install -d $(@D) - $(V)install -m 4755 $(starter_suid) $(starter_suid_INSTALL) diff --git a/repo/packages/singularity/spack_perms_fix.sh.j2 b/repo/packages/singularity/spack_perms_fix.sh.j2 deleted file mode 100644 index 32baa212..00000000 --- a/repo/packages/singularity/spack_perms_fix.sh.j2 +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/sh -eu - -{% for cf in chown_files %} -chown root {{ prefix }}/{{ cf }} -{% endfor %} - -{% for sf in setuid_files %} -chmod 4555 {{ prefix }}/{{ sf }} -{% endfor %} - -# end diff --git a/repo/packages/singularityce/package.py b/repo/packages/singularityce/package.py deleted file mode 100644 index a85c45ba..00000000 --- a/repo/packages/singularityce/package.py +++ /dev/null @@ -1,220 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -import os -import shutil - -import llnl.util.tty as tty - -from spack.package import * - - -class SingularityBase(MakefilePackage): - variant("suid", default=True, description="install SUID binary") - variant("network", default=True, description="install network plugins") - - depends_on("pkgconfig", type="build") - depends_on("conmon", type=("build", "run")) - depends_on("squashfs", type=("build", "run")) - depends_on("go@1.16:") - depends_on("uuid") - depends_on("libgpg-error") - depends_on("libseccomp") - depends_on("squashfs", type="run") - depends_on("git", when="@develop") # mconfig uses it for version info - depends_on("shadow", type="run", when="@3.3:") - depends_on("cryptsetup", type=("build", "run"), when="@3.4:") - depends_on("libfuse", type=("build", "run"), when="@4.0:") - depends_on("autoconf", type="build", when="@4.0:") - depends_on("automake", type="build", when="@4.0:") - depends_on("libtool", type="build", when="@4.0:") - - conflicts("platform=darwin", msg="singularity requires a Linux VM on Windows & Mac") - - # Use these properties to buffer the renaming to Apptainer - singularity_org = "sylabs" - singularity_name = "singularity" - singularity_security_urls = ( - "https://sylabs.io/guides/2.6/admin-guide/security.html", - "https://sylabs.io/guides/3.2/admin-guide/admin_quickstart.html#singularity-security", - ) - - # Go has novel ideas about how projects should be organized. - # We'll point GOPATH at the stage dir, and move the unpacked src - # tree into the proper subdir in our overridden do_stage below. - @property - def gopath(self): - return self.stage.path - - @property - def singularity_gopath_dir(self): - return join_path( - self.gopath, "src", "github.com", self.singularity_org, self.singularity_name - ) - - # Unpack the tarball as usual, then move the src dir into - # its home within GOPATH. - def do_stage(self, mirror_only=False): - super().do_stage(mirror_only) - if not os.path.exists(self.singularity_gopath_dir): - # Move the expanded source to its destination - tty.debug( - "Moving {0} to {1}".format(self.stage.source_path, self.singularity_gopath_dir) - ) - shutil.move(self.stage.source_path, self.singularity_gopath_dir) - - # The build process still needs access to the source path, - # so create a symlink. - force_symlink(self.singularity_gopath_dir, self.stage.source_path) - - # MakefilePackage's stages use this via working_dir() - @property - def build_directory(self): - return self.singularity_gopath_dir - - # Allow overriding config options - @property - def config_options(self): - # Using conmon from spack - return ["--without-conmon"] - - # Hijack the edit stage to run mconfig. - def edit(self, spec, prefix): - with working_dir(self.build_directory): - _config_options = ["--prefix=%s" % prefix] - _config_options += self.config_options - if "~suid" in spec: - _config_options += ["--without-suid"] - if "~network" in spec: - _config_options += ["--without-network"] - configure = Executable("./mconfig") - configure(*_config_options) - - # Set these for use by MakefilePackage's default build/install methods. - build_targets = ["-C", "builddir", "parallel=False"] - install_targets = ["install", "-C", "builddir", "parallel=False"] - - def setup_build_environment(self, env): - # Point GOPATH at the top of the staging dir for the build step. - env.prepend_path("GOPATH", self.gopath) - - # `singularity` has a fixed path where it will look for - # mksquashfs. If it lives somewhere else you need to specify the - # full path in the config file. This bit uses filter_file to edit - # the config file, uncommenting and setting the mksquashfs path. - @run_after("install") - def fix_mksquashfs_path(self): - prefix = self.spec.prefix - squash_path = join_path(self.spec["squashfs"].prefix.bin, "mksquashfs") - filter_file( - r"^# mksquashfs path =", - "mksquashfs path = {0}".format(squash_path), - join_path(prefix.etc, self.singularity_name, self.singularity_name + ".conf"), - ) - - # - # Assemble a script that fixes the ownership and permissions of several - # key files, install it, and tty.warn() the user. - # HEADSUP: https://github.com/spack/spack/pull/10412. - # - def perm_script(self): - return "spack_perms_fix.sh" - - def perm_script_tmpl(self): - return "{0}.j2".format(self.perm_script()) - - def perm_script_path(self): - return join_path(self.spec.prefix.bin, self.perm_script()) - - def _build_script(self, filename, variable_data): - with open(filename, "w") as f: - env = spack.tengine.make_environment(dirs=self.package_dir) - t = env.get_template(self.perm_script_tmpl()) - f.write(t.render(variable_data)) - - @run_after("install") - def build_perms_script(self): - if self.spec.satisfies("+suid"): - script = self.perm_script_path() - chown_files = [ - fn.format(self.singularity_name) - for fn in [ - "libexec/{0}/bin/starter-suid", - "etc/{0}/{0}.conf", - "etc/{0}/capability.json", - "etc/{0}/ecl.toml", - ] - ] - setuid_files = ["libexec/{0}/bin/starter-suid".format(self.singularity_name)] - self._build_script( - script, - { - "prefix": self.spec.prefix, - "chown_files": chown_files, - "setuid_files": setuid_files, - }, - ) - chmod = which("chmod") - chmod("555", script) - - # Until tty output works better from build steps, this ends up in - # the build log. See https://github.com/spack/spack/pull/10412. - @run_after("install") - def caveats(self): - if self.spec.satisfies("+suid"): - tty.warn( - """ - For full functionality, you'll need to chown and chmod some files - after installing the package. This has security implications. - For details, see: - {1} - {2} - - We've installed a script that will make the necessary changes; - read through it and then execute it as root (e.g. via sudo). - - The script is named: - - {0} - """.format( - self.perm_script_path(), *self.singularity_security_urls - ) - ) - - -class Singularityce(SingularityBase): - """Singularity is a container technology focused on building portable - encapsulated environments to support "Mobility of Compute" For older - versions of Singularity (pre 3.0) you should use singularity-legacy, - which has a different install base (Autotools). - - Needs post-install chmod/chown steps to enable full functionality. - See package definition or `spack-build-out.txt` build log for details, - e.g. - - tail -15 $(spack location -i singularityce)/.spack/spack-build-out.txt - """ - - homepage = "https://sylabs.io/singularity/" - url = "https://github.com/sylabs/singularity/releases/download/v3.9.1/singularity-ce-3.9.1.tar.gz" - git = "https://github.com/sylabs/singularity.git" - - license("Apache-2.0") - - maintainers("alalazo") - version("master", branch="master") - - version("4.1.0", sha256="119667f18e76a750b7d4f8612d7878c18a824ee171852795019aa68875244813") - version("4.0.3", sha256="b3789c9113edcac62032ce67cd1815cab74da6c33c96da20e523ffb54cdcedf3") - version("3.11.5", sha256="5acfbb4a109d9c63a25c230e263f07c1e83f6c726007fbcd97a533f03d33a86a") - version("3.11.4", sha256="751dbea64ec16fd7e7af1e36953134c778c404909f9d27ba89006644160b2fde") - version("3.11.3", sha256="a77ede063fd115f85f98f82d2e30459b5565db7d098665497bcd684bf8edaec9") - version("3.10.3", sha256="f87d8e212ce209c5212d6faf253b97a24b5d0b6e6b17b5e58b316cdda27a332f") - version("3.10.2", sha256="b4f279856ea4bf28a1f34f89320c02b545d6e57d4143679920e1ac4267f540e1") - version("3.10.1", sha256="e3af12edc0260bc3a3a481459a3a4457de9235025e6b37288da80e3cdc011a7a") - version("3.10.0", sha256="5e22e6cdad66c331668f6cff4544c83917bb3db90da3cf92403a394c5bf8cc8f") - version("3.9.9", sha256="1381433d64138c08e93ffacdfb4844e82c2288f1e39a9d2c631a1c4021381f2a") - version("3.9.1", sha256="1ba3bb1719a420f48e9b0a6afdb5011f6c786d0f107ef272528c632fff9fd153") - version("3.8.0", sha256="5fa2c0e7ef2b814d8aa170826b833f91e5031a85d85cd1292a234e6c55da1be1") diff --git a/repo/packages/singularityce/spack_perms_fix.sh.j2 b/repo/packages/singularityce/spack_perms_fix.sh.j2 deleted file mode 100644 index 32baa212..00000000 --- a/repo/packages/singularityce/spack_perms_fix.sh.j2 +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/sh -eu - -{% for cf in chown_files %} -chown root {{ prefix }}/{{ cf }} -{% endfor %} - -{% for sf in setuid_files %} -chmod 4555 {{ prefix }}/{{ sf }} -{% endfor %} - -# end