From 3d77ecd92e0ccc950daf30468ec2ef591668d8eb Mon Sep 17 00:00:00 2001 From: Massimiliano Culpo Date: Mon, 21 Oct 2019 20:20:05 +0200 Subject: Bootstrap environment modules optimizing for generic architectures (#13105) fixes #13073 Since #3206 was merged bootstrapping environment-modules was using the architecture of the current host or the best match supported by the default compiler. The former case is an issue since shell integration was looking for a spec targeted at the host microarchitecture. 1. Bootstrap an env modules targeted at generic architectures 2. Look for generic targets in shell integration scripts 3. Add a new entry in Travis to test shell integration --- share/spack/qa/run-bootstrap-tests | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100755 share/spack/qa/run-bootstrap-tests (limited to 'share') diff --git a/share/spack/qa/run-bootstrap-tests b/share/spack/qa/run-bootstrap-tests new file mode 100755 index 0000000000..346122c529 --- /dev/null +++ b/share/spack/qa/run-bootstrap-tests @@ -0,0 +1,37 @@ +#!/bin/bash -e +# +# Copyright 2013-2019 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) + +# +# Description: +# Checks that Spack shell integration with modules works correctly. +# +# Usage: +# run-bootstrap-tests +# +. "$(dirname $0)/setup.sh" +check_dependencies ${coverage} git hg svn + +# Fetch the sources in a mirror, and add it to Spack +mkdir -p ~/.mirror +bin/spack mirror add travis ~/.mirror +bin/spack mirror create -D -d ~/.mirror environment-modules~X + + +# Move to root directory of Spack +# Allows script to be run from anywhere +cd "$SPACK_ROOT" + +# Print compiler information +spack config get compilers + +# Run some build smoke tests, potentially with code coverage +${coverage_run} bin/spack bootstrap + +# Check module integration +. "share/spack/setup-env.sh" +module av || exit 1 +spack load tcl || exit 1 -- cgit v1.2.3-60-g2f50