Python interface build cant find dolfinx target

Hello. I’ve built the dolfinx c++ core from source and I am trying to install the python interface with pip install .

haydel@Delta-XPS-15-9500:~/FEniCSx/dolfinx/cpp/build$ make install
[100%] Built target dolfinx
Install the project...
-- Install configuration: "RelWithDebInfo"
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/lib/libdolfinx.so.0.5.0
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/lib/libdolfinx.so.0.5
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/lib/libdolfinx.so
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/lib/cmake/dolfinx/DOLFINXTargets.cmake
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/lib/cmake/dolfinx/DOLFINXTargets-relwithdebinfo.cmake
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/defines.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/dolfin_common.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/dolfin_doc.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/IndexMap.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/log.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/loguru.hpp
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/sort.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/math.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/MPI.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/Scatterer.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/Table.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/Timer.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/TimeLogger.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/TimeLogManager.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/timing.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/utils.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/Constant.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/CoordinateElement.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/DirichletBC.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/DofMap.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/ElementDofLayout.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/Expression.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/FiniteElement.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/Form.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/Function.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/FunctionSpace.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/assembler.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/assemble_matrix_impl.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/assemble_scalar_impl.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/assemble_vector_impl.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/discreteoperators.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/dofmapbuilder.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/dolfin_fem.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/interpolate.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/petsc.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/sparsitybuild.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/fem/utils.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/geometry/BoundingBoxTree.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/geometry/gjk.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/geometry/dolfin_geometry.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/geometry/utils.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/graph/AdjacencyList.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/graph/dolfin_graph.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/graph/ordering.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/graph/partitioners.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/graph/partition.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/dolfin_io.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/ADIOS2Writers.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/cells.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/HDF5Interface.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/vtk_utils.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/VTKFile.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/XDMFFile.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/xdmf_function.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/xdmf_mesh.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/xdmf_meshtags.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/xdmf_read.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/io/xdmf_utils.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/la/dolfin_la.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/la/MatrixCSR.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/la/SparsityPattern.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/la/Vector.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/la/petsc.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/la/utils.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/la/slepc.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/mesh/dolfin_mesh.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/mesh/Mesh.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/mesh/Geometry.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/mesh/Topology.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/mesh/MeshTags.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/mesh/cell_types.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/mesh/generation.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/mesh/graphbuild.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/mesh/permutationcomputation.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/mesh/topologycomputation.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/mesh/utils.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/nls/dolfin_nls.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/nls/NewtonSolver.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/refinement/dolfin_refinement.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/refinement/plaza.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/refinement/refine.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/refinement/utils.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/include/dolfinx/common/version.h
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/lib/cmake/dolfinx/DOLFINXConfig.cmake
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/lib/cmake/dolfinx/DOLFINXConfigVersion.cmake
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/lib/pkgconfig/dolfinx.pc
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/lib/dolfinx/dolfinx.conf
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/hyperelasticity
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/hyperelasticity/main.cpp
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/hyperelasticity/CMakeLists.txt
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/hyperelasticity/hyperelasticity.py
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/interpolation-io
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/interpolation-io/main.cpp
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/interpolation-io/CMakeLists.txt
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/poisson_matrix_free
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/poisson_matrix_free/poisson.py
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/poisson_matrix_free/main.cpp
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/poisson_matrix_free/CMakeLists.txt
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/poisson
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/poisson/poisson.py
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/poisson/main.cpp
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/poisson/CMakeLists.txt
-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo/CMakeLists.txt
----------------------------------------------------------------------------
DOLFINx has now been installed in

    /home/haydel/FEniCSx/dolfinx/cpp/build

and demo programs have been installed in

    /home/haydel/FEniCSx/dolfinx/cpp/build/share/dolfinx/demo

Don't forget to update your environment variables. This can be done
easily using the helper file 'dolfinx.conf' which sets the appropriate
variables (for users of the Bash shell).

To update your environment variables, run the following command:

    source /home/haydel/FEniCSx/dolfinx/cpp/build/lib/dolfinx/dolfinx.conf

----------------------------------------------------------------------------

with the error message here:

haydel@Delta-XPS-15-9500:~/FEniCSx/dolfinx/python$ pip install .
Processing /home/haydel/FEniCSx/dolfinx/python
  Preparing metadata (setup.py) ... done
Requirement already satisfied: cffi in /home/haydel/FEniCSx/python/lib/python3.10/site-packages (from fenics-dolfinx==0.5.0) (1.15.1)
Requirement already satisfied: numpy>=1.21 in /home/haydel/FEniCSx/python/lib/python3.10/site-packages (from fenics-dolfinx==0.5.0) (1.23.2)
Requirement already satisfied: mpi4py in /home/haydel/FEniCSx/python/lib/python3.10/site-packages (from fenics-dolfinx==0.5.0) (3.1.3)
Requirement already satisfied: petsc4py in /home/haydel/FEniCSx/python/lib/python3.10/site-packages (from fenics-dolfinx==0.5.0) (3.17.4)
Requirement already satisfied: fenics-ffcx<0.6.0,>=0.5.0 in /home/haydel/FEniCSx/python/lib/python3.10/site-packages (from fenics-dolfinx==0.5.0) (0.5.0.post0)
Requirement already satisfied: fenics-ufl<2022.3.0,>=2022.2.0 in /home/haydel/FEniCSx/python/lib/python3.10/site-packages (from fenics-dolfinx==0.5.0) (2022.2.0)
Requirement already satisfied: setuptools in /home/haydel/FEniCSx/python/lib/python3.10/site-packages (from fenics-ffcx<0.6.0,>=0.5.0->fenics-dolfinx==0.5.0) (63.2.0)
Requirement already satisfied: fenics-basix<0.6.0,>=0.5.0 in /home/haydel/FEniCSx/python/lib/python3.10/site-packages (from fenics-ffcx<0.6.0,>=0.5.0->fenics-dolfinx==0.5.0) (0.5.0)
Requirement already satisfied: pycparser in /home/haydel/FEniCSx/python/lib/python3.10/site-packages (from cffi->fenics-dolfinx==0.5.0) (2.21)
Using legacy 'setup.py install' for fenics-dolfinx, since package 'wheel' is not installed.
Installing collected packages: fenics-dolfinx
  Running setup.py install for fenics-dolfinx ... error
  error: subprocess-exited-with-error
  
  × Running setup.py install for fenics-dolfinx did not run successfully.
  │ exit code: 1
  ╰─> [102 lines of output]
      /home/haydel/FEniCSx/python/lib/python3.10/site-packages/setuptools/installer.py:27: SetuptoolsDeprecationWarning: setuptools.installer is deprecated. Requirements should be satisfied by a PEP 517 installer.
        warnings.warn(
      WARNING: The wheel package is not available.
      running install
      /home/haydel/FEniCSx/python/lib/python3.10/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
        warnings.warn(
      running build
      running build_py
      running build_ext
      -- Found Python3: /home/haydel/FEniCSx/python/bin/python3.10 (found version "3.10.6") found components: Interpreter Development
      -- Found pybind11: /home/haydel/FEniCSx/dolfinx/python/.eggs/pybind11-2.10.0-py3.10.egg/pybind11/include (found version "2.10.0")
      -- Adding /home/haydel/FEniCSx/python/lib/python3.10/site-packages/basix to Basix search hints
      -- Found Boost 1.71.0 at /usr/lib/x86_64-linux-gnu/cmake/Boost-1.71.0
      --   Requested configuration: QUIET REQUIRED COMPONENTS timer;filesystem
      -- Found boost_headers 1.71.0 at /usr/lib/x86_64-linux-gnu/cmake/boost_headers-1.71.0
      -- Found boost_timer 1.71.0 at /usr/lib/x86_64-linux-gnu/cmake/boost_timer-1.71.0
      --   [x] libboost_timer.so.1.71.0
      --   [ ] libboost_timer.a
      -- Adding boost_timer dependencies: chrono;headers
      -- Found boost_chrono 1.71.0 at /usr/lib/x86_64-linux-gnu/cmake/boost_chrono-1.71.0
      --   [x] libboost_chrono.so.1.71.0
      --   [ ] libboost_chrono.a
      -- Adding boost_chrono dependencies: headers
      -- Found boost_filesystem 1.71.0 at /usr/lib/x86_64-linux-gnu/cmake/boost_filesystem-1.71.0
      --   [x] libboost_filesystem.so.1.71.0
      --   [ ] libboost_filesystem.a
      -- Adding boost_filesystem dependencies: headers
      -- Found Python3: /home/haydel/FEniCSx/python/bin/python3.10 (found version "3.10.6") found components: Interpreter
      -- Adding /home/haydel/FEniCSx/python/lib/python3.10/site-packages/basix to Basix search hints
      -- HDF5: Using hdf5 compiler wrapper to determine C configuration
      -- HDF5_DIR: HDF5_DIR-NOTFOUND
      -- HDF5_DEFINITIONS:
      -- HDF5_INCLUDE_DIRS: /usr/include/hdf5/openmpi
      -- HDF5_LIBRARIES: /usr/lib/x86_64-linux-gnu/hdf5/openmpi/libhdf5.so;/usr/lib/x86_64-linux-gnu/libsz.so;/usr/lib/x86_64-linux-gnu/libz.so;/usr/lib/x86_64-linux-gnu/libdl.so;/usr/lib/x86_64-linux-gnu/libm.so
      -- HDF5_HL_LIBRARIES:
      -- HDF5_C_DEFINITIONS:
      -- HDF5_C_INCLUDE_DIR:
      -- HDF5_C_INCLUDE_DIRS: /usr/include/hdf5/openmpi
      -- HDF5_C_LIBRARY:
      -- HDF5_C_LIBRARIES: /usr/lib/x86_64-linux-gnu/hdf5/openmpi/libhdf5.so;/usr/lib/x86_64-linux-gnu/libsz.so;/usr/lib/x86_64-linux-gnu/libz.so;/usr/lib/x86_64-linux-gnu/libdl.so;/usr/lib/x86_64-linux-gnu/libm.so
      -- HDF5_C_HL_LIBRARY:
      -- HDF5_C_HL_LIBRARIES:
      CMake Error at /home/haydel/FEniCSx/dolfinx/cpp/build/dolfinx/DOLFINXConfig.cmake:101 (include):
        include could not find load file:
      
          /home/haydel/FEniCSx/dolfinx/cpp/build/dolfinx/DOLFINXTargets.cmake
      Call Stack (most recent call first):
        CMakeLists.txt:35 (find_package)
      
      
      CMake Error at CMakeLists.txt:39 (get_target_property):
        get_target_property() called with non-existent target "dolfinx".

The cmake target file is built but not where the findpackage is looking:

-- Up-to-date: /home/haydel/FEniCSx/dolfinx/cpp/build/lib/cmake/dolfinx/DOLFINXTargets.cmake

Is there an easy fix for this? seems like I just need to point the setup.py to the correct directory, but I am not quite sure the best way to go about this without editing the file.

my environment vars are :

haydel@Delta-XPS-15-9500:~/FEniCSx/dolfinx/cpp/build$ echo $LD_LIBRARY_PATH
/home/haydel/FEniCSx/dolfinx/cpp/build/lib:/home/haydel/FEniCSx/dolfinx/cpp/build/lib:/home/haydel/FEniCSx/dolfinx/cpp/build/lib:/home/haydel/FEniCSx/dolfinx/cpp/build/lib:
haydel@Delta-XPS-15-9500:~/FEniCSx/dolfinx/cpp/build$ echo $PATH
/home/haydel/FEniCSx/dolfinx/cpp/build/bin:/home/haydel/FEniCSx/dolfinx/cpp/build/bin:/home/haydel/FEniCSx/dolfinx/cpp/build/bin:/home/haydel/FEniCSx/dolfinx/cpp/build/bin:/home/haydel/FEniCSx/python/bin:{/home/haydel/glvis-4.2:/usr/local/krb5/bin:/usr/local/ossh/bin:/home/haydel/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin}
haydel@Delta-XPS-15-9500:~/FEniCSx/dolfinx/cpp/build$ echo $PKG_CONFIG_PATH
/home/haydel/FEniCSx/dolfinx/cpp/build/lib/pkgconfig:/home/haydel/FEniCSx/dolfinx/cpp/build/lib/pkgconfig:/home/haydel/FEniCSx/dolfinx/cpp/build/lib/pkgconfig:/home/haydel/FEniCSx/dolfinx/cpp/build/lib/pkgconfig:

I know that I can use the spack package manager or docker image, but I would like to get this working if possible.

There is a DOLFINXConfig.cmake inside /home/haydel/FEniCSx/dolfinx/cpp/build/lib/cmake/dolfinx/
should I be using that one instead?

the dolfinx/cmake_install.cmake is putting those files here "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/cmake/dolfinx/DOLFINXTargets.cmake"
yet the config.cmake tries to include them from here:
dolfinx/DOLFINXConfig.cmake: include("${CMAKE_CURRENT_LIST_DIR}/DOLFINXTargets.cmake")

haydel@Delta-XPS-15-9500:~/FEniCSx/dolfinx/cpp/build$ grep -r DOLFINXTargets.cmake
install_manifest.txt:/home/haydel/FEniCSx/dolfinx/cpp/build/lib/cmake/dolfinx/DOLFINXTargets.cmake
lib/cmake/dolfinx/DOLFINXConfig.cmake:  include("${CMAKE_CURRENT_LIST_DIR}/DOLFINXTargets.cmake")
dolfinx/cmake_install.cmake:  if(EXISTS "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/cmake/dolfinx/DOLFINXTargets.cmake")
dolfinx/cmake_install.cmake:         "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/cmake/dolfinx/DOLFINXTargets.cmake"
dolfinx/cmake_install.cmake:         "/home/haydel/FEniCSx/dolfinx/cpp/build/dolfinx/CMakeFiles/Export/lib/cmake/dolfinx/DOLFINXTargets.cmake")
dolfinx/cmake_install.cmake:        message(STATUS "Old export file \"$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib/cmake/dolfinx/DOLFINXTargets.cmake\" will be replaced.  Removing files [${OLD_CONFIG_FILES}].")
dolfinx/cmake_install.cmake:  file(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/lib/cmake/dolfinx" TYPE FILE FILES "/home/haydel/FEniCSx/dolfinx/cpp/build/dolfinx/CMakeFiles/Export/lib/cmake/dolfinx/DOLFINXTargets.cmake")
dolfinx/DOLFINXConfig.cmake:  include("${CMAKE_CURRENT_LIST_DIR}/DOLFINXTargets.cmake")

I went ahead and changed the line include("${CMAKE_CURRENT_LIST_DIR}/DOLFINXTargets.cmake")
to point to this one instead /home/haydel/FEniCSx/dolfinx/cpp/build/lib/cmake/dolfinx/DOLFINXTargets.cmake/DOLFINXTargets.cmake and the build was able to complete.

But I unable to get a working finished product.
with errors like:

Python 3.10.6 (main, Aug 27 2022, 20:26:02) [GCC 10.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import dolfinx
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/haydel/FEniCSx/dolfinx/python/dolfinx/__init__.py", line 29, in <module>
    from dolfinx import common
  File "/home/haydel/FEniCSx/dolfinx/python/dolfinx/common.py", line 10, in <module>
    from dolfinx import cpp as _cpp
ImportError: cannot import name 'cpp' from partially initialized module 'dolfinx' (most likely due to a circular import) (/home/haydel/FEniCSx/dolfinx/python/dolfinx/__init__.py)
>>> quit()

In all honesty, I haven’t read the whole text, but PKGBUILD recipes are kind of a clear way on compilation instructions. If you want, you can check:
https://aur.archlinux.org/packages/fenics-basix-git
https://aur.archlinux.org/packages/dolfinx

Note that every line with a depends relates to another package which will be needed for your installation, and the names are definitely not consistent across distributions (flavours of Linux)

depends=(boost xsimd python-fenics-ffcx hdf5-openmpi petsc parmetis pugixml)

Another disclaimer: I am a new user :slight_smile: . Good luck.