Skip to content
Snippets Groups Projects
Commit abaddf6a authored by Philipp Spilger's avatar Philipp Spilger
Browse files

feat: Fetch specs with correct compiler constraint

Change-Id: I2b72fd1abc480deae4ac38ea4bd2be4055f442ad
parent c423616a
No related branches found
No related tags found
No related merge requests found
......@@ -91,13 +91,9 @@ for package in "${packages_to_fetch[@]}"; do
eval "${oldstate}"
tmp_err="$(mktemp)"
tmpfiles_concretize_err+=("${tmp_err}")
# We need to strip the compiler spec starting with '%' from the spec string
# because the compiler is not yet known.
# Note that this will also delete target information right now!
package_wo_compiler="${package%%%*}"
( set -x;
( specfile=$(get_specfile_name "${package_wo_compiler}");
(${MY_SPACK_CMD} spec --fresh -y "${package_wo_compiler}" > "${specfile}")
( specfile=$(get_specfile_name "${package}");
(${MY_SPACK_CMD} spec --fresh -y "${package}" > "${specfile}")
) 2>"${tmp_err}" \
|| ( echo "CONCRETIZING FAILED" >> "${tmpfiles_concretize_err[0]}" );
) &
......@@ -148,8 +144,7 @@ find "${MY_SPACK_FOLDER}/var/spack/repos" -type f -print0 \
# now fetch everything that is needed in order
fetch_specfiles=()
for package in "${packages_to_fetch[@]}"; do
package_wo_compiler="${package%%%*}"
specfile="$(get_specfile_name "${package_wo_compiler}")"
specfile="$(get_specfile_name "${package}")"
if (( $(wc -l <"${specfile}") == 0 )); then
echo "${package} failed to concretize!" >&2
exit 1
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment