Segmentation fault with example B1

Hello!
I try to install Giant 4 on Mac, but every time I try to run B1 example, I get a segmentation fault error. Geant and example were installed without problems (except a problem with geant4_set_and_check_package_variable).

Available UI session types: [ Qt, tcsh, csh ]
QObject::connect: No such signal QTabWidget::tabCloseRequested(G4int)
QObject::connect: No such signal QTabWidget::currentChanged(G4int)
QObject::connect: No such signal QTabWidget::currentChanged(G4int)
QObject::connect: No such signal QComboBox::activated(G4int)

**************************************************************
 Geant4 version Name: geant4-11-01-patch-01 [MT]   (10-February-2023)
  << in Multi-threaded mode >> 
                       Copyright : Geant4 Collaboration
                      References : NIM A 506 (2003), 250-303
                                 : IEEE-TNS 53 (2006), 270-278
                                 : NIM A 835 (2016), 186-225
                             WWW : http://geant4.org/
**************************************************************

<<< Reference Physics List QBBC 
Visualization Manager instantiating with verbosity "warnings (3)"...
Visualization Manager initialising...
Registering graphics systems...

You have successfully registered the following graphics systems.
Registered graphics systems are:
  ASCIITree (ATree)
  DAWNFILE (DAWNFILE)
  G4HepRepFile (HepRepFile)
  RayTracer (RayTracer)
  VRML2FILE (VRML2FILE)
  gMocrenFile (gMocrenFile)
  TOOLSSG_OFFSCREEN (TSG_OFFSCREEN)
  TOOLSSG_OFFSCREEN (TSG_OFFSCREEN, TSG_FILE)
  OpenGLImmediateQt (OGLIQt, OGLI)
  OpenGLStoredQt (OGLSQt, OGL, OGLS)
  Qt3D (Qt3D)
  TOOLSSG_QT_GLES (TSG_QT_GLES, TSGQt, TSG)

Registering model factories...

You have successfully registered the following model factories.
Registered model factories:
  generic
  drawByAttribute
  drawByCharge
  drawByOriginVolume
  drawByParticleID
  drawByEncounteredVolume

Registered models:
  None

Registered filter factories:
  attributeFilter
  chargeFilter
  originVolumeFilter
  particleFilter
  encounteredVolumeFilter

Registered filters:
  None

You have successfully registered the following user vis actions.
Run Duration User Vis Actions: none
End of Event User Vis Actions: none
End of Run User Vis Actions: none

Some /vis commands (optionally) take a string to specify colour.
"/vis/list" to see available colours.
/control/saveHistory
/run/verbose 2
#
# Change the default number of threads (in multi-threaded mode)
#/run/numberOfThreads 4
#
# Initialize kernel
/run/initialize

==========================================================================================
zsh: segmentation fault  ./exampleB1

What should I do to fix it?
Thanks!

Geant4 Version: 4.11.01
Operating System: MacOS 13.5.2
Compiler/Version: clang 15.0.0
CMake Version: 3.27.6


What options did you build Geant4 with, and which Qt version and install are you using?

The raw seg fault doesn’t give much info, so I would suggest:

  1. Build the example with the Debug build mode, i.e. configure exampleB1 with cmake -DCMAKE_BUILD_TYPE=Debug <otherargs> and then rebuild

  2. Run the example inside the lldb debugger to get more info on the source of the segfault, e.g.

    $ lldb ./exampleB1
    ...
    > run
    

    You’ll need to enter your password and have admin access on the machine the first time you run this.

    When the segfault occurs, use bt to get a backtrace - which you can check and/or post here.

Thank you! I built an example with debug info and found that the data was installed incorrectly. I copied the data dir manually and now it works!

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.