Message: Dump while compiling detectorconstruction.cc Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Dump while compiling detectorconstruction.cc 

Forum: Geometry
Date: 20 Apr, 2011
From: Linxi Shi <Linxi Shi>

Hi,

I was trying to implement a project with a geometry constructed in my BCTDetectorConstruction and a BCTdetectorMessenger is supposed to change the geometrical parameters, which is based on example N03.  While I was trying to 'make', it gave me a long list of error, as:
--------------------------------------------------------------------
Compiling BCTTestCellParameterisation.cc ...
BCTTestCellParameterisation.cc
Compiling BCTTestDetectorConstruction.cc ...
BCTTestDetectorConstruction.cc
e:/Geant4/geant4_9_3_p01/source/global/HEPGeometry/include\geomdefs.hh(43) : err
or C2864: 'BCTdetectorMessenger::kInfinity' : only static const integral data me
mbers can be initialized within a class
e:/Geant4/geant4_9_3_p01/source/global/HEPGeometry/include\geomdefs.hh(47) : err
or C2864: 'BCTdetectorMessenger::kMinExitingNormalCosine' : only static const in
tegral data members can be initialized within a class
E:/CLHEP/include\CLHEP/Vector/ThreeVector.h(31) : error C2059: syntax error : 'n
amespace'
E:/CLHEP/include\CLHEP/Vector/ThreeVector.h(31) : error C2334: unexpected token(
s) preceding '{'; skipping apparent function body
E:/CLHEP/include\CLHEP/Vector/ThreeVector.icc(13) : error C2059: syntax error :
'namespace'
E:/CLHEP/include\CLHEP/Vector/ThreeVector.icc(13) : error C2334: unexpected toke
n(s) preceding '{'; skipping apparent function body
e:/Geant4/geant4_9_3_p01/source/global/management/include\G4ThreeVector.hh(43) :
 error C2039: 'Hep3Vector' : is not a member of 'CLHEP'
e:/Geant4/geant4_9_3_p01/source/global/management/include\G4ThreeVector.hh(43) :
 error C2146: syntax error : missing ';' before identifier 'G4ThreeVector'
e:/Geant4/geant4_9_3_p01/source/global/management/include\G4ThreeVector.hh(43) :
 error C4430: missing type specifier - int assumed. Note: C++ does not support d
efault-int
e:/Geant4/geant4_9_3_p01/source/global/management/include\G4ThreeVector.hh(43) :
 error C4430: missing type specifier - int assumed. Note: C++ does not support d
efault-int
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(86) : er
ror C2065: 'G4ThreeVector' : undeclared identifier
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(121) : e
rror C4430: missing type specifier - int assumed. Note: C++ does not support def
ault-int
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(121) : e
rror C2143: syntax error : missing ',' before '&'
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(126) : e
rror C2146: syntax error : missing ';' before identifier 'SurfaceNormal'
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(126) : e
rror C2433: 'BCTdetectorMessenger::G4VSolid::G4ThreeVector' : 'virtual' not perm
itted on data declarations
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(126) : e
rror C4430: missing type specifier - int assumed. Note: C++ does not support def
ault-int
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(126) : e
rror C4430: missing type specifier - int assumed. Note: C++ does not support def
ault-int
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(126) : e
rror C2143: syntax error : missing ',' before '&'
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(126) : e
rror C4430: missing type specifier - int assumed. Note: C++ does not support def
ault-int
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(126) : w
arning C4183: 'SurfaceNormal': missing return type; assumed to be a member funct
ion returning 'int'
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(130) : e
rror C4430: missing type specifier - int assumed. Note: C++ does not support def
ault-int
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(130) : e
rror C2143: syntax error : missing ',' before '&'
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(138) : e
rror C4430: missing type specifier - int assumed. Note: C++ does not support def
ault-int
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(138) : e
rror C2143: syntax error : missing ',' before '&'
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(138) : e
rror C2535: 'G4double BCTdetectorMessenger::G4VSolid::DistanceToIn(const int) co
nst' : member function already defined or declared
        e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(
130) : see declaration of 'BCTdetectorMessenger::G4VSolid::DistanceToIn'
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(142) : e
rror C4430: missing type specifier - int assumed. Note: C++ does not support def
ault-int
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(142) : e
rror C2143: syntax error : missing ',' before '&'
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(163) : e
rror C4430: missing type specifier - int assumed. Note: C++ does not support def
ault-int
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(163) : e
rror C2143: syntax error : missing ',' before '&'
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(163) : e
rror C2535: 'G4double BCTdetectorMessenger::G4VSolid::DistanceToOut(const int) c
onst' : member function already defined or declared
        e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(
142) : see declaration of 'BCTdetectorMessenger::G4VSolid::DistanceToOut'
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(192) : e
rror C2146: syntax error : missing ';' before identifier 'GetPointOnSurface'
e:/Geant4/geant4_9_3_p01/source/geometry/management/include\G4VSolid.hh(192) : e
rror C2433: 'BCTdetectorMessenger::G4VSolid::G4ThreeVector' : 'virtual' not perm
itted on data declarations.......so on a very long list
----------------------------------------------------------------------

I am not very strong in C++ program. Since errors first come up with C2864:'BCTdetectorMessenger::kInfinity' and C2864: 'BCTdetectorMessenger::kMinExitingNormalCosine' 
My guess is there might be errors when initializating with my DetectorMessenger. 
Here is the constructor of my BCTDetectorConstruction:
-------------------------------------------------------------
BCTTestDetectorConstruction::BCTTestDetectorConstruction()
  :worldSolid(0),fpWorldLogical(0),fpWorldPhysical(0)
  ,breastTarget(0),targetLogical(0),targetphysical(0)
  ,skinLayer(0),skinLogical(0),skinphysical(0)
  ,detectorSolid(0),detectorLogical(0),detectorphysical(0)
  ,cellSolid(0),cellLogical(0),cellphysical(0),cellParam(0)
  ,air(0),G4_Breast_Tissue(0),G4_Skin(0),G4_CsI(0),
{
// default parameter values about the breast tissue at 50% glandular rario
	breastdensity = 0.9819*g/cm3;
	HWR = 0.107;
	CWR = 0.401;
	PWR = 0.003;
	OWR = 0.464;
	NWR = 0.025;
	breastdia = 6.6*cm;
	breastheight = 6.6*cm;

// default parameter values about the skin with thikness 0.4cm
	skinthick = 0.4*cm;

// create commands for interactive definition of the geometry
  detectorMessenger = new BCTdetectorMessenger(this);
}
---------------------------------------------------------------------------
Does any experts here have any clue why it is?

Any help would be appreciated!

Linxi

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

1 None: Re: Dump while compiling detectorconstruction.cc   (Linxi Shi - 21 Apr, 2011)
 Add Message Add Message
to: "Dump while compiling detectorconstruction.cc"

 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 ]