Problem running root on macOS 10.13.6: ERROR in cling::CIFactory::createCI(): cannot extract standard library include paths!

I am trying to run root on a MacBook Air that was recently upgraded to macOS 10.13.6 (root ran without problems prior to the upgrade).

Upon starting root I now get the following error:

[Peters-MacBook-Air-3:~] pmjacobs% root
ERROR in cling::CIFactory::createCI(): cannot extract standard library include paths!
Invoking:
  LC_ALL=C /Library/Developer/CommandLineTools/usr/bin/c++   -O2 -DNDEBUG -xc++ -E -v /dev/null 2>&1 >/dev/null | awk '/^#include </,/^End of search/{if (!/^#include </ && !/^End of search/){ print }}' | GREP_OPTIONS= grep -E "(c|g)\+\+"
Results was:
With exit code 256
input_line_1:1:10: fatal error: 'new' file not found
#include <new>
         ^~~~~
input_line_3:37:10: fatal error: 'string' file not found
#include <string>
         ^~~~~~~~
   ------------------------------------------------------------
  | Welcome to ROOT 6.14/02                http://root.cern.ch |
  |                               (c) 1995-2018, The ROOT Team |
  | Built for macosx64                                         |
  | From tags/v6-14-02@v6-14-02, Jul 27 2018, 10:56:25         |
  | Try '.help', '.demo', '.license', '.credits', '.quit'/'.q' |
   ------------------------------------------------------------

input_line_9:1:10: fatal error: 'iostream' file not found
#include <iostream>
         ^~~~~~~~~~
root [0]

I note two previous posts to this forum reporting a similar problem:

(i) ERROR in cling::CIFactory::createCI(): cannot extract standard library include paths!

(ii) thread labelled 28284 (the interface for this message didn’t allow me to include the actual link for some reason)

In thread (i) the problem was solved by moving Xcode.app to the Applications folder. That solution evidently does not apply in my case - Xcode.app is already there and is evidently up-to-date:

[Peters-MacBook-Air-3:~] pmjacobs% /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ -O2 -DNDEBUG -xc++ -E -v /dev/null
Apple LLVM version 9.1.0 (clang-902.0.39.2)
Target: x86_64-apple-darwin17.7.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
 "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang" -cc1 -triple x86_64-apple-macosx10.13.0 -Wdeprecated-objc-isa-usage -Werror=deprecated-objc-isa-usage -E -disable-free -disable-llvm-verifier -discard-value-names -main-file-name null -mrelocation-model pic -pic-level 2 -mthread-model posix -mdisable-fp-elim -fno-strict-return -masm-verbose -munwind-tables -target-cpu penryn -target-linker-version 351.8 -v -dwarf-column-info -debugger-tuning=lldb -resource-dir /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.1.0 -D NDEBUG -stdlib=libc++ -O2 -fdeprecated-macro -fdebug-compilation-dir /Users/pmjacobs -ferror-limit 19 -fmessage-length 133 -stack-protector 1 -fblocks -fobjc-runtime=macosx-10.13.0 -fencode-extended-block-signature -fcxx-exceptions -fexceptions -fmax-type-align=16 -fdiagnostics-show-option -fcolor-diagnostics -vectorize-loops -vectorize-slp -o - -x c++ /dev/null
clang -cc1 version 9.1.0 (clang-902.0.39.2) default target x86_64-apple-darwin17.7.0
ignoring nonexistent directory "/usr/include/c++/v1"
ignoring nonexistent directory "/usr/include"
#include "..." search starts here:
#include <...> search starts here:
 /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1
 /usr/local/include
 /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.1.0/include
 /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include
 /System/Library/Frameworks (framework directory)
 /Library/Frameworks (framework directory)
End of search list.
# 1 "/dev/null"
# 1 "<built-in>" 1
# 1 "<built-in>" 3
# 353 "<built-in>" 3
# 1 "<command line>" 1
# 1 "<built-in>" 2
# 1 "/dev/null" 2

[Peters-MacBook-Air-3:~] pmjacobs%

Thread (ii) refers to thread (i), so is not helpful.

Please advise, thanks.

Peter Jacobs
Lawrence Berkeley National Laboratory

If things were working before, and stopped working after you upgraded the OS, then you will need to rebuild ROOT from source. Unfortunately, ROOT’s binary distribution for macOS depends on the system compiler and headers, and these often get changed by Apple when they upgrade the OS in a way that breaks ROOT.

Thanks, this solved the problem.

Regards,

Peter Jacobs

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