Uploaded image for project: 'ROOT'
  1. ROOT
  2. ROOT-9072

Can't build 6.10/08 in C++14 mode with Xcode 9.0

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: 6.10/08
    • Fix Version/s: 6.10/08
    • Component/s: Core Libraries, I/O
    • Labels:
      None
    • Environment:

      macOS High Sierra, Xcode 9.0

    • Development:

      Description

      According to the release notes (https://root.cern.ch/doc/v610/release-notes.html#release-6.1008) compilation issues on High Sierra should've been solved in tag v6-10-08. But I still see the following:

      [bash][tauriel]:build > cmake -Dall=ON -Dcxx14=ON -Drpath=ON -Dbuiltin_xrootd=ON -Dbuiltin_gsl=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=~/Software/ROOT/v6-10-08 ../root/
      [bash][tauriel]:build > make -j4
      ...
      [ 70%] Building CXX object core/thread/CMakeFiles/ThreadObjs.dir/src/TConditionImp.cxx.o
      In file included from /Users/krasznaa/Development/ROOT/build/root/io/io/v7/src/TFile.cxx:15:
      /Users/krasznaa/Development/ROOT/build/build/include/ROOT/TFile.hxx:163:26: error: no member named 'to_string' in
            'std::__1::basic_string_view<char, std::__1::char_traits<char> >'
          auto dep = Find(name.to_string());
                          ~~~~ ^
      /Users/krasznaa/Development/ROOT/build/root/io/io/v7/src/TFile.cxx:100:48: error: no member named 'to_string' in
            'std::__1::basic_string_view<char, std::__1::char_traits<char> >'
          fOldFile->WriteObjectAny(address, cl, name.to_string().c_str());
                                                ~~~~ ^
      /Users/krasznaa/Development/ROOT/build/root/io/io/v7/src/TFile.cxx:147:54: error: no member named 'to_string' in
            'std::__1::basic_string_view<char, std::__1::char_traits<char> >'
        auto v6storage = std::make_unique<TV6Storage>(name.to_string(), GetV6TFileOpts(mode, opts));
                                                      ~~~~ ^
      /Users/krasznaa/Development/ROOT/build/root/io/io/v7/src/TFile.cxx:194:33: error: no member named 'to_string' in
            'std::__1::basic_string_view<char, std::__1::char_traits<char> >'
        ::TFile::SetCacheFileDir(path.to_string().c_str());
                                 ~~~~ ^
      4 errors generated.
      make[2]: *** [io/io/CMakeFiles/RIOObjs.dir/v7/src/TFile.cxx.o] Error 1
      make[2]: *** Waiting for unfinished jobs....
      [ 70%] Building CXX object core/base/CMakeFiles/Base.dir/src/InitGui.cxx.o
      [ 70%] Building CXX object core/thread/CMakeFiles/ThreadObjs.dir/src/TMutex.cxx.o
      [ 70%] Building CXX object core/base/CMakeFiles/Base.dir/src/Match.cxx.o
      [ 70%] Building CXX object core/thread/CMakeFiles/ThreadObjs.dir/src/TMutexImp.cxx.o
      [ 70%] Building CXX object core/base/CMakeFiles/Base.dir/src/String.cxx.o
      make[1]: *** [io/io/CMakeFiles/RIOObjs.dir/all] Error 2
      make[1]: *** Waiting for unfinished jobs....

      My educated guess is that only code compiled with C++11 enabled was fixed for this latest clang version.

      As a reference, since we/I wanted to be able to use the exact same ROOT version on High Sierra that we use for production in ATLAS at the moment, I fixed the build of v6-08-06 a while ago for our analysis build with these patches:

      https://gitlab.cern.ch/atlas/atlasexternals/blob/master/External/ROOT/patches/clang90.patch

      Though the fix for this particular issue should be obvious...

      Cheers,
      Attila

        Attachments

          Activity

            People

            Assignee:
            mato Pere Mato Vila
            Reporter:
            akraszna Attila Krasznahorkay
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: