Homebrew installation of ROOT on Mac not working

Hey folks,

I am trying to install ROOT for the first time as I am beginning work in an HEP research group. Online instructions suggested using Homebrew to do that, so that is what I did. But, after the installation I tried to use ROOT but got errors:

Bens-MacBook-Pro-3:Users benluke$ root
input_line_1:1:2: fatal error: malformed or corrupted AST file: 'could not find file '/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/bank.modulemap' referenced by AST file'
#include <new>
 ^
input_line_1:1:2: note: after modifying system headers, please delete the module cache at '/usr/local/Cellar/root/6.32.02/lib/root'
input_line_1:1:2: note: imported by module 'std' in '/usr/local/Cellar/root/6.32.02/lib/root/std.pcm'
Warning in cling::IncrementalParser::CheckABICompatibility():
  Failed to extract C++ standard library version.
Warning in cling::IncrementalParser::CheckABICompatibility():
  Possible C++ standard library mismatch, compiled with _LIBCPP_ABI_VERSION '1'
  Extraction of runtime standard library version was: ''
Replaced symbol at_quick_exit cannot be found in JIT!
<<< cling interactive line includer >>>: fatal error: module file '/usr/local/Cellar/root/6.32.02/lib/root/Darwin.pcm' is out of date and needs to be rebuilt
Failed to load module Darwin
Failed to load module std
Failed to load module _Builtin_intrinsics
Failed to load module ROOT_Foundation_C
Failed to load module ROOT_Config
Failed to load module ROOT_Rtypes
Failed to load module ROOT_Foundation_Stage1_NoRTTI
Failed to load module Core
Failed to load module Rint
Failed to load module RIO
Failed to load module MathCore
Failed to load module Hist
Failed to load module Darwin
Failed to load module RHTTPSniff
Failed to load module Imt
Failed to load module HistPainter
Failed to load module PyMVA
Failed to load module RDAVIX
Failed to load module ROOTBrowsable
Failed to load module RHTTP
Failed to load module FitPanel
Failed to load module ROOTVecOps
Failed to load module RMySQL
Failed to load module Quadp
Failed to load module ROOT_Foundation_Stage1_NoRTTI
Failed to load module GeomPainter
Failed to load module Genetic
Failed to load module Eve
Failed to load module TreeViewer
Failed to load module Physics
Failed to load module ROOTNTuple
Failed to load module EG
Failed to load module Tree
Failed to load module HistFactory
Failed to load module Spectrum
Failed to load module Matrix
Failed to load module Html
Failed to load module Hist
Failed to load module GuiHtml
Failed to load module _Builtin_intrinsics
Failed to load module Gpad
Failed to load module TMVAGui
Failed to load module ROOTEve
Failed to load module Fumili
Failed to load module Net
Failed to load module RGL
Failed to load module Geom
Failed to load module Postscript
Failed to load module GCocoa
Failed to load module ROOTGpadv7
Failed to load module RCsg
Failed to load module Cling_Runtime
Failed to load module SPlot
Failed to load module Hbook
Failed to load module GeomBuilder
Failed to load module RooFit
Failed to load module ROOT_Config
Failed to load module RooFitMore
Failed to load module Rint
Failed to load module XMLParser
Failed to load module MultiProc
Failed to load module RooStats
Failed to load module RooFitRDataFrameHelpers
Failed to load module FITSIO
Failed to load module Ged
Failed to load module Recorder
Failed to load module FFTW
Failed to load module GuiBld
Failed to load module ROOTWebDisplay
Failed to load module RooFitCore
Failed to load module Gui
Failed to load module SQLIO
Failed to load module XMLIO
Failed to load module ROOT_Rtypes
Failed to load module std
Failed to load module TMVAUtils
Failed to load module ROOTHistDraw
Failed to load module RIO
Failed to load module ROOTTMVASofie
Failed to load module ASImage
Failed to load module ROOT_Foundation_C
Failed to load module MathMore
Failed to load module RooFitXRooFit
Failed to load module RooFitHS3
Failed to load module Foam
Failed to load module RSQLite
Failed to load module SpectrumPainter
Failed to load module Minuit2
Failed to load module Core
Failed to load module MLP
Failed to load module ROOTDataFrame
Failed to load module GenVector
Failed to load module NetxNG
Failed to load module ROOTBrowserv7
Failed to load module Minuit
Failed to load module RootAuth
Failed to load module Graf3d
Failed to load module TMVA
Failed to load module ROOTNTupleUtil
Failed to load module ASImageGui
Failed to load module Graf
Failed to load module Gdml
Failed to load module ROOTTreeViewer
Failed to load module Cling_Runtime_Extra
Failed to load module MathCore
Failed to load module Gviz3d
Failed to load module WebGui6
Failed to load module ROOTTPython
Failed to load module ROOTHist
Failed to load module TreePlayer
Failed to load module ROOTGeomViewer
Failed to load module ROOTGraphicsPrimitives
Failed to load module ROOTFitPanelv7
Failed to load module Smatrix
Failed to load module RooFitJSONInterface
Failed to load module Thread

 *** Break *** segmentation violation
