Skip to content

ci: add spack test + spack fixes#3156

Merged
minitu merged 33 commits intomasterfrom
ci-spack
Nov 23, 2020
Merged

ci: add spack test + spack fixes#3156
minitu merged 33 commits intomasterfrom
ci-spack

Conversation

@matthiasdiener
Copy link
Copy Markdown
Contributor

No description provided.

@matthiasdiener matthiasdiener self-assigned this Nov 15, 2020
@evan-charmworks
Copy link
Copy Markdown
Contributor

evan-charmworks commented Nov 16, 2020

The Linux build got much further but failed with this near the very end:

2020-11-16T21:01:37.3810795Z ==> Error: OSError: Cannot call rmtree on a symbolic link
2020-11-16T21:01:37.3811081Z 
2020-11-16T21:01:37.3811692Z /home/runner/work/charm/spack/var/spack/repos/builtin/packages/charmpp/package.py:301, in install:
2020-11-16T21:01:37.3812240Z         298                        os.rename(tmppath, filepath)
2020-11-16T21:01:37.3812591Z         299                    except (IOError, OSError):
2020-11-16T21:01:37.3812874Z         300                        pass
2020-11-16T21:01:37.3813206Z   >>    301        shutil.rmtree(join_path(builddir, "tmp"))
2020-11-16T21:01:37.3813514Z         302
2020-11-16T21:01:37.3814184Z         303        if self.spec.satisfies('@6.9.99'):
2020-11-16T21:01:37.3814799Z         304            # A broken 'doc' link in the prefix can break the build.
2020-11-16T21:01:37.3815244Z 
2020-11-16T21:01:37.3815501Z See build log for details:
2020-11-16T21:01:37.3817008Z   /tmp/runner/spack-stage/spack-stage-charmpp-develop-mcvl5dowlcd7qsrwamploktdzaltsjhd/spack-build-out.txt
2020-11-16T21:01:37.3819175Z 

Spack is probably expecting builddir/tmp to be a folder and not a symlink to builddir/include. This expectation may need to be fixed upstream.

        # 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
        shutil.rmtree(join_path(builddir, "tmp"))

@matthiasdiener matthiasdiener marked this pull request as ready for review November 22, 2020 15:46
@matthiasdiener matthiasdiener added the CI Continuous Integration label Nov 22, 2020
@matthiasdiener matthiasdiener changed the title ci: add spack test ci: add spack test + space fixes Nov 23, 2020
@matthiasdiener matthiasdiener changed the title ci: add spack test + space fixes ci: add spack test + spack fixes Nov 23, 2020
@minitu minitu merged commit 465c54e into master Nov 23, 2020
@minitu minitu deleted the ci-spack branch November 23, 2020 02:58
stwhite91 pushed a commit that referenced this pull request May 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CI Continuous Integration

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants