2020-11-19 15:49:24 +01:00
|
|
|
#
|
|
|
|
# spec file for package spack
|
|
|
|
#
|
2024-01-31 10:55:54 +01:00
|
|
|
# Copyright (c) 2024 SUSE LLC
|
2020-11-19 15:49:24 +01:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2021-02-04 19:31:35 +01:00
|
|
|
|
2020-12-08 16:10:47 +01:00
|
|
|
%global flavor @BUILD_FLAVOR@%{?nil}
|
|
|
|
%if "%{flavor}" == "doc"
|
|
|
|
%bcond_without doc
|
|
|
|
%endif
|
|
|
|
|
2024-02-12 11:43:18 +01:00
|
|
|
ExcludeArch: i586 %arm s390 s390x %power64 ppc
|
|
|
|
|
2020-12-08 16:10:47 +01:00
|
|
|
%if %{with doc} && (0%{?sle_version} > 0) && (150200 >= 0%{?sle_version})
|
|
|
|
ExclusiveArch: do_not_build
|
|
|
|
%endif
|
|
|
|
|
2020-11-19 15:49:24 +01:00
|
|
|
%define spack_dir %_prefix/lib/spack/
|
|
|
|
%define spack_group spack
|
2024-03-16 18:10:02 +01:00
|
|
|
# These packages are missing from a BCI-style base container but may
|
|
|
|
# be used by Spack for building. To avoid unresolved libraries, make
|
|
|
|
# sure these are installed in the runtime container.
|
|
|
|
%if 0%{suse_version} == 1500
|
|
|
|
%define spack_container_packages libgfortran4 libfl2 libzip5
|
|
|
|
%else
|
|
|
|
%if 0%{suse_version} > 1600
|
|
|
|
%define spack_container_packages libgfortran5 libfl2 libzip5
|
|
|
|
%endif
|
|
|
|
%endif
|
2023-03-09 08:41:20 +01:00
|
|
|
|
2023-03-30 16:41:13 +02:00
|
|
|
# These packages are found and can be used by spack, %{_sysconfdir}/spack/packages-yaml
|
2021-03-16 16:29:38 +01:00
|
|
|
# needs to be updated when one of these packages is updated or uninstalled.
|
|
|
|
# Distinguish between packages we recommend and packages which
|
2024-04-04 15:53:04 +02:00
|
|
|
%define spack_trigger_recommended_packages autoconf bash bison bzip2 libzip-devel cmake-full ccache cpio diffutils findutils flex git-lfs info make makeinfo m4 ncurses-devel libtool libcurl-devel libopenssl-devel perl-base pkgconf pkg-config python3-base tar xz xz-devel
|
2023-03-09 08:41:20 +01:00
|
|
|
|
|
|
|
%define spack_trigger_recommended_compilers gcc gcc-c++ gcc-fortran
|
|
|
|
|
2020-12-08 16:10:47 +01:00
|
|
|
# packages recognized by spack, but not recommended
|
2023-06-26 21:56:48 +02:00
|
|
|
%define spack_trigger_packages ghostscript go fish fzf hwloc-devel hugo java-11-openjdk-devel java-14-openjdk-devel java-15-openjdk-devel java-16-openjdk-devel java-1_8_0-openjdk-devel ruby sqlite3 openmpi1-devel openmpi2-devel openmpi3-devel openmpi4-devel openmpi1-gnu-hpc-devel openmpi2-gnu-hpc-devel openmpi3-gnu-hpc-devel openmpi4-gnu-hpc-devel mpich-gnu-hpc-devel mvapich2-devel mpich-devel
|
2023-03-09 08:41:20 +01:00
|
|
|
|
2024-01-31 10:55:54 +01:00
|
|
|
%define spack_trigger_compilers gcc7 gcc8 gcc9 gcc10 gcc11 gcc12 gcc13 gcc7-c++ gcc8-c++ gcc9-c++ gcc10-c++ gcc11-c++ gcc12-c++ gcc13-c++ gcc7-fortran gcc8-fortran gcc9-fortran gcc10-fortran gcc11-fortran gcc12-fortran gcc13-fortran
|
2023-03-09 08:41:20 +01:00
|
|
|
|
2021-03-16 16:29:38 +01:00
|
|
|
# non oss packages
|
2020-12-08 16:10:47 +01:00
|
|
|
%define spack_trigger_external cuda-nvcc
|
2024-02-12 11:43:18 +01:00
|
|
|
|
|
|
|
%if 0%{?sle_version} <= 120500 && !0%{?is_opensuse}
|
|
|
|
%define __python3 python3
|
|
|
|
%endif
|
|
|
|
|
|
|
|
%define mypyver 3
|
|
|
|
%define mypython python%{?mypyver}
|
|
|
|
|
2020-11-19 15:49:24 +01:00
|
|
|
Name: spack
|
2024-03-15 16:59:53 +01:00
|
|
|
Version: 0.21.2
|
2020-11-19 15:49:24 +01:00
|
|
|
Release: 0
|
|
|
|
Summary: Package manager for HPC systems
|
2021-02-04 19:31:35 +01:00
|
|
|
License: Apache-2.0 AND MIT AND Python-2.0 AND BSD-3-Clause
|
2020-11-19 15:49:24 +01:00
|
|
|
URL: https://spack.io
|
2020-12-08 16:10:47 +01:00
|
|
|
Source0: https://github.com/spack/spack/archive/v%{version}.tar.gz#/spack-%{version}.tar.gz
|
2020-11-19 16:23:20 +01:00
|
|
|
Source1: README.SUSE
|
2020-12-08 16:10:47 +01:00
|
|
|
Source2: spack-rpmlintrc
|
2022-01-12 17:44:43 +01:00
|
|
|
Source3: run-find-external.sh.in
|
2021-07-26 15:26:41 +02:00
|
|
|
Source4: https://en.opensuse.org/index.php?title=Spack&action=raw&ref=157522#/README-oo-wiki
|
2021-12-13 11:05:52 +01:00
|
|
|
# Source5 is from https://docs.python.org/3/objects.inv, but has permanent changes so using a static version
|
|
|
|
Source5: objects.inv
|
2023-05-04 12:15:58 +02:00
|
|
|
Source6: spack_get_libs.sh
|
2020-12-08 16:10:47 +01:00
|
|
|
Patch2: Adapt-shell-scripts-that-set-up-the-environment-for-different-shells.patch
|
2020-12-11 16:11:15 +01:00
|
|
|
Patch4: added-target-and-os-calls-to-output-of-spack-spec-co.patch
|
Accepting request 931785 from home:mslacken:sp
- updated to version 0.17.0
(Upstream feature/bug references (<ID>) are relative to
https://github.com/spack/spack/issues/<ID>).
* New concretizer is now default
The new concretizer introduced as an experimental feature in v0.16.0
is now the default (#25502). The new concretizer is based on the
clingo logic programming system,
and it enables us to do much higher quality and faster dependency solving
The old concretizer is still available via the concretizer: original
setting, but it is deprecated and will be removed in v0.18.0.
* Binary Bootstrapping
To make it easier to use the new concretizer and binary packages,
Spack now bootstraps clingo and GnuPG from public binaries. If it
is not able to bootstrap them from binaries, it installs them from
source code. With these changes, you should still be able to clone Spack
and start using it almost immediately.
* Reuse existing packages (experimental)
The most wanted feature from our
2020 user survey and
the most wanted Spack feature of all time (#25310). spack install,
spack spec, and spack concretize now have a --reuse option, which
causes Spack to minimize the number of rebuilds it does. The --reuse
option will try to find existing installations and binary packages locally
and in registered mirrors, and will prefer to use them over building new
versions. This will allow users to build from source far less than in
prior versions of Spack. This feature will continue to be improved, with
configuration options and better CLI expected in v0.17.1. It will become
the default concretization mode in v0.18.0.
* Better error messages
We have improved the error messages generated by the new concretizer by
OBS-URL: https://build.opensuse.org/request/show/931785
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=35
2021-11-16 15:32:55 +01:00
|
|
|
Patch5: Make-spack-paths-compliant-to-distro-installation.patch
|
2021-07-07 18:05:08 +02:00
|
|
|
Patch6: Fix-error-during-documentation-build-due-to-recursive-module-inclusion.patch
|
Accepting request 931785 from home:mslacken:sp
- updated to version 0.17.0
(Upstream feature/bug references (<ID>) are relative to
https://github.com/spack/spack/issues/<ID>).
* New concretizer is now default
The new concretizer introduced as an experimental feature in v0.16.0
is now the default (#25502). The new concretizer is based on the
clingo logic programming system,
and it enables us to do much higher quality and faster dependency solving
The old concretizer is still available via the concretizer: original
setting, but it is deprecated and will be removed in v0.18.0.
* Binary Bootstrapping
To make it easier to use the new concretizer and binary packages,
Spack now bootstraps clingo and GnuPG from public binaries. If it
is not able to bootstrap them from binaries, it installs them from
source code. With these changes, you should still be able to clone Spack
and start using it almost immediately.
* Reuse existing packages (experimental)
The most wanted feature from our
2020 user survey and
the most wanted Spack feature of all time (#25310). spack install,
spack spec, and spack concretize now have a --reuse option, which
causes Spack to minimize the number of rebuilds it does. The --reuse
option will try to find existing installations and binary packages locally
and in registered mirrors, and will prefer to use them over building new
versions. This will allow users to build from source far less than in
prior versions of Spack. This feature will continue to be improved, with
configuration options and better CLI expected in v0.17.1. It will become
the default concretization mode in v0.18.0.
* Better error messages
We have improved the error messages generated by the new concretizer by
OBS-URL: https://build.opensuse.org/request/show/931785
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=35
2021-11-16 15:32:55 +01:00
|
|
|
Patch7: Fix-Spinx-configuration-to-avoid-throwing-errors.patch
|
|
|
|
Patch8: Set-modules-default-to-lmod.patch
|
2022-01-12 17:44:43 +01:00
|
|
|
Patch9: Add-support-for-container-building-using-a-SLE-base-container.patch
|
2020-12-08 16:10:47 +01:00
|
|
|
%if %{without doc}
|
2024-02-12 11:43:18 +01:00
|
|
|
BuildRequires: %{mypython}-urllib3
|
2020-11-19 15:49:24 +01:00
|
|
|
BuildRequires: fdupes
|
2021-02-04 19:31:35 +01:00
|
|
|
BuildRequires: lua-lmod
|
|
|
|
BuildRequires: polkit
|
2021-03-30 16:36:39 +02:00
|
|
|
BuildRequires: sudo
|
2021-10-04 15:55:13 +02:00
|
|
|
BuildRequires: sysuser-tools
|
2024-02-12 11:43:18 +01:00
|
|
|
Requires: %{mypython}-clingo
|
2020-11-19 15:49:24 +01:00
|
|
|
Requires: %{name}-recipes = %{version}
|
2023-05-04 12:15:58 +02:00
|
|
|
Requires: awk
|
2021-02-04 19:31:35 +01:00
|
|
|
Requires: bzip2
|
Accepting request 931785 from home:mslacken:sp
- updated to version 0.17.0
(Upstream feature/bug references (<ID>) are relative to
https://github.com/spack/spack/issues/<ID>).
* New concretizer is now default
The new concretizer introduced as an experimental feature in v0.16.0
is now the default (#25502). The new concretizer is based on the
clingo logic programming system,
and it enables us to do much higher quality and faster dependency solving
The old concretizer is still available via the concretizer: original
setting, but it is deprecated and will be removed in v0.18.0.
* Binary Bootstrapping
To make it easier to use the new concretizer and binary packages,
Spack now bootstraps clingo and GnuPG from public binaries. If it
is not able to bootstrap them from binaries, it installs them from
source code. With these changes, you should still be able to clone Spack
and start using it almost immediately.
* Reuse existing packages (experimental)
The most wanted feature from our
2020 user survey and
the most wanted Spack feature of all time (#25310). spack install,
spack spec, and spack concretize now have a --reuse option, which
causes Spack to minimize the number of rebuilds it does. The --reuse
option will try to find existing installations and binary packages locally
and in registered mirrors, and will prefer to use them over building new
versions. This will allow users to build from source far less than in
prior versions of Spack. This feature will continue to be improved, with
configuration options and better CLI expected in v0.17.1. It will become
the default concretization mode in v0.18.0.
* Better error messages
We have improved the error messages generated by the new concretizer by
OBS-URL: https://build.opensuse.org/request/show/931785
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=35
2021-11-16 15:32:55 +01:00
|
|
|
Requires: coreutils
|
2020-11-19 15:49:24 +01:00
|
|
|
Requires: curl
|
2021-05-03 09:33:04 +02:00
|
|
|
Requires: gcc-c++
|
2020-11-19 15:49:24 +01:00
|
|
|
Requires: gcc-fortran
|
2023-05-04 12:15:58 +02:00
|
|
|
Requires: git
|
2020-11-19 15:49:24 +01:00
|
|
|
Requires: gpg2
|
2023-05-04 12:15:58 +02:00
|
|
|
Requires: gzip
|
2021-03-30 16:36:39 +02:00
|
|
|
Requires: libbz2-devel
|
2021-08-10 15:21:51 +02:00
|
|
|
Requires: make
|
2021-04-01 14:11:29 +02:00
|
|
|
Requires: patch
|
2021-02-04 19:31:35 +01:00
|
|
|
Requires: polkit
|
2021-03-30 16:36:39 +02:00
|
|
|
Requires: sudo
|
2021-08-10 15:21:51 +02:00
|
|
|
Requires: tar
|
2023-05-04 12:15:58 +02:00
|
|
|
Requires: unzip
|
2021-02-04 19:31:35 +01:00
|
|
|
Requires: xz
|
2024-04-04 15:53:04 +02:00
|
|
|
Requires: (patchelf if (product(SUSE_SLE) >= 15.6 or product(Leap) or product(openSUSE)))
|
2023-03-09 08:41:20 +01:00
|
|
|
Recommends: %spack_trigger_recommended_packages %spack_trigger_recommended_compilers
|
Accepting request 1143459 from home:mslacken:sp
fix infinite recursion when computing concretization
errors
+ environment: fix an issue with
deconcretization/reconcretization of specs
+ buildcache: don't error if a patch is missing, when
installing from binaries
In v0.18, we added better error messages that could tell you
what problem happened, but they couldn't tell you why it
happened. 0.21 adds condition chaining to the solver, and
Spack can now trace back through the conditions that led to
an error and build a tree of causes potential causes and
where they came from.
This creates a container image from the Spack installations
on the host system, without the need to run spack install
from a Dockerfile or sif file. It also addresses the
inconvenience of losing binaries of dependencies when RUN
spack install fails inside docker build. Further, the
container image layers and build cache tarballs are the same
files. This means that spack install and docker pull use the
exact same underlying binaries. If you previously used spack
install inside of docker build, this feature helps you save
storage by a factor two.
Increasingly, complex package builds require multiple
versions of some build dependencies. For example, Python
packages frequently require very specific versions of
setuptools, cython, and sometimes different physics packages
require different versions of Python to build. The
concretizer enforced that every solve was unified, i.e.,
that there only be one version of every package. The
concretizer now supports "duplicate" nodes for build
OBS-URL: https://build.opensuse.org/request/show/1143459
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=91
2024-02-02 08:10:30 +01:00
|
|
|
Recommends: lua-lmod
|
2024-04-04 15:53:04 +02:00
|
|
|
Recommends: patchelf
|
2023-06-27 10:11:09 +02:00
|
|
|
Requires: (hwloc if hwloc-devel)
|
|
|
|
Requires: (hwloc-devel if hwloc)
|
2020-12-08 16:10:47 +01:00
|
|
|
%else
|
|
|
|
BuildRequires: git
|
2021-02-04 19:31:35 +01:00
|
|
|
BuildRequires: makeinfo
|
Accepting request 931785 from home:mslacken:sp
- updated to version 0.17.0
(Upstream feature/bug references (<ID>) are relative to
https://github.com/spack/spack/issues/<ID>).
* New concretizer is now default
The new concretizer introduced as an experimental feature in v0.16.0
is now the default (#25502). The new concretizer is based on the
clingo logic programming system,
and it enables us to do much higher quality and faster dependency solving
The old concretizer is still available via the concretizer: original
setting, but it is deprecated and will be removed in v0.18.0.
* Binary Bootstrapping
To make it easier to use the new concretizer and binary packages,
Spack now bootstraps clingo and GnuPG from public binaries. If it
is not able to bootstrap them from binaries, it installs them from
source code. With these changes, you should still be able to clone Spack
and start using it almost immediately.
* Reuse existing packages (experimental)
The most wanted feature from our
2020 user survey and
the most wanted Spack feature of all time (#25310). spack install,
spack spec, and spack concretize now have a --reuse option, which
causes Spack to minimize the number of rebuilds it does. The --reuse
option will try to find existing installations and binary packages locally
and in registered mirrors, and will prefer to use them over building new
versions. This will allow users to build from source far less than in
prior versions of Spack. This feature will continue to be improved, with
configuration options and better CLI expected in v0.17.1. It will become
the default concretization mode in v0.18.0.
* Better error messages
We have improved the error messages generated by the new concretizer by
OBS-URL: https://build.opensuse.org/request/show/931785
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=35
2021-11-16 15:32:55 +01:00
|
|
|
# Hardcode this - there is no python2 version of this around any more.
|
2024-02-12 11:43:18 +01:00
|
|
|
BuildRequires: %{mypython}-Sphinx >= 3.4
|
|
|
|
BuildRequires: %{mypython}-sphinxcontrib-programoutput
|
2021-02-04 19:31:35 +01:00
|
|
|
BuildRequires: spack
|
2020-12-08 16:10:47 +01:00
|
|
|
# html
|
|
|
|
BuildRequires: graphviz
|
|
|
|
# info
|
|
|
|
BuildRequires: graphviz-gnome
|
|
|
|
## pdf
|
2024-02-12 11:43:18 +01:00
|
|
|
# BuildRequires: %{mypython}-Sphinx-latex
|
|
|
|
Recommends: spack
|
2020-12-08 16:10:47 +01:00
|
|
|
%endif
|
2020-11-19 15:49:24 +01:00
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
%description
|
|
|
|
Spack is a configurable Python-based HPC package manager, automating
|
|
|
|
the installation and fine-tuning of simulations and libraries.
|
|
|
|
It operates on a wide variety of HPC platforms and enables users
|
|
|
|
to build many code configurations. Software installed by Spack
|
|
|
|
runs correctly regardless of environment, and file management
|
|
|
|
is streamlined. Spack can install many variants of the same build
|
|
|
|
using different compilers, options, and MPI implementations.
|
|
|
|
|
|
|
|
This package provides a module file that must be loaded to use spack.
|
|
|
|
|
|
|
|
%package recipes
|
|
|
|
Summary: Spack built-in package recipes
|
2022-03-02 17:29:47 +01:00
|
|
|
Requires: %{name} = %version
|
2020-11-19 15:49:24 +01:00
|
|
|
|
|
|
|
%description recipes
|
|
|
|
Spack is a configurable Python-based HPC package manager, automating
|
|
|
|
the installation and fine-tuning of simulations and libraries.
|
|
|
|
It operates on a wide variety of HPC platforms and enables users
|
|
|
|
to build many code configurations. Software installed by Spack
|
|
|
|
runs correctly regardless of environment, and file management
|
|
|
|
is streamlined. Spack can install many variants of the same build
|
|
|
|
using different compilers, options, and MPI implementations.
|
|
|
|
|
2021-03-16 16:29:38 +01:00
|
|
|
This package contains the built-in package recipes.
|
2020-11-19 15:49:24 +01:00
|
|
|
|
2020-12-08 16:10:47 +01:00
|
|
|
%package man
|
|
|
|
Summary: Man Page for Spack - Package manager for HPC systems
|
|
|
|
Requires: man
|
|
|
|
|
|
|
|
%description man
|
|
|
|
Spack is a configurable Python-based HPC package manager, automating
|
|
|
|
the installation and fine-tuning of simulations and libraries.
|
|
|
|
It operates on a wide variety of HPC platforms and enables users
|
|
|
|
to build many code configurations. Software installed by Spack
|
|
|
|
runs correctly regardless of environment, and file management
|
|
|
|
is streamlined. Spack can install many variants of the same build
|
|
|
|
using different compilers, options, and MPI implementations.
|
|
|
|
|
|
|
|
This package contains the man page.
|
|
|
|
|
|
|
|
%package info
|
|
|
|
Summary: Info Page for Spack - Package manager for HPC systems
|
|
|
|
Requires: info
|
2023-03-30 16:41:13 +02:00
|
|
|
%if 0%{?suse_version} <= 1500
|
|
|
|
Requires(post): %{install_info_prereq}
|
|
|
|
Requires(pre): %{install_info_prereq}
|
|
|
|
%endif
|
2020-12-08 16:10:47 +01:00
|
|
|
|
|
|
|
%description info
|
|
|
|
Spack is a configurable Python-based HPC package manager, automating
|
|
|
|
the installation and fine-tuning of simulations and libraries.
|
|
|
|
It operates on a wide variety of HPC platforms and enables users
|
|
|
|
to build many code configurations. Software installed by Spack
|
|
|
|
runs correctly regardless of environment, and file management
|
|
|
|
is streamlined. Spack can install many variants of the same build
|
|
|
|
using different compilers, options, and MPI implementations.
|
|
|
|
|
|
|
|
This package contains the info page.
|
|
|
|
|
2020-11-19 15:49:24 +01:00
|
|
|
%prep
|
|
|
|
%setup -q
|
|
|
|
%autopatch -p1
|
2020-12-11 16:11:15 +01:00
|
|
|
%if %{without doc}
|
2020-11-19 15:49:24 +01:00
|
|
|
|
2020-12-08 16:10:47 +01:00
|
|
|
# set SPACK_ROOT
|
|
|
|
for i in share/spack/setup-env.*; do
|
|
|
|
sed -i -e "s;@@_prefix@@;%_prefix;g" $i
|
|
|
|
done
|
Accepting request 931785 from home:mslacken:sp
- updated to version 0.17.0
(Upstream feature/bug references (<ID>) are relative to
https://github.com/spack/spack/issues/<ID>).
* New concretizer is now default
The new concretizer introduced as an experimental feature in v0.16.0
is now the default (#25502). The new concretizer is based on the
clingo logic programming system,
and it enables us to do much higher quality and faster dependency solving
The old concretizer is still available via the concretizer: original
setting, but it is deprecated and will be removed in v0.18.0.
* Binary Bootstrapping
To make it easier to use the new concretizer and binary packages,
Spack now bootstraps clingo and GnuPG from public binaries. If it
is not able to bootstrap them from binaries, it installs them from
source code. With these changes, you should still be able to clone Spack
and start using it almost immediately.
* Reuse existing packages (experimental)
The most wanted feature from our
2020 user survey and
the most wanted Spack feature of all time (#25310). spack install,
spack spec, and spack concretize now have a --reuse option, which
causes Spack to minimize the number of rebuilds it does. The --reuse
option will try to find existing installations and binary packages locally
and in registered mirrors, and will prefer to use them over building new
versions. This will allow users to build from source far less than in
prior versions of Spack. This feature will continue to be improved, with
configuration options and better CLI expected in v0.17.1. It will become
the default concretization mode in v0.18.0.
* Better error messages
We have improved the error messages generated by the new concretizer by
OBS-URL: https://build.opensuse.org/request/show/931785
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=35
2021-11-16 15:32:55 +01:00
|
|
|
%else
|
|
|
|
cp %{S:5} lib/spack/docs/
|
2020-12-08 16:10:47 +01:00
|
|
|
%endif
|
Accepting request 931785 from home:mslacken:sp
- updated to version 0.17.0
(Upstream feature/bug references (<ID>) are relative to
https://github.com/spack/spack/issues/<ID>).
* New concretizer is now default
The new concretizer introduced as an experimental feature in v0.16.0
is now the default (#25502). The new concretizer is based on the
clingo logic programming system,
and it enables us to do much higher quality and faster dependency solving
The old concretizer is still available via the concretizer: original
setting, but it is deprecated and will be removed in v0.18.0.
* Binary Bootstrapping
To make it easier to use the new concretizer and binary packages,
Spack now bootstraps clingo and GnuPG from public binaries. If it
is not able to bootstrap them from binaries, it installs them from
source code. With these changes, you should still be able to clone Spack
and start using it almost immediately.
* Reuse existing packages (experimental)
The most wanted feature from our
2020 user survey and
the most wanted Spack feature of all time (#25310). spack install,
spack spec, and spack concretize now have a --reuse option, which
causes Spack to minimize the number of rebuilds it does. The --reuse
option will try to find existing installations and binary packages locally
and in registered mirrors, and will prefer to use them over building new
versions. This will allow users to build from source far less than in
prior versions of Spack. This feature will continue to be improved, with
configuration options and better CLI expected in v0.17.1. It will become
the default concretization mode in v0.18.0.
* Better error messages
We have improved the error messages generated by the new concretizer by
OBS-URL: https://build.opensuse.org/request/show/931785
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=35
2021-11-16 15:32:55 +01:00
|
|
|
|
2020-11-19 15:49:24 +01:00
|
|
|
%build
|
|
|
|
# Nothing to build
|
2020-12-08 16:10:47 +01:00
|
|
|
%if %{with doc}
|
Accepting request 931785 from home:mslacken:sp
- updated to version 0.17.0
(Upstream feature/bug references (<ID>) are relative to
https://github.com/spack/spack/issues/<ID>).
* New concretizer is now default
The new concretizer introduced as an experimental feature in v0.16.0
is now the default (#25502). The new concretizer is based on the
clingo logic programming system,
and it enables us to do much higher quality and faster dependency solving
The old concretizer is still available via the concretizer: original
setting, but it is deprecated and will be removed in v0.18.0.
* Binary Bootstrapping
To make it easier to use the new concretizer and binary packages,
Spack now bootstraps clingo and GnuPG from public binaries. If it
is not able to bootstrap them from binaries, it installs them from
source code. With these changes, you should still be able to clone Spack
and start using it almost immediately.
* Reuse existing packages (experimental)
The most wanted feature from our
2020 user survey and
the most wanted Spack feature of all time (#25310). spack install,
spack spec, and spack concretize now have a --reuse option, which
causes Spack to minimize the number of rebuilds it does. The --reuse
option will try to find existing installations and binary packages locally
and in registered mirrors, and will prefer to use them over building new
versions. This will allow users to build from source far less than in
prior versions of Spack. This feature will continue to be improved, with
configuration options and better CLI expected in v0.17.1. It will become
the default concretization mode in v0.18.0.
* Better error messages
We have improved the error messages generated by the new concretizer by
OBS-URL: https://build.opensuse.org/request/show/931785
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=35
2021-11-16 15:32:55 +01:00
|
|
|
mkdir -p ${HOME}/.spack
|
|
|
|
cat > ${HOME}/.spack/config.yaml <<EOF
|
|
|
|
config:
|
|
|
|
install_tree:
|
|
|
|
root: /tmp/spack
|
|
|
|
projections:
|
|
|
|
all: "${ARCHITECTURE}/${COMPILERNAME}-${COMPILERVER}/${PACKAGE}-${VERSION}-${HASH}"
|
|
|
|
EOF
|
|
|
|
# Don't really run spack when building documentation!
|
|
|
|
tmpdir=$(mktemp -d %{_sourcedir}/tmpd-XXXXXXXXX)
|
|
|
|
echo -e '#! /bin/sh
|
|
|
|
args=${1+"$@"}
|
2021-11-17 09:47:48 +01:00
|
|
|
while [ -n "$1" ]; do
|
|
|
|
case $1 in
|
|
|
|
--*) shift ;;
|
Accepting request 1088985 from home:mslacken:sp
- Update to version 0.20.0 with the following features:
* Exact versions: Spack did not previously have a way to distinguish a
version if it was a prefix of some other version. For example, @3.2 would
match 3.2, 3.2.1, 3.2.2, etc. You can now match exactly 3.2 with @=3.2.
This is useful, for example, if you need to patch only the 3.2 version of a
package
* More stable concretization: Now, spack concretize will only concretize the
new portions of the environment and will not change existing parts of an
environment unless you specify --force. This has always been true for
unify:false, but not for unify:true and unify:when_possible environments.
* The concretizer has a new --reuse-deps argument that only reuses dependencies.
That is, it will always treat the roots of your environment as it would with
--fresh. This allows you to upgrade just the roots of your environment while
keeping everything else stable
* Specs in buildcaches can be referenced by hash: Previously, you could run
spack buildcache list and see the hashes in buildcaches, but referring to
them by hash would fail. You can now run commands like spack spec and
spack install and refer to buildcache hashes directly, e.g. spack install
/abc123
* New package and buildcache index websites
Our public websites for searching packages have been completely revamped
and updated. You can check them out here:
Package Index: https://packages.spack.io
Buildcache Index: https://cache.spack.io
Both are searchable and more interactive than before. Currently major
releases are shown; UI for browsing develop snapshots is coming soon.
* Default CMake and Meson build types are now Release: Spack has historically
defaulted to building with optimization and debugging, but packages like
llvm can be enormous with debug turned on. Our default build type for all
Spack packages is now Release. This has a number of benefits:
OBS-URL: https://build.opensuse.org/request/show/1088985
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=72
2023-06-01 11:34:31 +02:00
|
|
|
graph|spec|unit-test) exit 0 ;;
|
2023-06-26 21:56:48 +02:00
|
|
|
*) exec %{_bindir}/spack ${args} ;;
|
2021-11-17 09:47:48 +01:00
|
|
|
esac;
|
Accepting request 931785 from home:mslacken:sp
- updated to version 0.17.0
(Upstream feature/bug references (<ID>) are relative to
https://github.com/spack/spack/issues/<ID>).
* New concretizer is now default
The new concretizer introduced as an experimental feature in v0.16.0
is now the default (#25502). The new concretizer is based on the
clingo logic programming system,
and it enables us to do much higher quality and faster dependency solving
The old concretizer is still available via the concretizer: original
setting, but it is deprecated and will be removed in v0.18.0.
* Binary Bootstrapping
To make it easier to use the new concretizer and binary packages,
Spack now bootstraps clingo and GnuPG from public binaries. If it
is not able to bootstrap them from binaries, it installs them from
source code. With these changes, you should still be able to clone Spack
and start using it almost immediately.
* Reuse existing packages (experimental)
The most wanted feature from our
2020 user survey and
the most wanted Spack feature of all time (#25310). spack install,
spack spec, and spack concretize now have a --reuse option, which
causes Spack to minimize the number of rebuilds it does. The --reuse
option will try to find existing installations and binary packages locally
and in registered mirrors, and will prefer to use them over building new
versions. This will allow users to build from source far less than in
prior versions of Spack. This feature will continue to be improved, with
configuration options and better CLI expected in v0.17.1. It will become
the default concretization mode in v0.18.0.
* Better error messages
We have improved the error messages generated by the new concretizer by
OBS-URL: https://build.opensuse.org/request/show/931785
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=35
2021-11-16 15:32:55 +01:00
|
|
|
done
|
|
|
|
exit 0' > $tmpdir/spack
|
|
|
|
chmod 0755 $tmpdir/spack
|
|
|
|
PATH=$tmpdir:${PATH}
|
|
|
|
export PATH
|
|
|
|
mkdir -p /tmp/spack
|
2020-12-08 16:10:47 +01:00
|
|
|
cd lib/spack/docs
|
Accepting request 931785 from home:mslacken:sp
- updated to version 0.17.0
(Upstream feature/bug references (<ID>) are relative to
https://github.com/spack/spack/issues/<ID>).
* New concretizer is now default
The new concretizer introduced as an experimental feature in v0.16.0
is now the default (#25502). The new concretizer is based on the
clingo logic programming system,
and it enables us to do much higher quality and faster dependency solving
The old concretizer is still available via the concretizer: original
setting, but it is deprecated and will be removed in v0.18.0.
* Binary Bootstrapping
To make it easier to use the new concretizer and binary packages,
Spack now bootstraps clingo and GnuPG from public binaries. If it
is not able to bootstrap them from binaries, it installs them from
source code. With these changes, you should still be able to clone Spack
and start using it almost immediately.
* Reuse existing packages (experimental)
The most wanted feature from our
2020 user survey and
the most wanted Spack feature of all time (#25310). spack install,
spack spec, and spack concretize now have a --reuse option, which
causes Spack to minimize the number of rebuilds it does. The --reuse
option will try to find existing installations and binary packages locally
and in registered mirrors, and will prefer to use them over building new
versions. This will allow users to build from source far less than in
prior versions of Spack. This feature will continue to be improved, with
configuration options and better CLI expected in v0.17.1. It will become
the default concretization mode in v0.18.0.
* Better error messages
We have improved the error messages generated by the new concretizer by
OBS-URL: https://build.opensuse.org/request/show/931785
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=35
2021-11-16 15:32:55 +01:00
|
|
|
# fix Makefile of sphinx and ignore warnings due to offline build
|
|
|
|
sed -i 's/\(^SPHINXOPTS\).*/\1 = --keep-going /' Makefile
|
2020-12-08 16:10:47 +01:00
|
|
|
# Causes issues building texinfo as a suitable image cannot be found
|
|
|
|
grep -rl ":target:" | xargs sed -i -e "/:target:/s/^/#/" -e "/figure::/s/^/#/"
|
|
|
|
# Fix path to var - we install this to the 'real' /var
|
|
|
|
grep -rl "\$SPACK_ROOT/var" | xargs sed -i -e "s@\(.*\)\$SPACK_ROOT/var\(/spack.*\)@\1/var/lib\2@g"
|
2023-01-12 12:55:47 +01:00
|
|
|
grep -rl '/var/lib/spack/repos' | grep -v "cmd/list.py" | \
|
|
|
|
xargs -i@ sed -i 's|/var/lib/spack/repos|/usr/share/spack/repos|g' @
|
2021-03-16 16:29:38 +01:00
|
|
|
# spack cannot run without knowing at least the compiler, so we inject
|
2020-12-11 16:11:15 +01:00
|
|
|
# a dummy one
|
2021-03-16 16:29:38 +01:00
|
|
|
mkdir -p ${HOME}/.spack/linux/
|
2020-12-11 16:11:15 +01:00
|
|
|
cat > ${HOME}/.spack/linux/compilers.yaml <<EOF
|
|
|
|
compilers:
|
|
|
|
- compiler:
|
|
|
|
spec: gcc@7.5.0
|
|
|
|
paths:
|
2023-06-26 21:56:48 +02:00
|
|
|
cc: %{_bindir}/gcc
|
|
|
|
cxx: %{_bindir}/g++
|
|
|
|
f77: %{_bindir}/gfortran
|
|
|
|
fc: %{_bindir}/gfortran
|
2020-12-11 16:11:15 +01:00
|
|
|
flags: {}
|
|
|
|
operating_system: SUSE
|
|
|
|
target: x86_64
|
|
|
|
modules: []
|
|
|
|
environment:
|
|
|
|
unset: []
|
|
|
|
extra_rpaths: []
|
|
|
|
EOF
|
Accepting request 931785 from home:mslacken:sp
- updated to version 0.17.0
(Upstream feature/bug references (<ID>) are relative to
https://github.com/spack/spack/issues/<ID>).
* New concretizer is now default
The new concretizer introduced as an experimental feature in v0.16.0
is now the default (#25502). The new concretizer is based on the
clingo logic programming system,
and it enables us to do much higher quality and faster dependency solving
The old concretizer is still available via the concretizer: original
setting, but it is deprecated and will be removed in v0.18.0.
* Binary Bootstrapping
To make it easier to use the new concretizer and binary packages,
Spack now bootstraps clingo and GnuPG from public binaries. If it
is not able to bootstrap them from binaries, it installs them from
source code. With these changes, you should still be able to clone Spack
and start using it almost immediately.
* Reuse existing packages (experimental)
The most wanted feature from our
2020 user survey and
the most wanted Spack feature of all time (#25310). spack install,
spack spec, and spack concretize now have a --reuse option, which
causes Spack to minimize the number of rebuilds it does. The --reuse
option will try to find existing installations and binary packages locally
and in registered mirrors, and will prefer to use them over building new
versions. This will allow users to build from source far less than in
prior versions of Spack. This feature will continue to be improved, with
configuration options and better CLI expected in v0.17.1. It will become
the default concretization mode in v0.18.0.
* Better error messages
We have improved the error messages generated by the new concretizer by
OBS-URL: https://build.opensuse.org/request/show/931785
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=35
2021-11-16 15:32:55 +01:00
|
|
|
source /usr/share/spack/setup-env.sh
|
|
|
|
make man info || { cat /tmp/sphinx-err-*.log; exit 1; } #text dirhtml
|
|
|
|
rm -rf $tmpdir
|
2020-12-08 16:10:47 +01:00
|
|
|
gzip _build/texinfo/Spack.info _build/man/spack.1
|
2023-01-12 12:55:47 +01:00
|
|
|
# with doc
|
2020-12-08 16:10:47 +01:00
|
|
|
%endif
|
2023-01-11 22:36:28 +01:00
|
|
|
cd -
|
2024-02-12 11:43:18 +01:00
|
|
|
grep -rl '#! /usr/bin/env bash' . | xargs -i@ sed -i '1s|#! /usr/bin/env bash|#!%{_bindir}/bash|g' @
|
|
|
|
grep -rl '#!/bin/env sh' . | xargs -i@ sed -i '1s|#!/bin/env sh|#!%{_bindir}/sh|g' @
|
|
|
|
grep -rl '#!/usr/bin/env bash' . | xargs -i@ sed -i '1s|#!/usr/bin/env bash|#!%{_bindir}/bash|g' @
|
|
|
|
grep -rl '#![[:space:]]*/usr/bin/env python' | \
|
|
|
|
xargs -i@ sed -i '1s|#![[:space:]]*/usr/bin/env python|#!%{_bindir}/%{mypython}|g' @
|
2023-01-12 00:27:26 +01:00
|
|
|
grep -rl '/var/spack/repos' | grep -v "cmd/list.py" | \
|
|
|
|
xargs -i@ sed -i 's|/var/spack/repos|/usr/share/spack/repos|g' @
|
2023-01-11 22:36:28 +01:00
|
|
|
grep -rl "spack/" . | xargs -i@ sed -i \
|
|
|
|
-e 's|$spack/opt|/opt|g' \
|
|
|
|
-e 's|$spack/var|/var/lib|g'\
|
2023-01-12 00:27:26 +01:00
|
|
|
-e 's|$spack/usr|/usr|g'\
|
2023-01-11 22:36:28 +01:00
|
|
|
-e 's|$spack/share/spack/lmod|/opt/spack/modules|g'\
|
|
|
|
-e 's|$spack/share/spack/modules|/opt/spack/modules|g'\
|
|
|
|
@
|
2020-11-19 15:49:24 +01:00
|
|
|
|
|
|
|
%install
|
2021-07-26 15:26:41 +02:00
|
|
|
# combine READMEs
|
|
|
|
cat %{S:4} >> %{S:1}
|
2020-12-08 16:10:47 +01:00
|
|
|
%if %{without doc}
|
|
|
|
cp %{S:1} .
|
2020-11-19 15:49:24 +01:00
|
|
|
# Fix some rpmlint warnings
|
|
|
|
## Remove files not required to run spack
|
|
|
|
rm -rf lib/spack/spack/test
|
|
|
|
rm -rf share/spack/qa
|
2020-12-08 16:10:47 +01:00
|
|
|
rm -rf share/spack/logo
|
2020-11-19 15:49:24 +01:00
|
|
|
rm -rf var/spack/repos/builtin.mock var/spack/gpg.mock var/spack/mock_configs
|
|
|
|
rm -rf lib/spack/external/ruamel/yaml/.ruamel
|
|
|
|
find . -type f -name .gitignore -delete
|
|
|
|
find . -type f -name .nojekyll -delete
|
2022-12-05 12:17:15 +01:00
|
|
|
find . -type f -name .gitlab-ci.yml -delete
|
|
|
|
|
2020-12-08 16:10:47 +01:00
|
|
|
# Fix _spack_root link
|
2020-11-19 15:49:24 +01:00
|
|
|
rm -f lib/spack/docs/_spack_root
|
|
|
|
ln -sf ../.. lib/spack/docs/_spack_root
|
2020-12-08 16:10:47 +01:00
|
|
|
# Do not ship AWS specifics
|
|
|
|
rm -f share/spack/setup-tutorial-env.sh
|
|
|
|
# Fix rpmlint warnings
|
2020-11-19 15:49:24 +01:00
|
|
|
## No need for the standalone scripts
|
|
|
|
rm -f lib/spack/external/macholib/macho_*.py
|
2022-11-26 12:34:27 +01:00
|
|
|
## Remove non linux stuff
|
|
|
|
rm -f bin/spack.bat bin/spack_cmd.bat bin/spack_pwsh.ps1
|
2020-11-19 15:49:24 +01:00
|
|
|
|
|
|
|
mkdir -p %{buildroot}%{spack_dir}
|
|
|
|
mkdir -p %{buildroot}%{spack_dir}/opt
|
2020-12-08 16:10:47 +01:00
|
|
|
mkdir -p %{buildroot}%{_datarootdir}/spack/lib/spack
|
2020-11-19 15:49:24 +01:00
|
|
|
mkdir -p %{buildroot}%{_datarootdir}/spack/modules
|
|
|
|
mkdir -p %{buildroot}%{_localstatedir}/lib/spack
|
|
|
|
mkdir -p %{buildroot}%{_localstatedir}/lib/spack/junit-report
|
|
|
|
mkdir -p %{buildroot}%{_localstatedir}/cache/spack
|
|
|
|
mkdir -p %{buildroot}%{_sysconfdir}/skel/.spack/
|
|
|
|
mkdir -p %{buildroot}/%{_bindir}
|
2020-12-08 16:10:47 +01:00
|
|
|
# Link avoids having to fix paths
|
2020-11-19 15:49:24 +01:00
|
|
|
ln -sf %{buildroot}/%{_localstatedir}/cache/spack %{buildroot}%{_localstatedir}/lib/spack/cache
|
|
|
|
|
|
|
|
# Copy files to corresponding paths
|
2020-12-08 16:10:47 +01:00
|
|
|
cp -r etc %{buildroot}%{_prefix}
|
2022-11-24 08:38:21 +01:00
|
|
|
cp -r lib/spack/{env,external,llnl,spack,spack_installable} %{buildroot}%{spack_dir}
|
2020-11-19 15:49:24 +01:00
|
|
|
cp -r share/spack/* %{buildroot}%{_datarootdir}/spack
|
|
|
|
cp -r var/spack/* %{buildroot}%{_localstatedir}/lib/spack
|
2023-01-11 15:53:34 +01:00
|
|
|
# No repos in /var
|
|
|
|
mv %{buildroot}%{_localstatedir}/lib/spack/repos %{buildroot}%{_datarootdir}/spack
|
2020-11-19 15:49:24 +01:00
|
|
|
cp -r bin/sbang %{buildroot}/%{_bindir}
|
2020-12-08 16:10:47 +01:00
|
|
|
cp -r bin/spack* %{buildroot}%{_bindir}/
|
2023-05-04 12:15:58 +02:00
|
|
|
cp %{S:6} %{buildroot}%{_bindir}/
|
|
|
|
chmod 0755 %{buildroot}%{_bindir}/%{basename:%{S:6}}
|
2020-11-19 15:49:24 +01:00
|
|
|
cp etc/spack/defaults/config.yaml %{buildroot}%{_sysconfdir}/skel/.spack/
|
2021-03-31 17:51:48 +02:00
|
|
|
install -m 755 %{S:3} %{buildroot}/%{spack_dir}/run-find-external.sh
|
2022-01-12 17:44:43 +01:00
|
|
|
sed -i -e 's#@@_sysconfdir@@#%{_sysconfdir}#' %{buildroot}/%{spack_dir}/run-find-external.sh
|
2024-03-16 18:10:02 +01:00
|
|
|
sed -i -e '/. \/opt/s#/opt/spack/#/usr/#' %{buildroot}/%{_datarootdir}/spack/templates/container/singularity.def
|
|
|
|
%{?spack_container_packages:
|
|
|
|
sed -i -e 's/\(zypper update -y\)/\1 \&\& zypper -n in -y %{spack_container_packages}/' \
|
|
|
|
%{buildroot}%{spack_dir}/spack/container/images.json}
|
2021-12-14 12:16:05 +01:00
|
|
|
# Make spack only to write to home dir of user, if run as user
|
|
|
|
sed -i 's@\(\sroot:\) /opt/spack@\1 ~/spack/packages@' %{buildroot}%{_sysconfdir}/skel/.spack/config.yaml
|
2020-11-19 15:49:24 +01:00
|
|
|
sed -i 's@\(\ssource_cache:\).*@\1 /var/tmp/$user/spack-cache@' %{buildroot}%{_sysconfdir}/skel/.spack/config.yaml
|
2020-12-08 16:10:47 +01:00
|
|
|
cat >> %{buildroot}%{_sysconfdir}/skel/.spack/config.yaml <<EOF
|
2022-11-24 08:38:21 +01:00
|
|
|
|
2020-12-08 16:10:47 +01:00
|
|
|
binary_index_root: ~/.spack/indices
|
|
|
|
EOF
|
2020-11-19 15:49:24 +01:00
|
|
|
|
2021-12-14 12:16:05 +01:00
|
|
|
cat >> %{buildroot}%{_sysconfdir}/skel/.spack/modules.yaml <<EOF
|
|
|
|
modules:
|
|
|
|
default:
|
|
|
|
roots:
|
|
|
|
tcl: ~/spack/modules
|
|
|
|
lmod: ~/spack/modules
|
|
|
|
EOF
|
|
|
|
|
2024-02-12 11:43:18 +01:00
|
|
|
# compile python files for %{mypython}
|
2020-12-08 16:10:47 +01:00
|
|
|
# %%{buildroot}%%{spack_dir}/spack
|
2024-02-12 11:43:18 +01:00
|
|
|
%{expand:%{py%{?mypyver}_compile .}}
|
2020-11-19 15:49:24 +01:00
|
|
|
|
|
|
|
# make shell scripts executeable
|
|
|
|
find %{buildroot}%{_localstatedir}/lib/spack/ -type f -name \*.sh -exec chmod 755 {} \;
|
|
|
|
|
2023-03-30 16:41:13 +02:00
|
|
|
# Create %{_sysconfdir}/spack/compilers.yaml
|
2020-11-19 15:49:24 +01:00
|
|
|
mkdir -p %{buildroot}%{spack_dir}/etc/spack/
|
|
|
|
cat > %{buildroot}%{spack_dir}/etc/spack/compilers.yaml <<EOF
|
|
|
|
compilers:
|
|
|
|
- compiler:
|
|
|
|
spec: gcc@GCC_FULL_VERSION
|
|
|
|
paths:
|
2023-06-26 21:56:48 +02:00
|
|
|
cc: %{_bindir}/gcc-GCC_VERSION
|
|
|
|
cxx: %{_bindir}/g++-GCC_VERSION
|
|
|
|
f77: %{_bindir}/gfortran-GCC_VERSION
|
|
|
|
fc: %{_bindir}/gfortran-GCC_VERSION
|
2020-11-19 15:49:24 +01:00
|
|
|
flags: {}
|
|
|
|
operating_system: SUSE_VERSION
|
|
|
|
target: HOSTTYPE
|
|
|
|
modules: []
|
|
|
|
environment:
|
|
|
|
unset: []
|
|
|
|
extra_rpaths: []
|
|
|
|
EOF
|
|
|
|
|
2023-03-30 16:41:13 +02:00
|
|
|
# Create %{_sysconfdir}/profile.d/spack.sh
|
2020-11-19 15:49:24 +01:00
|
|
|
# This file properly sets MODULEPATH so lua-lmod can find the modules created by spack
|
|
|
|
mkdir -p %{buildroot}/%{_sysconfdir}/profile.d
|
|
|
|
cat > %{buildroot}/%{_sysconfdir}/profile.d/spack.sh <<EOF
|
2023-08-13 14:55:40 +02:00
|
|
|
ID=\$(source /etc/os-release; echo \${ID})
|
2022-08-19 15:09:17 +02:00
|
|
|
if [ "\${ID}" = "opensuse-tumbleweed" ] ; then
|
2020-11-19 15:49:24 +01:00
|
|
|
SPACK_NAME="\${ID/-/}"
|
|
|
|
else
|
|
|
|
SPACK_NAME="\${ID/-/_}\${VERSION_ID/.*/}"
|
|
|
|
fi
|
2023-08-13 14:55:40 +02:00
|
|
|
export SPACK_ROOT=%{_prefix}
|
2021-03-19 17:07:22 +01:00
|
|
|
export MODULEPATH=~/spack/modules/linux-\${SPACK_NAME}-\${CPU}:%{_prefix}/share/spack/modules/linux-\${SPACK_NAME}-\${CPU}:\${MODULEPATH}
|
2020-11-19 15:49:24 +01:00
|
|
|
# copy local configuration, if its not there
|
|
|
|
if [ ! -e ~/.spack/config.yaml ] ; then
|
|
|
|
# test if user is in spack group by touching database
|
|
|
|
if ! touch %{spack_dir}/.spack-db &> /dev/null ; then
|
|
|
|
test -e ~/.spack || mkdir -p ~/.spack
|
|
|
|
[ -e ~/.spack/config.yaml ] || \
|
|
|
|
cp -r %{_sysconfdir}/skel/.spack/config.yaml ~/.spack/
|
2021-12-14 12:16:05 +01:00
|
|
|
[ -e ~/.spack/modules.yaml ] || \
|
|
|
|
cp -r %{_sysconfdir}/skel/.spack/modules.yaml ~/.spack/
|
2020-11-19 15:49:24 +01:00
|
|
|
fi
|
|
|
|
fi
|
|
|
|
EOF
|
|
|
|
# Same for csh
|
|
|
|
cat > %{buildroot}/%{_sysconfdir}/profile.d/spack.csh <<EOF
|
|
|
|
# get ID
|
|
|
|
eval \`awk '/^ID=/ {sub("-","_"); printf("set %%s",\$0);}' /etc/os-release\`
|
|
|
|
# get VERSION_ID
|
|
|
|
eval \`awk '/^VERSION_ID=/ {sub("\\\\.[0-9]",""); printf("set %%s",\$0);}' /etc/os-release\`
|
|
|
|
if ( \$ID == "opensuse_tumbleweed" ) then
|
|
|
|
eval \`awk '/^ID=/ {sub("-",""); printf("set %%s",\$0);}' /etc/os-release\`
|
|
|
|
set SPACK_NAME=\$ID
|
2021-03-16 16:29:38 +01:00
|
|
|
else
|
2020-11-19 15:49:24 +01:00
|
|
|
set SPACK_NAME="\${ID}\${VERSION_ID}"
|
2021-03-16 16:29:38 +01:00
|
|
|
endif
|
2023-08-13 14:55:40 +02:00
|
|
|
set SPACK_ROOT="%{_prefix}"
|
2021-03-19 17:07:22 +01:00
|
|
|
set MODULEPATH="~/spack/modules/linux-\${SPACK_NAME}-\${CPU}:%{_prefix}/share/spack/modules/linux-\${SPACK_NAME}-\${CPU}:\${MODULEPATH}"
|
2020-11-19 15:49:24 +01:00
|
|
|
if ( ! -e ~/.spack/config.yaml ) then
|
|
|
|
# test if user is in spack group by touching database
|
|
|
|
touch %{spack_dir}/.spack-db >& /dev/null
|
|
|
|
if ( \$? == 1 ) then
|
|
|
|
test -e ~/.spack || mkdir -p ~/.spack
|
|
|
|
test -e ~/.spack/config.yaml || \
|
|
|
|
cp -r %{_sysconfdir}/skel/.spack/config.yaml ~/.spack/
|
2021-12-14 12:16:05 +01:00
|
|
|
test -e ~/.spack/modules.yaml || \
|
|
|
|
cp -r %{_sysconfdir}/skel/.spack/modules.yaml ~/.spack/
|
2020-11-19 15:49:24 +01:00
|
|
|
endif
|
|
|
|
endif
|
|
|
|
|
|
|
|
EOF
|
2021-12-14 12:16:05 +01:00
|
|
|
## Create modules.yaml file, so that hierarchy module files are created
|
|
|
|
#cat > %{buildroot}%{spack_dir}/etc/spack/modules.yaml <<EOF
|
|
|
|
#modules:
|
|
|
|
# enable:
|
|
|
|
# - lmod
|
|
|
|
# lmod:
|
|
|
|
# core_compilers:
|
|
|
|
# - 'gcc@GCC_FULL_VERSION'
|
|
|
|
# projections:
|
|
|
|
# all: '{compiler.name}-{compiler.version}/{name}/{version}'
|
|
|
|
# ^mpi: '{compiler.name}-{compiler.version}/{^mpi.name}-{^mpi.version}/{name}/{version}'
|
|
|
|
#EOF
|
2020-12-08 16:10:47 +01:00
|
|
|
mkdir -p %{buildroot}%{_sysconfdir}/spack
|
2020-11-19 15:49:24 +01:00
|
|
|
|
|
|
|
# Fix link to not point into buildroot
|
|
|
|
rm -f %{buildroot}%{_localstatedir}/lib/spack/cache
|
|
|
|
ln -sf %{_localstatedir}/cache/spack %{buildroot}%{_localstatedir}/lib/spack/cache
|
2020-12-08 16:10:47 +01:00
|
|
|
# Remove problematic binaries which are removed upstream with
|
|
|
|
# 0889be20e0d9dcdf4346cdeaa0647285187375f3
|
2023-01-11 15:53:34 +01:00
|
|
|
rm -r %{buildroot}%{_datarootdir}/spack/repos/builtin/packages/patchelf/test/
|
2021-10-04 15:55:13 +02:00
|
|
|
|
2021-10-18 16:45:44 +02:00
|
|
|
echo "g %{name} -" > system-group-%{name}.conf
|
|
|
|
%sysusers_generate_pre system-group-%{name}.conf %{name} system-group-%{name}.conf
|
|
|
|
install -D -m 644 system-group-%{name}.conf %{buildroot}%{_sysusersdir}/system-group-%{name}.conf
|
2021-10-04 15:55:13 +02:00
|
|
|
|
2020-11-19 15:49:24 +01:00
|
|
|
%fdupes %{buildroot}%{spack_dir}
|
|
|
|
%fdupes %{buildroot}%{_datarootdir}/spack
|
|
|
|
%fdupes %{buildroot}%{_localstatedir}/lib/spack
|
2022-01-12 17:44:43 +01:00
|
|
|
%{?_distconfdir:%fdupes %{buildroot}/%{_distconfdir}/spack}
|
2020-12-08 16:10:47 +01:00
|
|
|
%else
|
|
|
|
mkdir -p %{buildroot}%{_infodir}
|
|
|
|
mkdir -p %{buildroot}%{_mandir}/man1
|
|
|
|
cd lib/spack/docs/_build
|
|
|
|
cp man/spack.1.gz %{buildroot}%{_mandir}/man1/
|
2021-02-04 19:31:35 +01:00
|
|
|
cp -r texinfo/Spack.info.gz %{buildroot}%{_infodir}
|
|
|
|
[ -d texinfo/Spack-figures ] && cp -r texinfo/Spack-figures %{buildroot}%{_infodir}
|
2020-12-08 16:10:47 +01:00
|
|
|
%endif
|
2020-11-19 15:49:24 +01:00
|
|
|
|
2023-03-30 16:41:13 +02:00
|
|
|
%if %{without doc}
|
|
|
|
# for sysusers
|
2021-10-04 15:55:13 +02:00
|
|
|
%pre -f %{name}.pre
|
2020-11-19 15:49:24 +01:00
|
|
|
|
|
|
|
%post
|
2023-03-30 16:41:13 +02:00
|
|
|
# Replace %{_sysconfdir}/spack/compilers.yaml
|
2020-11-19 15:49:24 +01:00
|
|
|
export GCC_VERSION=`gcc -dumpversion`
|
|
|
|
export GCC_FULL_VERSION=`gcc -dumpfullversion`
|
2021-12-14 12:16:05 +01:00
|
|
|
#sed -i "s@GCC_FULL_VERSION@$GCC_FULL_VERSION@" %{spack_dir}/etc/spack/modules.yaml
|
2020-11-19 15:49:24 +01:00
|
|
|
if [ -e /etc/os-release ] ; then
|
|
|
|
source /etc/os-release
|
2022-08-19 15:09:17 +02:00
|
|
|
if [ "${ID}" = "opensuse-tumbleweed" ] ; then
|
2020-11-19 15:49:24 +01:00
|
|
|
export SPACK_NAME="${ID/-/}"
|
|
|
|
else
|
|
|
|
export SPACK_NAME="${ID/-/_}${VERSION_ID/.*/}"
|
|
|
|
fi
|
|
|
|
sed -i "s@SUSE_VERSION@$SPACK_NAME@" %{spack_dir}/etc/spack/compilers.yaml
|
2023-03-30 16:41:13 +02:00
|
|
|
sed -i "s@SUSE_VERSION@$SPACK_NAME@g" %{_sysconfdir}/profile.d/spack.sh
|
2020-11-19 15:49:24 +01:00
|
|
|
fi
|
2023-03-30 16:41:13 +02:00
|
|
|
sed -i "s@GCC_FULL_VERSION@$GCC_FULL_VERSION@" %{spack_dir}/etc/spack/compilers.yaml
|
|
|
|
sed -i "s@GCC_VERSION@$GCC_VERSION@" %{spack_dir}/etc/spack/compilers.yaml
|
2020-11-19 15:49:24 +01:00
|
|
|
sed -i "s@HOSTTYPE@$HOSTTYPE@" %{spack_dir}/etc/spack/compilers.yaml
|
Accepting request 931785 from home:mslacken:sp
- updated to version 0.17.0
(Upstream feature/bug references (<ID>) are relative to
https://github.com/spack/spack/issues/<ID>).
* New concretizer is now default
The new concretizer introduced as an experimental feature in v0.16.0
is now the default (#25502). The new concretizer is based on the
clingo logic programming system,
and it enables us to do much higher quality and faster dependency solving
The old concretizer is still available via the concretizer: original
setting, but it is deprecated and will be removed in v0.18.0.
* Binary Bootstrapping
To make it easier to use the new concretizer and binary packages,
Spack now bootstraps clingo and GnuPG from public binaries. If it
is not able to bootstrap them from binaries, it installs them from
source code. With these changes, you should still be able to clone Spack
and start using it almost immediately.
* Reuse existing packages (experimental)
The most wanted feature from our
2020 user survey and
the most wanted Spack feature of all time (#25310). spack install,
spack spec, and spack concretize now have a --reuse option, which
causes Spack to minimize the number of rebuilds it does. The --reuse
option will try to find existing installations and binary packages locally
and in registered mirrors, and will prefer to use them over building new
versions. This will allow users to build from source far less than in
prior versions of Spack. This feature will continue to be improved, with
configuration options and better CLI expected in v0.17.1. It will become
the default concretization mode in v0.18.0.
* Better error messages
We have improved the error messages generated by the new concretizer by
OBS-URL: https://build.opensuse.org/request/show/931785
OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=35
2021-11-16 15:32:55 +01:00
|
|
|
mkdir -p /opt/spack
|
|
|
|
chgrp spack /opt/spack
|
|
|
|
chmod 0775 /opt/spack
|
2020-11-19 15:49:24 +01:00
|
|
|
|
2023-03-09 08:41:20 +01:00
|
|
|
%triggerin -- %{?spack_trigger_recommended_packages} %{?spack_trigger_packages} %{?spack_trigger_external}
|
|
|
|
/usr/lib/spack/run-find-external.sh packages
|
|
|
|
|
|
|
|
%triggerin -- %{?spack_trigger_recommended_compilers} %{?spack_trigger_compilers}
|
|
|
|
/usr/lib/spack/run-find-external.sh compilers
|
|
|
|
|
|
|
|
%triggerpostun -- %{?spack_trigger_recommended_packages} %{?spack_trigger_packages} %{?spack_trigger_external}
|
|
|
|
/usr/lib/spack/run-find-external.sh packages
|
2021-02-04 19:31:35 +01:00
|
|
|
|
2023-03-09 08:41:20 +01:00
|
|
|
%triggerpostun -- %{?spack_trigger_recommended_compilers} %{?spack_trigger_compilers}
|
|
|
|
/usr/lib/spack/run-find-external.sh compilers
|
2020-12-08 16:10:47 +01:00
|
|
|
|
2020-11-19 15:49:24 +01:00
|
|
|
%files
|
|
|
|
%license COPYRIGHT LICENSE-APACHE LICENSE-MIT
|
2020-12-08 16:10:47 +01:00
|
|
|
%doc CHANGELOG.md NOTICE README.md README.SUSE
|
|
|
|
%dir %{_sysconfdir}/spack/
|
2020-11-19 15:49:24 +01:00
|
|
|
%{_bindir}/*
|
2020-12-08 16:10:47 +01:00
|
|
|
%if 0%{?suse_version} <= 1500
|
|
|
|
%dir %{_prefix}/etc
|
|
|
|
%endif
|
|
|
|
%{_prefix}/etc/spack
|
2023-03-30 16:41:13 +02:00
|
|
|
%ghost %config %{_sysconfdir}/spack/compilers.yaml
|
2020-11-19 15:49:24 +01:00
|
|
|
%attr(0775, root, spack) %{_localstatedir}/lib/spack/junit-report
|
|
|
|
%attr(0775, root, spack) %{spack_dir}/opt
|
|
|
|
%attr(0775, root, spack) %{_localstatedir}/cache/spack
|
|
|
|
%attr(0775, root, spack) %{_datarootdir}/spack/modules
|
2020-12-08 16:10:47 +01:00
|
|
|
%{spack_dir}
|
2020-11-19 15:49:24 +01:00
|
|
|
%{_localstatedir}/cache/spack
|
|
|
|
%{_localstatedir}/lib/spack
|
|
|
|
%{_datarootdir}/spack
|
2023-01-11 15:53:34 +01:00
|
|
|
%exclude %{_datarootdir}/spack/repos
|
2020-11-19 15:49:24 +01:00
|
|
|
%config %{_sysconfdir}/profile.d/spack.sh
|
2021-03-30 16:36:39 +02:00
|
|
|
%ghost %config %{_sysconfdir}/spack/packages.yaml
|
2020-11-19 15:49:24 +01:00
|
|
|
%config %{_sysconfdir}/profile.d/spack.csh
|
|
|
|
%dir %{_sysconfdir}/skel/.spack
|
|
|
|
%config %{_sysconfdir}/skel/.spack/config.yaml
|
2021-12-14 12:16:05 +01:00
|
|
|
%config %{_sysconfdir}/skel/.spack/modules.yaml
|
2020-11-19 15:49:24 +01:00
|
|
|
# repos directory is installed in -recipes
|
2021-10-18 16:45:44 +02:00
|
|
|
%{_sysusersdir}/system-group-%{name}.conf
|
2020-11-19 15:49:24 +01:00
|
|
|
|
|
|
|
%files recipes
|
|
|
|
%license COPYRIGHT LICENSE-APACHE LICENSE-MIT
|
|
|
|
%doc CHANGELOG.md NOTICE README.md
|
2023-01-11 15:53:34 +01:00
|
|
|
%{_datarootdir}/spack/repos
|
2020-11-19 15:49:24 +01:00
|
|
|
|
2023-03-30 16:41:13 +02:00
|
|
|
#%{without doc}
|
2020-12-08 16:10:47 +01:00
|
|
|
%else
|
2021-02-04 19:31:35 +01:00
|
|
|
|
2023-03-30 16:41:13 +02:00
|
|
|
%if 0%{?suse_version} <= 1500
|
2021-02-04 19:31:35 +01:00
|
|
|
%post info
|
|
|
|
%install_info --info-dir=%{_infodir} --info-file="%{_infodir}/Spack.info.gz"
|
|
|
|
|
|
|
|
%preun info
|
|
|
|
%install_info_delete --info-dir=%{_infodir} --info-file="%{_infodir}/Spack.info.gz"
|
2023-03-30 16:41:13 +02:00
|
|
|
%endif
|
2021-02-04 19:31:35 +01:00
|
|
|
|
2020-12-08 16:10:47 +01:00
|
|
|
%files man
|
|
|
|
%{_mandir}/man1/*
|
|
|
|
|
|
|
|
%files info
|
|
|
|
%{_infodir}/*
|
|
|
|
|
|
|
|
%endif
|
2020-11-19 15:49:24 +01:00
|
|
|
|
|
|
|
%changelog
|