Message: Geant4 10.0p01 with c++11 does not compile Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Geant4 10.0p01 with c++11 does not compile 

Forum: Installation and Configuration
Date: 11 Jun, 2014
From: <Marty>

System configuration: Mac OS 10.9.3; XCode 5.1.1; Clang 5.1.0; Cmake 2.8-11

cmake -DGEANT4_INSTALL_DATA=ON -DGEANT4_USE_OPENGL_X11=ON -DCMAKE_INSTALL_PREFIX=/geant4/geant4_10_00_p01-install/ /geant4/geant4_10_00_p01/

make -j 4

works just fine. Example B1 is also running.

Now I tried to compile against c++ standard 'c++11' (-DGEANT4_BUILD_CXXSTD=c++11) and make fails:

/geant4/geant4_10_00_p01/source/processes/electromagnetic/dna/processes/src/G4DNASecondOrderReaction.cc:64:22: warning: reference
      'fpSecondOrderReactionState' is not yet bound to a value when used here [-Wuninitialized]
    InitProcessState(fpSecondOrderReactionState, fpState)
                     ^
/geant4/geant4_10_00_p01/source/processes/electromagnetic/dna/management/include/G4VITProcess.hh:54:32: note: expanded from macro 'InitProcessState'
    destination(reference_cast(destination,source))
                               ^
/geant4/geant4_10_00_p01/source/processes/electromagnetic/dna/processes/src/G4DNASecondOrderReaction.cc:71:22: warning: reference
      'fpSecondOrderReactionState' is not yet bound to a value when used here [-Wuninitialized]
    InitProcessState(fpSecondOrderReactionState, fpState)
                     ^
/geant4/geant4_10_00_p01/source/processes/electromagnetic/dna/management/include/G4VITProcess.hh:54:32: note: expanded from macro 'InitProcessState'
    destination(reference_cast(destination,source))
                               ^
8 warnings and 1 error generated.
make[2]: *** [source/processes/CMakeFiles/G4processes.dir/electromagnetic/dna/processes/src/G4DNASecondOrderReaction.cc.o] Error 1
make[2]: *** Waiting for unfinished jobs....
6 warnings generated.
6 warnings generated.
6 warnings generated.
make[1]: *** [source/processes/CMakeFiles/G4processes.dir/all] Error 2
make: *** [all] Error 2

Is there an issue with c++11 compatibility? Or does this have to do with Mavericks? (I know that Mavericks is not officially supported but it seems to work for c++98)

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 Question: Re: Geant4 10.0p01 with c++11 does not compile   (Ben Morgan - 13 Jun, 2014)
(_ Feedback: Re: Geant4 10.0p01 with c++11 does not compile   (Marty - 13 Jun, 2014)
(_ Feedback: Re: Geant4 10.0p01 with c++11 does not compile   (Ben Morgan - 18 Jun, 2014)
(_ None: Re: Geant4 10.0p01 with c++11 does not compile   (Marty - 18 Jun, 2014)
 Add Message Add Message
to: "Geant4 10.0p01 with c++11 does not compile"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]