Message: Re: Current working directory Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Re: Current working directory 

Forum: (Graphical) User Interfaces
Re: Question Current working directory (Mojca Miklavec)
Date: 09 May, 2015
From: John Allison <John Allison>

There may be a more elegant way, but this works for me:

#include <cstdlib>
#include <unistd.h>
int main(int argc,char** argv)
{
  chdir("/Users/johna/Geant4_builds/dev/Debug-clang/examples/basic/B1");
  putenv("G4LEDATA=/Users/johna/Geant4_data/share/Geant4-10.1.0/data/G4EMLOW6.41");
  putenv("G4LEVELGAMMADATA=/Users/johna/Geant4_data/share/Geant4-10.1.0/data/PhotonEvaporation3.1");
  putenv("G4NEUTRONXSDATA=/Users/johna/Geant4_data/share/Geant4-10.1.0/data/G4NEUTRONXS1.4");
  putenv("G4SAIDXSDATA=/Users/johna/Geant4_data/share/Geant4-10.1.0/data/G4SAIDDATA1.1");
...

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

1 None: Re: Current working directory   (garnier - 22 Jun, 2015)
(_ Feedback: Re: Current working directory   (Mojca Miklavec - 23 Jun, 2015)
 Add Message Add Message
to: "Re: Current working directory"

 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 ]