[/usr/lib/system/libsystem_platform.dylib] _sigtramp (no debug info)
[<unknown binary>] (no debug info)
[/usr/local/Cellar/root/6.32.02/lib/root/libCling.so] ROOT::TMetaUtils::TNormalizedCtxtImpl::TNormalizedCtxtImpl(cling::LookupHelper const&) (no debug info)
[/usr/local/Cellar/root/6.32.02/lib/root/libCling.so] ROOT::TMetaUtils::TNormalizedCtxt::TNormalizedCtxt(cling::LookupHelper const&) (no debug info)
[/usr/local/Cellar/root/6.32.02/lib/root/libCling.so] TCling::TCling(char const*, char const*, char const* const*, void*) (no debug info)
[/usr/local/Cellar/root/6.32.02/lib/root/libCling.so] CreateInterpreter (no debug info)
[/usr/local/Cellar/root/6.32.02/lib/root/libCore.so] TROOT::InitInterpreter() (no debug info)
[/usr/local/Cellar/root/6.32.02/lib/root/libCore.so] ROOT::Internal::GetROOT2() (no debug info)
[/usr/local/Cellar/root/6.32.02/lib/root/libCore.so] TApplication::TApplication(char const*, int*, char**, void*, int) (no debug info)
[/usr/local/Cellar/root/6.32.02/lib/root/libRint.so] TRint::TRint(char const*, int*, char**, void*, int, bool, bool) (no debug info)
[/usr/local/Cellar/root/6.32.02/bin/root.exe] main (no debug info)
[/usr/lib/dyld] start (no debug info)

I’m working on macOS 13.6.7. I also saw the recent post describing the same issue (sadly I’m a new user here and cannot include a link to said post). Given the suggestion there, I sought to download an older version of ROOT from source. But following the installation instructions found on the ROOT website for macOS, it looked like I needed to update Xcode. I then tried to update Xcode but was stopped because my OS will not support the latest version of Xcode, and I am not able to update to the required macOS 14.0. To my knowledge (and after sifting through some online forums), it is not possible to download an older version of Xcode that is compatible with my OS.

Is there anything I can do to get ROOT running on my Mac? I feel I’ve exhausted all other resources. Thanks for any help!

–Ben

Welcome to the ROOT Forum!
Looking at the download page for the latest release: Release 63202 - ROOT you cas see there are binaries for macOS 13.6 arm64 Xcode 15 and macOS 13.6 arm64 Xcode 15. Can you try the one matching your architecture?

Thanks for the reply, bellenot.

I did what you said and installed the appropriate ROOT binary for my Mac. I took all the steps recommended on the ROOT install page for a pre-compiled binary. This was successful up until I tried to launch the ROOT interactive shell in Terminal by typing root and pressing return–it complained with “Bad CPU type in executable”. I’ve searched the internet for this error having to do with ROOT, but I haven’t found anything for it. Do you have ideas? Thanks!

So apparently you don’t have a arm64 architecture, so I’m afraid you’ll have to build from source…

My last ditch effort to not build from source was to install an older pre-build where they included a macOS 13.6 x86_64 (my Mac is a 2017 model). I installed release 6.30.04. It installed fine but I get different errors from the last ones.

clang: error: argument to '-isysroot' is missing (expected 1 value)
clang: error: no input files
ERROR in cling::CIFactory::createCI(): cannot extract standard library include paths!
Invoking:
  LC_ALL=C /Library/Developer/CommandLineTools/usr/bin/c++ -isysroot;/Library/Developer/CommandLineTools/SDKs/MacOSX14.2.sdk   -xc++ -E -v /dev/null 2>&1 | sed -n -e '/^.include/,${' -e '/^ \/.*++/p' -e '}'
Results was:
clang: error: argument to '-isysroot' is missing (expected 1 value)
clang: error: no input files
With exit code 0
input_line_1:1:2: fatal error: malformed or corrupted AST file: 'could not find file '/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/netinet.modulemap' referenced by AST file'
#include <new>
 ^
input_line_1:1:2: note: after modifying system headers, please delete the module cache at '/Applications/root_v6.30.04/lib'
input_line_1:1:2: note: imported by module 'std' in '/Applications/root_v6.30.04/lib/std.pcm'
Warning in cling::IncrementalParser::CheckABICompatibility():
  Failed to extract C++ standard library version.
Warning in cling::IncrementalParser::CheckABICompatibility():
  Possible C++ standard library mismatch, compiled with _LIBCPP_ABI_VERSION '1'
  Extraction of runtime standard library version was: ''
Replaced symbol at_quick_exit cannot be found in JIT!
<<< cling interactive line includer >>>: fatal error: module file '/Applications/root_v6.30.04/lib/Darwin.pcm' is out of date and needs to be rebuilt

plus a long string of modules that failed to load, and some more stuff.

Any thoughts about this, or has it really come down to building from source? (I’m inexperienced with ROOT and have been hoping it wouldn’t come down to building from source…)

I guess it’s because your version of XCode doesn’t match the one ROOT is expecting (but I’m not a MacOS user…)

I finally got it working. I am using ROOT 6.30.04 since this is the most recent version compatible with my 2017 Mac that runs Ventura 13.6. Then I had to install a more recent version of Xcode since the one available on the App Store required a more recent OS than what my Mac could accommodate. I thought at first that this would fix the problem, but it didn’t. Apparently installing Xcode does not automatically install the newer version of command line tools, so I had to do this manually. The link to the Apple developer page with older software versions is Sign In - Apple. (I downloaded Xcode 15.2, since this is the most recent version my OS will allow. I also downloaded command line tools for Xcode 15.1 [there was not a version for 15.2 oddly].) After all this, ROOT finally seems to be working (or at least it does what it’s supposed to when I type root in Terminal and press return).

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.