Message: Re: Compile B1 with debug Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Feedback Re: Compile B1 with debug 

Forum: Documentation and Examples
Re: None Compile B1 with debug (Tim Fulcher)
Date: 07 Nov, 2017
From: Michael H. Kelsey <Michael H. Kelsey>

On Sun, 05 Nov 2017 18:19:40 GMT, Tim Fulcher wrote:
> I've extended the B1 example so that it counts dose in multiple volumes
> simultaneously but it's raising a error and one of my volumes returns an
> obscenely large value. I've looked at my code and it doesn't seem to be
> me so I'll have to use a debugger to track down the problem.
> 
> I've had a read though of the installation guide (
> https://geant4.web.cern.ch/geant4/UserDocumentation/UsersGuides/InstallationGuide/html/ch03s02.html
> ) but this guide isn't explicit about where I set the G4DEBUG flag.
> Could you tell me where? Is it in cmakelists? Cmakefiles or makefile or
> cmake_install.make?

That flag is set as part of the "build type." From the command line, you can write

  cmake -DCMAKE_BUILD_TYPE=<type> .....

For debugging, use <type> Debug or RelWithDebugInfo.

You will want to do this for your Geant4 build, not just the example, because chances are you're going to need (at some point :-) to be able to step through or inspect toolkit code as you go.

  -- Michael Kelsey

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

1 None: Re: Compile B1 with debug   (Tim Fulcher - 16 Nov, 2017)
 Add Message Add Message
to: "Re: Compile B1 with debug"

 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 ]