Skip to content

Runtime dependency constraints are not respected for external packages #29298

@kwryankrattiger

Description

@kwryankrattiger

Steps to reproduce

Install external rocm stack version x.y.z and u.v.w. Configure them in /etc/spack/packages.yaml

For me, u.v.w is 5.0.0 and x.y.z is 4.3.1, but this is an issue in general.

packages:
  hip:
    buildable: false
    version: [u.v.w, x.y.z]
    externals:
      - spec: [email protected]
        prefix: /path/to/hip/u.v.w
      - spec: [email protected]
        prefix: /path/to/hip/x.y.z
  # additional externals for llvm-amdgpu, hsa-rocr-dev, rocm-cmake, etc.

Error message

==> [2022-03-02-17:42:28.796966] Imported spec from built-in commands
==> [2022-03-02-17:42:28.797789] Imported spec from built-in commands
==> [2022-03-02-17:42:28.798937] Reading config file /home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults/config.yaml
==> [2022-03-02-17:42:28.814173] Reading config file /etc/spack/config.yaml
==> [2022-03-02-17:42:28.814926] Reading config file /home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults/bootstrap.yaml
==> [2022-03-02-17:42:28.840365] Reading config file /home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults/config.yaml
==> [2022-03-02-17:42:28.854365] Reading config file /etc/spack/config.yaml
==> [2022-03-02-17:42:28.855054] DATABASE LOCK TIMEOUT: 3s
==> [2022-03-02-17:42:28.855080] PACKAGE LOCK TIMEOUT: No timeout
==> [2022-03-02-17:42:28.855330] Reading config file /home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults/bootstrap.yaml
==> [2022-03-02-17:42:28.860829] DATABASE LOCK TIMEOUT: 3s
==> [2022-03-02-17:42:28.860855] PACKAGE LOCK TIMEOUT: No timeout
==> [2022-03-02-17:42:28.860890] [BOOTSTRAP CONFIG SCOPE] name=_builtin
==> [2022-03-02-17:42:28.861111] [BOOTSTRAP CONFIG SCOPE] name=defaults, path=/home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults
==> [2022-03-02-17:42:28.861132] [BOOTSTRAP CONFIG SCOPE] name=defaults/linux, path=/home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults/linux
==> [2022-03-02-17:42:28.861149] [BOOTSTRAP CONFIG SCOPE] name=bootstrap, path=/home/local/KHQ/ryan.krattiger/.spack/bootstrap/config
==> [2022-03-02-17:42:28.861162] [BOOTSTRAP CONFIG SCOPE] name=bootstrap/linux, path=/home/local/KHQ/ryan.krattiger/.spack/bootstrap/config/linux
==> [2022-03-02-17:42:28.861366] Reading config file /home/local/KHQ/ryan.krattiger/.spack/bootstrap/config/linux/compilers.yaml
==> [2022-03-02-17:42:28.877513] [BOOTSTRAP ROOT SPEC] clingo-bootstrap@spack+python %gcc target=x86_64
==> [2022-03-02-17:42:28.877543] [BOOTSTRAP MODULE clingo] Try importing from Python
==> [2022-03-02-17:42:28.877676] Reading config file /home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults/bootstrap.yaml
==> [2022-03-02-17:42:28.980042] Reading config file /home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults/config.yaml
==> [2022-03-02-17:42:29.025308] [BOOTSTRAP MODULE clingo] The installed spec "clingo-bootstrap@spack+python %gcc target=x86_64 ^[email protected] /kt74l7kjzrlp3cgtj2576o33mhsrgyrw" provides the "clingo" Python module
==> [2022-03-02-17:42:29.025534] Reading config file /home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults/concretizer.yaml
==> [2022-03-02-17:42:29.027116] Reading config file /home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults/repos.yaml
==> [2022-03-02-17:42:30.189950] Reading config file /etc/spack/compilers.yaml
==> [2022-03-02-17:42:30.217469] Reading config file /home/local/KHQ/ryan.krattiger/.spack/compilers.yaml
==> [2022-03-02-17:42:30.220488] Reading config file /home/local/KHQ/ryan.krattiger/.spack/linux/compilers.yaml
==> [2022-03-02-17:42:30.226486] Reading config file /home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults/config.yaml
==> [2022-03-02-17:42:30.240254] Reading config file /etc/spack/config.yaml
==> [2022-03-02-17:42:30.241026] Reading config file /home/local/KHQ/ryan.krattiger/repos/spack/etc/spack/defaults/packages.yaml
==> [2022-03-02-17:42:30.262316] Reading config file /etc/spack/packages.yaml
==> [2022-03-02-17:42:30.462621] Reading config file /home/local/KHQ/ryan.krattiger/.spack/packages.yaml
==> [2022-03-02-17:42:38.117210] build(hip)
==> [2022-03-02-17:42:38.117296] build(vtk-m)
==> [2022-03-02-17:42:38.117313] build(cmake)
==> [2022-03-02-17:42:38.117326] build(rocm-cmake)
==> [2022-03-02-17:42:38.117338] build(llvm-amdgpu)
==> [2022-03-02-17:42:38.117351] build(hsa-rocr-dev)
==> [2022-03-02-17:42:38.117363] build(kokkos)
==> [2022-03-02-17:42:38.117374] build(perl)
==> [2022-03-02-17:42:38.117390] build(ncurses)
==> [2022-03-02-17:42:38.117401] build(zlib)
==> [2022-03-02-17:42:38.117412] build(bzip2)
==> [2022-03-02-17:42:38.117424] build(openssl)
==> [2022-03-02-17:42:38.117435] build(pkgconf)
==> [2022-03-02-17:42:38.117446] build(diffutils)
==> [2022-03-02-17:42:38.117457] build(berkeley-db)
==> [2022-03-02-17:42:38.117468] build(gdbm)
==> [2022-03-02-17:42:38.117481] build(libiconv)
==> [2022-03-02-17:42:38.117492] build(readline)
==> [2022-03-02-17:42:38.122166] Ordered hashes [berkeley-db]: berkeley-db/84/b231fcc4d5cff05e5c3a4814f6a5af0e9a966428dc2176540d2c05aff41de522
==> [2022-03-02-17:42:38.122303] Ordered hashes [hip]: hip/19/2a4190477b7d9206b9cd8d70770ba0bc007273cbe54772efb12f9ca2e37c0392, hip/24/e276c4acf3d37712b6bea306fea34f539d3c4f743471e9da208b5eb17b16ae67, hip/32/99190b4616edb362d48f9b265c3018a3c6339481b0729d9fe46185fca25bc54b
==> [2022-03-02-17:42:38.122368] Ordered hashes [hsa-rocr-dev]: hsa-rocr-dev/495/71e6851d9be8113bfb8d71b66a3171e0d0401bae5e6f161c9e7fe32558261a46
==> [2022-03-02-17:42:38.122440] Ordered hashes [llvm-amdgpu]: llvm-amdgpu/35/d999f3b235e655ee07f6dd2590302082feaa06d32c5c6b53aae9c5cf1e45b644
Input spec
--------------------------------
[email protected]+rocm amdgpu_target=gfx900
    ^[email protected]

