Error using spack - (ver0.8dev)

Hello,

I get an installation error when I try building the main branch using spack. it seems that the python wheel is using the wrong cmake build the py-fenicsx-dolfinx.
all the other packages required in the concretisation have been installed correctly.

Here is the output from the system.

==> [2024-04-09-10:52:58.220527] '********/spack/opt/spack/linux-centos7-broadwell/gcc-11.2.0/python-3.11.7-w2kpjwjirxnfznxvr7zbrafidsdvdppw/bin/python3.11' '-m' 'pip' '-vvv' '--no-input' '--no-cache-dir' '--disable-pip-version-check' 'install' '--no-deps' '--ignore-installed' '--no-build-isolation' '--no-warn-script-location' '--no-index' '--prefix=********/spack/opt/spack/linux-centos7-broadwell/gcc-11.2.0/py-fenics-dolfinx-main-mfrsd7g6xwccaiclzjr7ogkt42n5fd3r' '.'
Using pip 23.1.2 from ********/spack/opt/spack/linux-centos7-broadwell/gcc-11.2.0/py-pip-23.1.2-upiadzekaeikeiet6llgqotzmiycavh4/lib/python3.11/site-packages/pip (python 3.11)
Non-user install due to --prefix or --target option
Ignoring indexes: https://pypi.org/simple
Created temporary directory: /tmp/pip-build-tracker-hiectx17
Initialized build tracking at /tmp/pip-build-tracker-hiectx17
Created build tracker: /tmp/pip-build-tracker-hiectx17
Entered build tracker: /tmp/pip-build-tracker-hiectx17
Created temporary directory: /tmp/pip-install-nhytr9rw
Created temporary directory: /tmp/pip-ephem-wheel-cache-lk55kbfc
Processing ********/spack/tmp/spack-stage-py-fenics-dolfinx-main-mfrsd7g6xwccaiclzjr7ogkt42n5fd3r/spack-src/python
  Added file://********/spack/tmp/spack-stage-py-fenics-dolfinx-main-mfrsd7g6xwccaiclzjr7ogkt42n5fd3r/spack-src/python to build tracker '/tmp/pip-build-tracker-hiectx17'
  Created temporary directory: /tmp/pip-modern-metadata-xgj28tp_
  Preparing metadata (pyproject.toml): started
  Running command Preparing metadata (pyproject.toml)
  *** scikit-build-core 0.6.1 using CMake 3.17.5 (metadata_wheel)
  Preparing metadata (pyproject.toml): finished with status 'done'
  Source in ********/spack/tmp/spack-stage-py-fenics-dolfinx-main-mfrsd7g6xwccaiclzjr7ogkt42n5fd3r/spack-src/python has version 0.8.0.dev0, which satisfies requirement fenics-dolfinx==0.8.0.dev0 from file://********/spack/tmp/spack-stage-py-fenics-dolfinx-main-mfrsd7g6xwccaiclzjr7ogkt42n5fd3r/spack-src/python
  Removed fenics-dolfinx==0.8.0.dev0 from file://********/spack/tmp/spack-stage-py-fenics-dolfinx-main-mfrsd7g6xwccaiclzjr7ogkt42n5fd3r/spack-src/python from build tracker '/tmp/pip-build-tracker-hiectx17'
