Message: unknown type G4String G4Int Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None unknown type G4String G4Int 

Forum: Installation and Configuration
Date: 02 Oct, 2014
From: Anna Corsi <Anna Corsi>

Hello,

I am compiling an application using root and geant4 on OSX 10.9.4. I have installed geant4.9.6 while before I used geant4.9.3. I compile with cmake (CMakeList.txt is attached) and make, but have the following error message.

Any idea? Thanks in advance, Anna

acorsi@phnmcd68:~/codes/shogun-sim/EventBuilderRIKEN$ make
Scanning dependencies of target EventBuilder
[  3%] Building CXX object CMakeFiles/EventBuilder.dir/EventBuilder.cc.o
/Users/acorsi/codes/shogun-sim/EventBuilderRIKEN/EventBuilder.cc:367:24: warning: format specifies type 'char *' but the argument has type
      'char (*)[300]' [-Wformat]
      fscanf(fin,"%s ",&root_in); printf("%s %s \n",temp,root_in);
                  ~~   ^~~~~~~~
/Users/acorsi/codes/shogun-sim/EventBuilderRIKEN/EventBuilder.cc:370:24: warning: format specifies type 'char *' but the argument has type
      'char (*)[300]' [-Wformat]
      fscanf(fin,"%s ",&root_out); 
                  ~~   ^~~~~~~~~
2 warnings generated.
[  6%] Building CXX object CMakeFiles/EventBuilder.dir/src/EventAction.cc.o
In file included from /Users/acorsi/codes/shogun-sim/EventBuilderRIKEN/src/EventAction.cc:1:
/Users/acorsi/codes/shogun-sim/EventBuilderRIKEN/include/EventAction.hh:20:22: error: unknown type name 'G4String'
    void SetDrawFlag(G4String val) {drawFlag = val;};
                     ^
/Users/acorsi/codes/shogun-sim/EventBuilderRIKEN/include/EventAction.hh:21:25: error: unknown type name 'G4int'
    void SetPrintModulo(G4int val) {printModulo = val;};
                        ^
/Users/acorsi/codes/shogun-sim/EventBuilderRIKEN/include/EventAction.hh:25:5: error: unknown type name 'G4String'
    G4String                  drawFlag;
    ^
/Users/acorsi/codes/shogun-sim/EventBuilderRIKEN/include/EventAction.hh:26:5: error: unknown type name 'G4int'
    G4int                     printModulo;                    
    ^
/Users/acorsi/codes/shogun-sim/EventBuilderRIKEN/src/EventAction.cc:24:53: warning: unused parameter 'evt' [-Wunused-parameter]
void EventAction::BeginOfEventAction(const G4Event* evt)
                                                    ^
In file included from /Users/acorsi/codes/shogun-sim/EventBuilderRIKEN/src/EventAction.cc:1:
/Users/acorsi/codes/shogun-sim/EventBuilderRIKEN/include/EventAction.hh:25:31: warning: private field 'drawFlag' is not used
      [-Wunused-private-field]
    G4String                  drawFlag;
                              ^
/Users/acorsi/codes/shogun-sim/EventBuilderRIKEN/include/EventAction.hh:26:31: warning: private field 'printModulo' is not used
      [-Wunused-private-field]
    G4int                     printModulo;                    
                              ^
3 warnings and 4 errors generated.
make[2]: *** [CMakeFiles/EventBuilder.dir/src/EventAction.cc.o] Error 1
make[1]: *** [CMakeFiles/EventBuilder.dir/all] Error 2
make: *** [all] Error 2

   Attachment:
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2014/10/02/23.17-57705-CMakeLists.txt

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

1 None: Re: unknown type G4String G4Int   (Ben Morgan - 06 Oct, 2014)
 Add Message Add Message
to: "unknown type G4String G4Int"

 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 ]