From 9e2a9f8be2e919276523bfc0e058bfef63637735238ead3cff91870f55c846d1 Mon Sep 17 00:00:00 2001 From: Christian Goll <cgoll@suse.com> Date: Fri, 19 Aug 2022 13:09:17 +0000 Subject: [PATCH] Accepting request 995220 from home:dirkmueller:Factory - avoid bashism in post scripts (bsc#1195391) OBS-URL: https://build.opensuse.org/request/show/995220 OBS-URL: https://build.opensuse.org/package/show/network:cluster/spack?expand=0&rev=47 --- spack.changes | 5 +++++ spack.spec | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/spack.changes b/spack.changes index 3dc7f25..058db5e 100644 --- a/spack.changes +++ b/spack.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon Aug 15 19:39:22 UTC 2022 - Dirk Müller <dmueller@suse.com> + +- avoid bashism in post scripts (bsc#1195391) + ------------------------------------------------------------------- Thu Apr 7 12:56:45 UTC 2022 - Egbert Eich <eich@suse.com> diff --git a/spack.spec b/spack.spec index a80fad2..9fbe0f2 100644 --- a/spack.spec +++ b/spack.spec @@ -337,7 +337,7 @@ EOF mkdir -p %{buildroot}/%{_sysconfdir}/profile.d cat > %{buildroot}/%{_sysconfdir}/profile.d/spack.sh <<EOF source /etc/os-release -if [ "\${ID}" == "opensuse-tumbleweed" ] ; then +if [ "\${ID}" = "opensuse-tumbleweed" ] ; then SPACK_NAME="\${ID/-/}" else SPACK_NAME="\${ID/-/_}\${VERSION_ID/.*/}" @@ -433,7 +433,7 @@ sed -i "s@GCC_FULL_VERSION@$GCC_FULL_VERSION@" %{spack_dir}/etc/spack/compilers. sed -i "s@GCC_VERSION@$GCC_VERSION@" %{spack_dir}/etc/spack/compilers.yaml if [ -e /etc/os-release ] ; then source /etc/os-release - if [ "${ID}" == "opensuse-tumbleweed" ] ; then + if [ "${ID}" = "opensuse-tumbleweed" ] ; then export SPACK_NAME="${ID/-/}" else export SPACK_NAME="${ID/-/_}${VERSION_ID/.*/}"