Concretized
--------------------------------
[email protected]%[email protected]~64bitids+ascent_types~cuda+doubleprecision~ipo+kokkos~logging~mpi+openmp+rendering+rocm~shared~tbb~testlib~virtuals amdgpu_target=gfx900 build_type=Release arch=linux-ubuntu20.04-zen2
    ^[email protected]%[email protected]~doc+ncurses+openssl+ownlibs~qt build_type=Release arch=linux-ubuntu20.04-zen2
        ^[email protected]%[email protected]~symlinks+termlib abi=none arch=linux-ubuntu20.04-zen2
            ^[email protected]%[email protected] arch=linux-ubuntu20.04-zen2
        ^[email protected]%[email protected]~docs certs=system arch=linux-ubuntu20.04-zen2
            ^[email protected]%[email protected]+cpanm+shared+threads arch=linux-ubuntu20.04-zen2
                ^[email protected]%[email protected]+cxx~docs+stl patches=b231fcc arch=linux-ubuntu20.04-zen2
                ^[email protected]%[email protected]~debug~pic+shared arch=linux-ubuntu20.04-zen2
                    ^[email protected]%[email protected] arch=linux-ubuntu20.04-zen2
                        ^[email protected]%[email protected] libs=shared,static arch=linux-ubuntu20.04-zen2
                ^[email protected]%[email protected] arch=linux-ubuntu20.04-zen2
                    ^[email protected]%[email protected] arch=linux-ubuntu20.04-zen2
                ^[email protected]%[email protected]+optimize+pic+shared arch=linux-ubuntu20.04-zen2
    ^[email protected]%[email protected]~ipo build_type=Release patches=2a41904,99190b4,e276c4a arch=linux-ubuntu20.04-zen2
    ^[email protected]%[email protected]+image~ipo+shared build_type=Release patches=71e6851 arch=linux-ubuntu20.04-zen2
    ^[email protected]%[email protected]~aggressive_vectorization~compiler_warnings~cuda~cuda_constexpr~cuda_lambda~cuda_ldg_intrinsic~cuda_relocatable_device_code~cuda_uvm~debug~debug_bounds_check~debug_dualview_modify_check~deprecated_code~examples~explicit_instantiation~hpx~hpx_async_dispatch~hwloc~ipo~memkind~numactl~openmp~pic+profiling~profiling_load_print~pthread~qthread+rocm+serial+shared~sycl~tests~tuning~wrapper amdgpu_target=gfx900 build_type=RelWithDebInfo std=14 arch=linux-ubuntu20.04-zen2
        ^[email protected]%[email protected]~ipo~link_llvm_dylib~llvm_dylib+openmp+rocm-device-libs build_type=Release patches=d999f3b arch=linux-ubuntu20.04-zen2
    ^[email protected]%[email protected]~ipo+ldconfig build_type=Release arch=linux-ubuntu20.04-zen2

Note: hip is 4.3.1, but the other ROCm stack dependencies are 5.0.0.

These are not just build deps, the are also link and run deps, so having incompatible versions is not allowed. In all of the rocm packages, they explicitly depend on the same version.

Information on your system

  • Spack: 0.17.1-1276-a14a521727
  • Python: 3.8.10
  • Platform: linux-ubuntu20.04-zen2
  • Concretizer: clingo

@chuckatkins @kwryankrattiger

General information

  • I have run spack debug report and reported the version of Spack/Python/Platform
  • I have searched the issues of this repo and believe this is not a duplicate
  • I have run the failing commands in debug mode and reported the output

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Todo

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions