Mail Archives: djgpp/2001/06/08/15:41:17
Eli Zaretskii wrote":
>
> Does any code outside this block data file reference the
> variable killcode_mup__ ? If not, the linker will not know
> your program needs it.
The following FORTRAN routine assigns text value to CHAR80
string variable. N8 is the number of register (or array) to
assign to CHAR80.
The blkcom.ins pass auxiliary variables, as MONCAS, etc,.
The routine reads a direct access file if LUNTEX > 0, ans
assign the string variable if LUNTEX < 0
Other tests are done if other conditions are satisfied, but
this are not of importance for the problem in hands.
SUBROUTINE READ11 ( N8, CHAR80 )
IMPLICIT REAL*8 (A-H, O-Z), INTEGER*4 (I-N)
INCLUDE 'blkcom.ins'
EQUIVALENCE ( MONCAS(138), LUNTEX )
EQUIVALENCE ( MONCAS(145), KOMPAR )
CHARACTER*80 CHAR80, dmup
common /killcode_mup/ dmup(7653)
DATA KDATE / -7722 /
IF ( LUNTEX .LE. 0 ) THEN
IF ( KDATE .NE. -7722 ) GO TO 2864
IF ( KOMPAR .LT. 4 ) GO TO 2864
KDATE = 0
DO 5942 J=1, 9999
K = INDEX ( DMUP(J),
1 'Consult the 860-page ATP Rule Book' )
IF ( K .EQ. 0 ) GO TO 5942
DMUP(J+1)(11:31) = 'A. Program is no ol'
DMUP(J+1)(32:80) = 'der than March, 1996.'
GO TO 2864
5942 CONTINUE
STOP 'Halt in READ11. No March, 1996.'
2864 CHAR80 = DMUP(N8)
ELSE
READ (UNIT=LUNTEX, REC=N8) CHAR80
CHAR80=DMUP(N8)
ENDIF
RETURN
END
> It figures: when you call a function, the linker _must_ link
> it into the program.
>
I don't know if the extra '_' as added by f2c are or not
cause of some trouble.
Regards,
OPH. 2001-6-8 16:38
Ing. Orlando P. Hevia
heviaop AT ssdfe DOT com DOT ar
Santa Fe-Argentina
- Raw text -