Created temporary directory: /tmp/pip-unpack-j16ayppm
Building wheels for collected packages: fenics-dolfinx
  Created temporary directory: /tmp/pip-wheel-kftt_hkl
  Destination directory: /tmp/pip-wheel-kftt_hkl
  Building wheel for fenics-dolfinx (pyproject.toml): started
  Running command Building wheel for fenics-dolfinx (pyproject.toml)
  *** scikit-build-core 0.6.1 using CMake 3.17.5 (wheel)
  *** Configuring CMake...
  loading initial cache file /tmp/tmppz4hsd86/build/CMakeInit.txt
  CMake Error at CMakeLists.txt:1 (cmake_minimum_required):
    CMake 3.18 or higher is required.  You are running version 3.17.5


  -- Configuring incomplete, errors occurred!

  *** CMake configuration failed
  error: subprocess-exited-with-error
  
  × Building wheel for fenics-dolfinx (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> See above for output.
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
  full command: ********/spack/opt/spack/linux-centos7-broadwell/gcc-11.2.0/python-3.11.7-w2kpjwjirxnfznxvr7zbrafidsdvdppw/bin/python3.11 ********/spack/opt/spack/linux-centos7-broadwell/gcc-11.2.0/py-pip-23.1.2-upiadzekaeikeiet6llgqotzmiycavh4/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py build_wheel /tmp/tmpkrlqwuax
  cwd: ********/spack/tmp/spack-stage-py-fenics-dolfinx-main-mfrsd7g6xwccaiclzjr7ogkt42n5fd3r/spack-src/python
  Building wheel for fenics-dolfinx (pyproject.toml): finished with status 'error'
  ERROR: Failed building wheel for fenics-dolfinx
Failed to build fenics-dolfinx
ERROR: Could not build wheels for fenics-dolfinx, which is required to install pyproject.toml-based projects
Exception information:
Traceback (most recent call last):
  File "********/spack/opt/spack/linux-centos7-broadwell/gcc-11.2.0/py-pip-23.1.2-upiadzekaeikeiet6llgqotzmiycavh4/lib/python3.11/site-packages/pip/_internal/cli/base_command.py", line 169, in exc_logging_wrapper
    status = run_func(*args)
             ^^^^^^^^^^^^^^^
  File "********/spack/opt/spack/linux-centos7-broadwell/gcc-11.2.0/py-pip-23.1.2-upiadzekaeikeiet6llgqotzmiycavh4/lib/python3.11/site-packages/pip/_internal/cli/req_command.py", line 248, in wrapper
    return func(self, options, args)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "********/spack/opt/spack/linux-centos7-broadwell/gcc-11.2.0/py-pip-23.1.2-upiadzekaeikeiet6llgqotzmiycavh4/lib/python3.11/site-packages/pip/_internal/commands/install.py", line 426, in run
    raise InstallationError(
pip._internal.exceptions.InstallationError: Could not build wheels for fenics-dolfinx, which is required to install pyproject.toml-based projects
Removed build tracker: '/tmp/pip-build-tracker-hiectx17'```

can anybody help?

Seems like it is using the wrong cmake.

You would have to provide how you set up your environment (the config file) or the actual commands you ran. It would also help if you added the output of spack concretize.

the system:
cmake ver 3.22
gcc ver11.2.0

this is the config:

spack:
  # add package specs to the `specs` list
  specs:
  - py-fenics-dolfinx@main%gcc@11.2.0 ^adios2 ^intel-mpi ^petsc cflags=-O3 fflags=-O3
    +hypre
  view: true
  concretizer:
    unify: true

and this is the concretize:

$ spack concretize -f
==> Concretized py-fenics-dolfinx@main%gcc@11.2.0 ^adios2 ^intel-mpi ^petsc cflags=-O3 fflags=-O3 +hypre
 -   mfrsd7g  py-fenics-dolfinx@main%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  sa4nwmy      ^cmake@3.27.9%gcc@11.2.0~doc+ncurses+ownlibs build_system=generic build_type=Release arch=linux-centos7-broadwell
[+]  tl2xzpu          ^curl@8.6.0%gcc@11.2.0~gssapi~ldap~libidn2~librtmp~libssh~libssh2+nghttp2 build_system=autotools libs=shared,static tls=openssl arch=linux-centos7-broadwell
[+]  7q3rftl              ^nghttp2@1.57.0%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  7vk7mhg          ^gmake@4.4.1%gcc@11.2.0~guile build_system=generic arch=linux-centos7-broadwell
[+]  a5qx4o4          ^ncurses@6.4%gcc@11.2.0~symlinks+termlib abi=none build_system=autotools patches=7a351bc arch=linux-centos7-broadwell
[+]  qquxeey          ^zlib-ng@2.1.6%gcc@11.2.0+compat+new_strategies+opt+pic+shared build_system=autotools arch=linux-centos7-broadwell
[+]  fdmmviy      ^fenics-basix@main%gcc@11.2.0~ipo build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  6sozkkc          ^openblas@0.3.26%gcc@11.2.0~bignuma~consistent_fpcsr+dynamic_dispatch+fortran~ilp64+locking+pic+shared build_system=makefile symbol_suffix=none threads=none arch=linux-centos7-broadwell
[+]  fx3pc5h              ^perl@5.38.0%gcc@11.2.0+cpanm+opcode+open+shared+threads build_system=generic patches=714e4d1 arch=linux-centos7-broadwell
[+]  4lwuwnm                  ^berkeley-db@18.1.40%gcc@11.2.0+cxx~docs+stl build_system=autotools patches=26090f4,b231fcc arch=linux-centos7-broadwell
[+]  yhoanrq      ^fenics-dolfinx@main%gcc@11.2.0+adios2~ipo~slepc build_system=cmake build_type=Release generator=make partitioners=parmetis arch=linux-centos7-broadwell
[+]  tjhaxoa          ^adios2@2.10.0%gcc@11.2.0~aws+blosc2+bzip2~cuda~dataspaces+fortran~hdf5~ipo~kokkos+libcatalyst~libpressio+mgard+mpi~pic+png~python~rocm+sst~sycl+sz+zfp build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  5o6kpqi              ^c-blosc2@2.11.1%gcc@11.2.0+avx2~ipo+lizard+lz4+snappy+zlib+zstd build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  uokrxnc                  ^lizard@1.0%gcc@11.2.0 build_system=makefile patches=4895619 arch=linux-centos7-broadwell
[+]  qgaldne                  ^lz4@1.9.4%gcc@11.2.0+pic build_system=makefile libs=shared,static arch=linux-centos7-broadwell
[+]  b2ytbtg                  ^snappy@1.1.10%gcc@11.2.0~ipo+pic+shared build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  c4qkhyi                  ^zstd@1.5.5%gcc@11.2.0+programs build_system=makefile compression=none libs=shared,static arch=linux-centos7-broadwell
[+]  n7slkzf              ^libcatalyst@2.0.0-rc4%gcc@11.2.0~conduit~fortran~ipo~mpi~python build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  hfpqfux              ^libfabric@1.20.1%gcc@11.2.0~debug~kdreg~uring build_system=autotools fabrics=sockets,tcp,udp arch=linux-centos7-broadwell
[+]  j5efic5              ^libpng@1.6.39%gcc@11.2.0~ipo~pic build_system=cmake build_type=Release generator=make libs=shared,static arch=linux-centos7-broadwell
[+]  ha47j7z              ^mgard@2023-12-09%gcc@11.2.0~cuda~ipo+openmp+serial~timing~unstructured build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  gvyy3se                  ^libarchive@3.7.1%gcc@11.2.0+iconv build_system=autotools compression=bz2lib,lz4,lzma,lzo2,zlib,zstd crypto=openssl libs=shared,static programs=none xar=libxml2 arch=linux-centos7-broadwell
[+]  gfhox3p                      ^lzo@2.10%gcc@11.2.0 build_system=autotools libs=shared,static arch=linux-centos7-broadwell
[+]  bpaetdw                  ^protobuf@3.25.3%gcc@11.2.0~ipo+shared build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  hvzgxpa                      ^abseil-cpp@20240116.1%gcc@11.2.0~ipo+shared build_system=cmake build_type=Release cxxstd=14 generator=make arch=linux-centos7-broadwell
[+]  jppjpcu                  ^sed@4.9%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  hvivpkx                  ^yaml-cpp@0.7.0%gcc@11.2.0~ipo+pic+shared~tests build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  ksgrgld              ^sz@2.1.12.5%gcc@11.2.0~fortran~hdf5~ipo~netcdf~pastri~python~random_access+shared~stats~time_compression build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  zxhyd2r              ^zfp@0.5.5%gcc@11.2.0~aligned~c~cuda~fasthash~fortran~ipo~openmp~profile~python+shared~strided~twoway+utilities bsws=64 build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  3fb3n4n          ^boost@1.84.0%gcc@11.2.0~atomic~chrono~clanglibcpp~container~context~contract~coroutine~date_time~debug~exception~fiber+filesystem~graph~graph_parallel~icu~iostreams~json~locale~log~math~mpi+multithreaded~nowide~numpy~pic+program_options~python~random~regex~serialization+shared~signals~singlethreaded~stacktrace~system~taggedlayout~test~thread+timer~type_erasure~versionedlayout~wave build_system=generic cxxstd=11 patches=a440f96 visibility=hidden arch=linux-centos7-broadwell
[+]  wkuxpy4          ^fenics-ufcx@main%gcc@11.2.0~ipo build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[e]  ksmaz5h          ^intel-mpi@2019.5.281%gcc@11.2.0~external-libfabric build_system=generic arch=linux-centos7-broadwell
[+]  ryqs5lh          ^parmetis@4.0.3%gcc@11.2.0~gdb~int64~ipo+shared build_system=cmake build_type=Release generator=make patches=4f89253,50ed208,704b84f arch=linux-centos7-broadwell
[+]  fo34zjw              ^metis@5.1.0%gcc@11.2.0~gdb~int64~ipo~real64+shared build_system=cmake build_type=Release generator=make patches=4991da9,93a7903,b1225da arch=linux-centos7-broadwell
[+]  m4g5pzh          ^petsc@3.21.0%gcc@11.2.0 cflags=-O3 fflags=-O3 ~X~batch~cgns~complex~cuda~debug+double~exodusii~fftw+fortran~giflib+hdf5~hpddm~hwloc+hypre~int64~jpeg~knl~kokkos~libpng~libyaml~memkind+metis~mkl-pardiso~mmg~moab~mpfr+mpi~mumps~openmp~p4est~parmmg~ptscotch~random123~rocm~saws~scalapack+shared~strumpack~suite-sparse+superlu-dist~sycl~tetgen~trilinos~valgrind~zoltan build_system=generic clanguage=C memalign=none arch=linux-centos7-broadwell
[+]  xb4sslv              ^diffutils@3.10%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  dounlkj              ^hypre@2.31.0%gcc@11.2.0~caliper~complex~cuda~debug+fortran~gptune~gpu-aware-mpi~int64~internal-superlu~magma~mixedint+mpi~openmp~rocm+shared~superlu-dist~sycl~umpire~unified-memory build_system=autotools arch=linux-centos7-broadwell
[+]  oyucldz              ^superlu-dist@8.2.1%gcc@11.2.0~cuda~int64~ipo~openmp+parmetis~rocm+shared build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  4lldxo6          ^pugixml@1.13%gcc@11.2.0~ipo+pic+shared build_system=cmake build_type=Release generator=make arch=linux-centos7-broadwell
[+]  lslwe4i      ^gcc-runtime@11.2.0%gcc@11.2.0 build_system=generic arch=linux-centos7-broadwell
[+]  seetgnr      ^hdf5@1.14.3%gcc@11.2.0~cxx~fortran~hl~ipo~java~map+mpi+shared~subfiling~szip~threadsafe+tools api=default build_system=cmake build_type=Release generator=make patches=82088c8 arch=linux-centos7-broadwell
[+]  7ilizv7      ^pkgconf@1.9.5%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  zy7xium      ^py-cffi@1.15.1%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  twn2sxh          ^libffi@3.4.6%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  yodsq4k          ^py-pycparser@2.21%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  ipkqhv6          ^py-setuptools@69.2.0%gcc@11.2.0 build_system=generic arch=linux-centos7-broadwell
[+]  uyejkix      ^py-fenics-basix@main%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  lhed4ut      ^py-fenics-ffcx@main%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  d7iievo      ^py-fenics-ufl@main%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  6gzwaec      ^py-mpi4py@3.1.5%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  3wjkmrx          ^py-cython@0.29.36%gcc@11.2.0 build_system=python_pip patches=c4369ad arch=linux-centos7-broadwell
[+]  4ftth7e      ^py-nanobind@1.8.0%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  ubdrbo7          ^ninja@1.11.1%gcc@11.2.0+re2c build_system=generic arch=linux-centos7-broadwell
[+]  7xhujgr              ^re2c@2.2%gcc@11.2.0 build_system=generic arch=linux-centos7-broadwell
[+]  zm5jq7c          ^py-scikit-build@0.17.6%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  mnwypvu              ^py-distro@1.8.0%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  2rb2law              ^py-hatch-fancy-pypi-readme@23.1.0%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  vruzvsg      ^py-numpy@1.26.4%gcc@11.2.0 build_system=python_pip patches=873745d arch=linux-centos7-broadwell
[+]  2kx5ilt          ^py-meson-python@0.15.0%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  y63k53w              ^meson@1.3.2%gcc@11.2.0 build_system=python_pip patches=0f0b1bd arch=linux-centos7-broadwell
[+]  nljnbgg      ^py-petsc4py@3.21.0%gcc@11.2.0+mpi build_system=python_pip arch=linux-centos7-broadwell
[+]  upiadze      ^py-pip@23.1.2%gcc@11.2.0 build_system=generic arch=linux-centos7-broadwell
[+]  d5n224h      ^py-scikit-build-core@0.6.1%gcc@11.2.0+pyproject build_system=python_pip arch=linux-centos7-broadwell
[+]  vlqohcs          ^py-hatch-vcs@0.3.0%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  2rjnuqj              ^py-setuptools-scm@7.1.0%gcc@11.2.0+toml build_system=python_pip arch=linux-centos7-broadwell
[+]  gmjwqdd                  ^git@2.42.0%gcc@11.2.0+man+nls+perl+subtree~svn~tcltk build_system=autotools arch=linux-centos7-broadwell
[+]  yqnsnt3                      ^autoconf@2.72%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  sohs6rc                      ^automake@1.16.5%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  7aabycz                      ^libidn2@2.3.4%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  7xzxum3                          ^libunistring@1.1%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  b6uzjuv                      ^libtool@2.4.7%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  2px2xbo                          ^findutils@4.9.0%gcc@11.2.0 build_system=autotools patches=440b954 arch=linux-centos7-broadwell
[+]  x76qaf5                      ^m4@1.4.19%gcc@11.2.0+sigsegv build_system=autotools patches=9dc5fbd,bfdffa7 arch=linux-centos7-broadwell
[+]  jhigjwp                          ^libsigsegv@2.14%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  3irgdca                      ^openssh@9.7p1%gcc@11.2.0+gssapi build_system=autotools arch=linux-centos7-broadwell
[+]  5h66knu                          ^krb5@1.20.1%gcc@11.2.0+shared build_system=autotools arch=linux-centos7-broadwell
[+]  246n5qd                              ^bison@3.8.2%gcc@11.2.0~color build_system=autotools arch=linux-centos7-broadwell
[+]  bqphf7f                          ^libedit@3.1-20230828%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  6mpcdeh                      ^pcre2@10.42%gcc@11.2.0~jit+multibyte build_system=autotools arch=linux-centos7-broadwell
[+]  jnrenmo                  ^py-tomli@2.0.1%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  rfhnh6x                  ^py-typing-extensions@4.8.0%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  uppxohw          ^py-hatchling@1.21.0%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  maafngi              ^py-editables@0.3%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  2a2a54y              ^py-pluggy@1.4.0%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  u77qoda              ^py-trove-classifiers@2023.8.7%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  hqhzerr                  ^py-calver@2022.6.26%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  o4syzkk          ^py-packaging@23.1%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  gpirj5u              ^py-flit-core@3.9.0%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  nwnu2im          ^py-pathspec@0.11.1%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  4a72sy5          ^py-pyproject-metadata@0.7.1%gcc@11.2.0 build_system=python_pip arch=linux-centos7-broadwell
[+]  yqy4ejb      ^py-wheel@0.41.2%gcc@11.2.0 build_system=generic arch=linux-centos7-broadwell
[+]  w2kpjwj      ^python@3.11.7%gcc@11.2.0+bz2+crypt+ctypes+dbm~debug+libxml2+lzma~nis~optimizations+pic+pyexpat+pythoncmd+readline+shared+sqlite3+ssl~tkinter+uuid+zlib build_system=generic patches=13fa8bf,b0615b2,ebdca64,f2fd060 arch=linux-centos7-broadwell
[+]  vsynphn          ^bzip2@1.0.8%gcc@11.2.0~debug~pic+shared build_system=generic arch=linux-centos7-broadwell
[+]  2kawzbi          ^expat@2.6.2%gcc@11.2.0+libbsd build_system=autotools arch=linux-centos7-broadwell
[+]  ybac6df              ^libbsd@0.12.1%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  iqyxufu                  ^libmd@1.0.4%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  bcuee6f          ^gdbm@1.23%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  dmlfylu          ^gettext@0.22.4%gcc@11.2.0+bzip2+curses+git~libunistring+libxml2+pic+shared+tar+xz build_system=autotools arch=linux-centos7-broadwell
[+]  yfrypv6              ^libiconv@1.17%gcc@11.2.0 build_system=autotools libs=shared,static arch=linux-centos7-broadwell
[+]  yqz2db5              ^libxml2@2.10.3%gcc@11.2.0+pic~python+shared build_system=autotools arch=linux-centos7-broadwell
[+]  c45x5fn              ^tar@1.34%gcc@11.2.0 build_system=autotools zip=pigz arch=linux-centos7-broadwell
[+]  ujo23v3                  ^pigz@2.8%gcc@11.2.0 build_system=makefile arch=linux-centos7-broadwell
[+]  5dfod3m          ^libxcrypt@4.4.35%gcc@11.2.0~obsolete_api build_system=autotools patches=4885da3 arch=linux-centos7-broadwell
[+]  ommy46c          ^openssl@3.2.1%gcc@11.2.0~docs+shared build_system=generic certs=mozilla arch=linux-centos7-broadwell
[+]  3axeg7t              ^ca-certificates-mozilla@2023-05-30%gcc@11.2.0 build_system=generic arch=linux-centos7-broadwell
[+]  rjr55r5          ^readline@8.2%gcc@11.2.0 build_system=autotools patches=bbf97f1 arch=linux-centos7-broadwell
[+]  a5gxfgv          ^sqlite@3.43.2%gcc@11.2.0+column_metadata+dynamic_extensions+fts~functions+rtree build_system=autotools arch=linux-centos7-broadwell
[+]  4nvmsgc          ^util-linux-uuid@2.38.1%gcc@11.2.0 build_system=autotools arch=linux-centos7-broadwell
[+]  kj2zaof          ^xz@5.4.6%gcc@11.2.0~pic build_system=autotools libs=shared,static arch=linux-centos7-broadwell

Strange that it picks up that cmake (3.17.5) as in the concretization it says that py-fenics-dolfinx uses cmake 3.27.9.

odd indeed. any idea how to force spack to use the right cmake?

Add CMake to the Spack environment:

spack add cmake@3.27
spack concretize -f

CMake is a build dependency for DOLFINx, but not a runtime dependency. Adding CMake to the environment will bring it into ‘user space’.

1 Like

unfortunately, it didn’t work. am I missing any intermediate step to bring cmake into the ‘user space’?

Did you run spack install after concretising the environment?

Spack documentation explains how to load a package Basic Usage — Spack 0.22.0.dev0 documentation

spack load cmake

sure, I run concretize and loaded cmake, but I still got the issue.

I tweaked the package to use the right installation RPATH as explained here Packaging Guide — Spack 0.22.0.dev0 documentation and it works now.