Skip to content
Snippets Groups Projects

Fix clang compilation failure in XmlTools Evaluator

Merged Gerhard Raven requested to merge fix-clang-error into master

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Gerhard Raven mentioned in merge request !1408 (merged)

    mentioned in merge request !1408 (merged)

  • Gerhard Raven added 1 commit

    added 1 commit

    Compare with previous version

  • Edited by Software for LHCb
  • @clemenci how can we check that this fixes the problem? The clang60 build in lhcb-lcg-dev3 slot never seems to run....

  • Author Developer

    @clemenci: it would also be nice to have a recipe for compiling with clang which does not involve lxplus, but would work on any (centos7) machine with /cvmfs available. I've tried several times, but haven't managed to make it work (the recipe provided for lxplus unfortunately does not work on our local centos7 machines)

  • @cattanem I just found out that some of the jobs we are using to wait for LCG nightlies installation were crashing randomly. I added notification + retry, so it should be slightly more reliable... just meaning that I will not have to retry by hand as it happened today for the dev3/clang60 build.

    @graven, it still does not work: https://lhcb-nightlies.cern.ch/logs/build/nightly/lhcb-lcg-dev3/598/x86_64-centos7-clang60-opt/LHCb/

    And about the recipe... why do you say it's for lxplus? I do not see anything about lxplus in https://twiki.cern.ch/twiki/bin/view/LHCb/SupportedPlatforms#Development_platforms_binary_bui you only have to be aware that to get the required LbScripts version you need to source /cvmfs/lhcb.cern.ch/lib/LbLoginDev.sh... apart from a fix that was available only for the nightlies and I just pushed to CVMFS (you should get it in ~1h)

  • Author Developer

    @clemenci: I must be doing something stupid. The following just works:

    -- zsh 5.0.2 on stbc-i5.nikhef.nl (x86_64 running Linux 3.10.0-693.2.2.el7.x86_64)--
    stbc-i5 1> cd project/master
    stbc-i5 2> export CMTCONFIG=x86_64-centos7-gcc7-opt ; source /cvmfs/lhcb.cern.ch/lib/LbLoginDev.sh
    WARNING : using environment variable CMTCONFIG for cmtconfig
    ********************************************************************************
    *                         ---- LHCb Login v9r2p6 ----                          *
    *    Building with gcc7 on centos7 x86_64 system (x86_64-centos7-gcc7-opt)     *
    ********************************************************************************
     --- User_release_area is set to /user/graven/cmtuser
     --- LHCBPROJECTPATH is set to:
        /cvmfs/lhcb.cern.ch/lib/lhcb
        /cvmfs/lhcb.cern.ch/lib/lcg/releases
        /cvmfs/lhcb.cern.ch/lib/lcg/app/releases
        /cvmfs/lhcb.cern.ch/lib/lcg/external
    --------------------------------------------------------------------------------
    stbc-i5 3> cd Gaudi
    stbc-i5 4> make configure
    cmake --build /project/bfys/graven/master/Gaudi/build.x86_64-centos7-gcc7-opt --target rebuild_cache -- 
    [1/1] Running CMake to regenerate build system...
    -- Using heptools 93 from /cvmfs/sft.cern.ch/lcg/releases/LCG_93/LCG_externals_x86_64-centos7-gcc7-opt.txt
    -- Using ccache for building
    -- Prefix COMPILE commands with ' /cvmfs/sft.cern.ch/lcg/releases/LCG_93/ccache/3.3.4/x86_64-centos7-gcc7-opt/bin/ccache'
    -- Using ccache for building
    -- Prefix COMPILE commands with ' /cvmfs/sft.cern.ch/lcg/releases/LCG_93/ccache/3.3.4/x86_64-centos7-gcc7-opt/bin/ccache'
    -- Looking for local directories...
    -- Found:
    ... remainder not shown ...

    but this does not:

    -- zsh 5.0.2 on stbc-i5.nikhef.nl (x86_64 running Linux 3.10.0-693.2.2.el7.x86_64)--
    stbc-i5 1> cd project/master
    stbc-i5 2> export CMTCONFIG=x86_64-centos7-clang60-opt ; source /cvmfs/lhcb.cern.ch/lib/LbLoginDev.sh
    WARNING : using environment variable CMTCONFIG for cmtconfig
    ********************************************************************************
    *                         ---- LHCb Login v9r2p6 ----                          *
    * Building with clang60 on centos7 x86_64 system (x86_64-centos7-clang60-opt)  *
    ********************************************************************************
     --- User_release_area is set to /user/graven/cmtuser
     --- LHCBPROJECTPATH is set to:
        /cvmfs/lhcb.cern.ch/lib/lhcb
        /cvmfs/lhcb.cern.ch/lib/lcg/releases
        /cvmfs/lhcb.cern.ch/lib/lcg/app/releases
        /cvmfs/lhcb.cern.ch/lib/lcg/external
    --------------------------------------------------------------------------------
    stbc-i5 3> cd Gaudi
    stbc-i5 4> make configure
    mkdir -p /project/bfys/graven/master/Gaudi/build.x86_64-centos7-clang60-opt
    cd /project/bfys/graven/master/Gaudi/build.x86_64-centos7-clang60-opt && cmake -DCMAKE_TOOLCHAIN_FILE=/project/bfys/graven/master/Gaudi/toolchain.cmake -GNinja /project/bfys/graven/master/Gaudi
    CMake Error at cmake/UseHEPTools.cmake:86 (message):
      Cannot find heptools 93.
    Call Stack (most recent call first):
      cmake/GaudiDefaultToolchain.cmake:10 (use_heptools)
      toolchain.cmake:15 (include)
      /cvmfs/lhcb.cern.ch/lib/contrib/CMake/3.11.0/Linux-x86_64/share/cmake-3.11/Modules/CMakeDetermineSystem.cmake:94 (include)
      CMakeLists.txt
    
    
    CMake Error: CMake was unable to find a build program corresponding to "Ninja".  CMAKE_MAKE_PROGRAM is not set.  You probably need to select a different build tool.
    CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
    CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
    -- Configuring incomplete, errors occurred!
    make: *** [/project/bfys/graven/master/Gaudi/build.x86_64-centos7-clang60-opt/build.ninja] Error 1
    

    Even adding explicitly eg. export CMAKE_PREFIX_PATH=/cvmfs/sft-nightlies.cern.ch/lcg/nightlies/dev3:$CMAKE_PREFIX_PATH does not help -- somehow it seems impossible to find a clang60 version of heptools 93...

    what am I doing wrong?

  • Sorry, my bad... I tested the recipe with lb-dev --nightly ....

    After LbLogin, you have to export CMAKE_PREFIX_PATH=/cvmfs/sft-nightlies.cern.ch/lcg/nightlies/dev3/Thu:$CMAKE_PREFIX_PATH (the day strin is important).

  • Author Developer

    Ah, that seems to do the trick!

  • Author Developer

    Looks like this is a known bug in clang

  • Author Developer

    seems to be fixed in clang-trunk -- see here

  • Gerhard Raven added 1 commit

    added 1 commit

    • 6f96b8ba - workaround for clang problem with std::visit

    Compare with previous version

  • Unfortunately the clang build in lhcb-lcg-dev3 is completely unreliable, it has not run since 5 days. I'll leave this MR open until by some magic the build decides to run....

  • Author Developer

    Since lhcb-lcg-dev3 still hasn't run, can I suggest the opposite strategy, i.e. it seems this version works fine with gcc (as the gcc builds do run), so it is at least as good as the master, and this version has a good chance of working with clang, whereas master does not -- hence I'd propose to merge it 'as-is', without waiting for the dev3 build.

  • Marco Cattaneo mentioned in commit cf432af7

    mentioned in commit cf432af7

Please register or sign in to reply
Loading