added cdb stuff
[u/mrichter/AliRoot.git] / PYTHIA6 / openDecayTable.F
CommitLineData
a646c34a 1#ifdef __APPLE__
2#define stop CALL EXIT !
3#define STOP CALL EXIT !
4#endif
e2dc8e65 5 SUBROUTINE OPENDECAYTABLE(LUN)
6 LOGICAL OPENED,EXISTS
7 LOGICAL LRMSCH, LRD1O2, LTRASP
8 INTEGER LUN
a39be50e 9 CHARACTER*1000 FILNAM
10 CHARACTER*1000 CHROOT
e2dc8e65 11 CHROOT=' '
12 CALL GETENVF('ALICE_ROOT',CHROOT)
13 LNROOT = LNBLNK(CHROOT)
14 IF(LNROOT.LE.0) THEN
15 FILNAM='decaytable.dat'
16 ELSE
17 FILNAM=CHROOT(1:LNROOT)//'/data/decaytable.dat'
18 ENDIF
19 INQUIRE(FILE=FILNAM,EXIST=EXISTS)
20 IF(.NOT.EXISTS) THEN
21 PRINT*,'***********************************'
22 PRINT*,'* OpenDecayTable *'
23 PRINT*,'* --------------- *'
24 PRINT*,'* File DECAYTABLE.DAT not found *'
25 PRINT*,'* Program STOP *'
26 PRINT*,'* Check ALICE_ROOT environment *'
27 PRINT*,'* variable *'
28 PRINT*,'***********************************'
29 STOP
30 ENDIF
31 OPEN(LUN,FILE=FILNAM,STATUS='OLD')
e2dc8e65 32 RETURN
33 END
4b9d5593 34 SUBROUTINE CLOSEDECAYTABLE(LUN)
35 CLOSE(LUN)
36 RETURN
37 END