I've noticed some unexpected behavior if an environment (or rather its view) contains two packages that have file conflicts, but do not conflict themselves. More specifically, metis and scotch^+metis both provide include/metis.h but do not conflict otherwise - it's perfectly possible to add both to an environment and install it, without Spack complaining at all.
However, the files are not directly compatible and while METIS' metis.h should be useable with scotchmetis (that's the recommended way by Scotch), the converse is not true and SCOTCH's metis.h does not contain all functions METIS offers, rendering METIS impaired.
Additionally, if you remove scotch from the environment afterwards, the conflicting files will be deleted and any install command afterwards will error like this:
===> Error: /mypathtospack/var/spack/environments/myenv/.spack-env/include/metis.h is not a link tree!
This seems to be a result of spack assuming that these files should exist if metis were installed properly. The situation is identical between parmetis and spack with their respective overlap.
Repro:
spack env create myenv
spack env activate myenv
spack add metis parmetis scotch
spack install
I've noticed some unexpected behavior if an environment (or rather its view) contains two packages that have file conflicts, but do not conflict themselves. More specifically,
metisandscotch^+metisboth provideinclude/metis.hbut do not conflict otherwise - it's perfectly possible to add both to an environment and install it, without Spack complaining at all.However, the files are not directly compatible and while METIS'
metis.hshould be useable withscotchmetis(that's the recommended way by Scotch), the converse is not true and SCOTCH'smetis.hdoes not contain all functions METIS offers, rendering METIS impaired.Additionally, if you remove
scotchfrom the environment afterwards, the conflicting files will be deleted and any install command afterwards will error like this:This seems to be a result of spack assuming that these files should exist if
metiswere installed properly. The situation is identical betweenparmetisandspackwith their respective overlap.Repro: