Error Installing ROOT-5.34.38

I am trying to install ROOT-5.34.38 on my MacBook Air 2022 with an M2 processor. Clang version is:

Apple clang version 14.0.0 (clang-1400.0.29.202)
Target: arm64-apple-darwin21.6.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin

I get this error I would appreciate someone could explain to me:

[  4%] Generating G__MetaUtils.cxx, G__MetaUtils.h
Error: cannot open file "AvailabilityMacros.h"  /Users/diiego/software/ROOT/ROOT_5.34.38/build/include/RConfig.h:384:
Warning: Error occurred during reading source files
Warning: Error occurred during dictionary source generation
!!!Removing G__MetaUtils.cxx G__MetaUtils.h !!!
Error: ../../bin/rootcint_tmp: error loading headers...
gmake[2]: *** [core/metautils/CMakeFiles/METAUTILS_DICTIONARY.dir/build.make:79: core/metautils/G__MetaUtils.cxx] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:4387: core/metautils/CMakeFiles/METAUTILS_DICTIONARY.dir/all] Error 2
gmake: *** [Makefile:156: all] Error 2

Generation gave a couple of warnings but I thought it went correctly:

CMake Deprecation Warning at CMakeLists.txt:2 (cmake_minimum_required):
  Compatibility with CMake < 2.8.12 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


-- The C compiler identification is AppleClang 14.0.0.14000029
-- The CXX compiler identification is AppleClang 14.0.0.14000029
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /Library/Developer/CommandLineTools/usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /Library/Developer/CommandLineTools/usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- The Fortran compiler identification is GNU 12.2.0
-- Checking whether Fortran compiler has -isysroot
-- Checking whether Fortran compiler has -isysroot - yes
-- Checking whether Fortran compiler supports OSX deployment target flag
-- Checking whether Fortran compiler supports OSX deployment target flag - yes
-- Detecting Fortran compiler ABI info
-- Detecting Fortran compiler ABI info - done
-- Check for working Fortran compiler: /opt/homebrew/bin/gfortran - skipped
-- Found Clang. Major version 14, minor version 0
-- CMAKE_BUILD_TYPE: RelWithDebInfo
-- Performing Test CXX_HAS_Wno-array-bounds
-- Performing Test CXX_HAS_Wno-array-bounds - Success
-- Performing Test CXX_HAS_Wno-strict-aliasing
-- Performing Test CXX_HAS_Wno-strict-aliasing - Success
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- Found a Mac OS X System 12.5
sysctl: unknown oid 'machdep.cpu.extfeatures'
-- Found a 32bit system
-- Found LLVM compiler collection
-- Performing Test CXX_HAS_Wno_deprecated_declarations
-- Performing Test CXX_HAS_Wno_deprecated_declarations - Success
-- ROOT Platform: macosx
-- ROOT Architecture: macosx
-- Build Type: RelWithDebInfo
-- Compiler Flags:  -m32 -pipe -W -Wall -Woverloaded-virtual -fsigned-char -fno-common -Qunused-arguments -pthread -Wno-deprecated-declarations -stdlib=libc++ -O2 -g -DNDEBUG
-- Looking for ZLib
-- Found ZLIB: /Library/Developer/CommandLineTools/SDKs/MacOSX13.1.sdk/usr/lib/libz.tbd (found version "1.2.11")
-- Looking for PCRE
-- PCRE not found. Switching on builtin_pcre option
-- Looking for LZMA
-- Found LZMA includes at /opt/homebrew/include
-- Found LZMA library at /Library/Developer/CommandLineTools/SDKs/MacOSX13.1.sdk/usr/lib/liblzma.tbd
-- Looking for LZ4
-- LZ4 not found. Switching on builtin_lz4 option
-- Building LZ4 version v1.7.5 included in ROOT itself
CMake Warning (dev) at /Applications/CMake.app/Contents/share/cmake-3.25/Modules/ExternalProject.cmake:3075 (message):
  The DOWNLOAD_EXTRACT_TIMESTAMP option was not given and policy CMP0135 is
  not set.  The policy's OLD behavior will be used.  When using a URL
  download, the timestamps of extracted files should preferably be that of
  the time of extraction, otherwise code that depends on the extracted
  contents might not be rebuilt if the URL changes.  The OLD behavior
  preserves the timestamps from the archive instead, but this is usually not
  what you want.  Update your project to the NEW behavior or specify the
  DOWNLOAD_EXTRACT_TIMESTAMP option with a value of true to avoid this
  robustness issue.
Call Stack (most recent call first):
  /Applications/CMake.app/Contents/share/cmake-3.25/Modules/ExternalProject.cmake:4185 (_ep_add_download_command)
  cmake/modules/SearchInstalledSoftware.cmake:163 (ExternalProject_Add)
  CMakeLists.txt:46 (include)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Found GIF: /opt/homebrew/lib/libgif.dylib (found version "5.2.1")
-- Found TIFF: /opt/homebrew/lib/libtiff.dylib (found version "4.4.0")
CMake Warning (dev) at /Applications/CMake.app/Contents/share/cmake-3.25/Modules/FindTIFF.cmake:131 (if):
  Policy CMP0054 is not set: Only interpret if() arguments as variables or
  keywords when unquoted.  Run "cmake --help-policy CMP0054" for policy
  details.  Use the cmake_policy command to set the policy and suppress this
  warning.

  Quoted variables like "CXX" will no longer be dereferenced when the policy
  is set to NEW.  Since the policy is not set the OLD behavior will be used.
Call Stack (most recent call first):
  cmake/modules/SearchInstalledSoftware.cmake:248 (find_Package)
  CMakeLists.txt:46 (include)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Found PNG: /opt/homebrew/lib/libpng.dylib (found version "1.6.39")
-- Found JPEG: /opt/homebrew/lib/libjpeg.dylib (found version "80")
-- Looking for GSL
-- FindGSL: gsl-config not found.
-- GSL not found. Set variable GSL_DIR to point to your GSL installation
--                Alternatively, you can also enable the option 'builtin_gsl' to build the GSL libraries internally'
--                For the time being switching OFF 'mathmore' option
-- Looking for Python
-- Found PythonInterp: /Library/Frameworks/Python.framework/Versions/3.11/bin/python3.11 (found version "3.11.1")
-- Found Python interpreter version 3.1
-- Found PythonLibs: /Library/Frameworks/Python.framework/Versions/3.11/lib/libpython3.11.dylib (found version "3.11.1")
-- Looking for GCCXML
-- Looking for OpenGL
-- Found OpenGL: /Library/Developer/CommandLineTools/SDKs/MacOSX13.1.sdk/System/Library/Frameworks/OpenGL.framework
-- Looking for Graphviz
CMake Warning (dev) at /Applications/CMake.app/Contents/share/cmake-3.25/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
  The package name passed to `find_package_handle_standard_args` (GRAPHVIZ)
  does not match the name of the calling package (Graphviz).  This can lead
  to problems in calling code that expects `find_package` result variables
  (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  cmake/modules/FindGraphviz.cmake:19 (find_package_handle_standard_args)
  cmake/modules/SearchInstalledSoftware.cmake:381 (find_package)
  CMakeLists.txt:46 (include)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Could NOT find GRAPHVIZ (missing: GRAPHVIZ_INCLUDE_DIR GRAPHVIZ_cdt_LIBRARY GRAPHVIZ_gvc_LIBRARY GRAPHVIZ_graph_LIBRARY GRAPHVIZ_pathplan_LIBRARY)
-- Graphviz not found. Switching off gviz option
-- Looking for Bonjour
-- Checking whether Bonjour/Avahi is supported
-- Looking for Kerberos 5
CMake Warning (dev) at /Applications/CMake.app/Contents/share/cmake-3.25/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
  The package name passed to `find_package_handle_standard_args` (KRB5) does
  not match the name of the calling package (Kerberos5).  This can lead to
  problems in calling code that expects `find_package` result variables
  (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  cmake/modules/FindKerberos5.cmake:36 (find_package_handle_standard_args)
  cmake/modules/SearchInstalledSoftware.cmake:428 (find_package)
  CMakeLists.txt:46 (include)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Found KRB5: /Library/Developer/CommandLineTools/SDKs/MacOSX13.1.sdk/usr/lib/libkrb5.tbd
-- Looking for LibXml2
-- Found LibXml2: /Library/Developer/CommandLineTools/SDKs/MacOSX13.1.sdk/usr/lib/libxml2.tbd (found version "2.9.13")
-- Looking for OpenSSL
-- Could NOT find OpenSSL, try to set the path to OpenSSL root folder in the system variable OPENSSL_ROOT_DIR (missing: OPENSSL_INCLUDE_DIR)
-- OpenSSL not found. Switching off ssl option
-- Looking for Castor
CMake Warning (dev) at /Applications/CMake.app/Contents/share/cmake-3.25/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
  The package name passed to `find_package_handle_standard_args` (CASTOR)
  does not match the name of the calling package (Castor).  This can lead to
  problems in calling code that expects `find_package` result variables
  (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  cmake/modules/FindCastor.cmake:43 (find_package_handle_standard_args)
  cmake/modules/SearchInstalledSoftware.cmake:501 (find_package)
  CMakeLists.txt:46 (include)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Could NOT find CASTOR (missing: CASTOR_shift_LIBRARY CASTOR_INCLUDE_DIR)
-- Castor not found. Switching off castor/rfio option
-- Looking for MySQL
CMake Warning (dev) at /Applications/CMake.app/Contents/share/cmake-3.25/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
  The package name passed to `find_package_handle_standard_args` (MYSQL) does
  not match the name of the calling package (MySQL).  This can lead to
  problems in calling code that expects `find_package` result variables
  (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  cmake/modules/FindMySQL.cmake:37 (find_package_handle_standard_args)
  cmake/modules/SearchInstalledSoftware.cmake:516 (find_package)
  CMakeLists.txt:46 (include)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Could NOT find MYSQL (missing: MYSQL_INCLUDE_DIR MYSQL_LIBRARIES)
-- MySQL not found. Switching off mysql option
-- Looking for Oracle
-- Oracle not found.
-- Oracle: You can specify includes: -DORACLE_PATH_INCLUDES=/usr/include/oracle/10.2.0.3/client
--    currently found includes:
-- Oracle: You can specify libs: -DORACLE_PATH_LIB=/usr/lib/oracle/10.2.0.3/client/lib
--    currently found libs: ORACLE_LIBRARY_OCCI-NOTFOUND;ORACLE_LIBRARY_CLNTSH-NOTFOUND;ORACLE_LIBRARY_LNNZ-NOTFOUND
-- Oracle not found. Switching off oracle option
-- Looking for ODBC
-- Could NOT find ODBC (missing: ODBC_INCLUDE_DIR)
-- ODBC not found. Switching off odbc option
-- Looking for PostgreSQL
-- Could NOT find PostgreSQL (missing: POSTGRESQL_INCLUDE_DIR POSTGRESQL_LIBRARIES)
-- PostgreSQL not found. Switching off pgsql option
-- Looking for SQLite
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE)
-- Found Sqlite: /Library/Developer/CommandLineTools/SDKs/MacOSX13.1.sdk/usr/include
-- Looking for Pythia6
-- Pythia6 not found. Switching off pythia6 option
-- Looking for Pythia8
-- Could NOT find Pythia8 (missing: PYTHIA8_INCLUDE_DIR PYTHIA8_LIBRARY)
-- Pythia8 not found. Switching off pythia8 option
-- Looking for FFTW3
-- FFTW3 not found. Switching off fftw3 option
-- Looking for CFITSIO
-- Could NOT find CFITSIO (missing: CFITSIO_INCLUDE_DIR CFITSIO_LIBRARY)
-- CFITSIO not found. You can enable the option 'builtin_cfitsio' to build the library internally'
--                    For the time being switching off 'fitsio' option
-- Support Shadow password not found. Switching off shadowpw option
-- Alien API not found. Set variable ALIEN_DIR to point to your Alien installation
-- For the time being switching OFF 'alien' option
-- Monalisa not found. Set variable MONALISA_DIR to point to your Monalisa installation
-- For the time being switching OFF 'monalisa' option
-- Looking for XROOTD
-- XROOTD not found. Set environment variable XRDSYS to point to your XROOTD installation
--                   Alternatively, you can also enable the option 'builtin_xrootd' to build XROOTD  internally'
--                   For the time being switching OFF 'xrootd' option
-- Could NOT find GFAL (missing: GFAL_INCLUDE_DIR SRM_IFCE_INCLUDE_DIR GFAL_LIBRARY)
-- GFAL library not found. Set variable GFAL_DIR to point to your gfal installation
                      and the variable SRM_IFCE_DIR to the srm_ifce installation
-- For the time being switching OFF 'gfal' option
-- Could NOT find DCAP (missing: DCAP_INCLUDE_DIR DCAP_LIBRARY)
-- dCap library not found. Set variable DCAP_DIR to point to your dCache installation
-- For the time being switching OFF 'dcache' option
CMake Warning (dev) at /Applications/CMake.app/Contents/share/cmake-3.25/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
  The package name passed to `find_package_handle_standard_args` (LDAP) does
  not match the name of the calling package (Ldap).  This can lead to
  problems in calling code that expects `find_package` result variables
  (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  cmake/modules/FindLdap.cmake:21 (find_package_handle_standard_args)
  cmake/modules/SearchInstalledSoftware.cmake:780 (find_package)
  CMakeLists.txt:46 (include)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Found LDAP: /Library/Developer/CommandLineTools/SDKs/MacOSX13.1.sdk/usr/include
-- >>> Option 'chirp' not implemented yet! Signal your urgency to pere.mato@cern.ch
-- >>> Option 'glite' not implemented yet! Signal your urgency to pere.mato@cern.ch
-- >>> Option 'hdfs' not implemented yet! Signal your urgency to pere.mato@cern.ch
-- >>> Option 'pch' not implemented yet! Signal your urgency to pere.mato@cern.ch
-- >>> Option 'sapdb' not implemented yet! Signal your urgency to pere.mato@cern.ch
-- >>> Option 'srp' not implemented yet! Signal your urgency to pere.mato@cern.ch
-- Enabled support for:  asimage astiff bonjour builtin_afterimage builtin_ftgl builtin_freetype builtin_glew builtin_pcre builtin_lz4 libcxx cintex cocoa exceptions explicitlink fortran genvector krb5 ldap memstat opengl python reflex shared sqlite thread tmva vdt xml
-- Performing Test CXX_HAS_Wno_strict_aliasing
-- Performing Test CXX_HAS_Wno_strict_aliasing - Success
-- Performing Test CXX_HAS_Wno_ignored_qualifiers
-- Performing Test CXX_HAS_Wno_ignored_qualifiers - Success
-- Performing Test CXX_HAS_Wno_potentially_evaluated_expression
-- Performing Test CXX_HAS_Wno_potentially_evaluated_expression - Success
Running /Users/diiego/software/ROOT/ROOT_5.34.38/root/build/unix/compiledata.sh
Making include/compiledata.h
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/diiego/software/ROOT/ROOT_5.34.38/build

Welcome to the ROOT forum

Just for curiosity: is there a specific reason to install such old version of ROOT on a such recent machine?

The software I am using requires it

21 posts were split to a new topic: Building ROOT 6.24 (the v6-24-00-patches branch)

Number 5 is Alive!