1998-02-01 02:37:08 +01:00
|
|
|
/* STARTUP PROCEDURE FOR UNIX FORTRAN PROGRAMS */
|
|
|
|
|
|
|
|
#include <stdio.h>
|
|
|
|
#include "signal1.h"
|
|
|
|
|
|
|
|
#include <stdlib.h>
|
|
|
|
|
2002-06-01 14:38:32 +02:00
|
|
|
extern void f_exit (void);
|
1998-02-01 02:37:08 +01:00
|
|
|
#ifndef NO_ONEXIT
|
|
|
|
#define ONEXIT atexit
|
2002-06-01 14:38:32 +02:00
|
|
|
extern int atexit (void (*)(void));
|
1998-02-01 02:37:08 +01:00
|
|
|
#endif
|
|
|
|
|
2002-06-01 14:38:32 +02:00
|
|
|
extern void f_init (void);
|
|
|
|
extern int MAIN__ (void);
|
2002-06-04 04:25:48 +02:00
|
|
|
extern void f_setarg (int, char **);
|
|
|
|
extern void f_setsig (void);
|
1998-02-01 02:37:08 +01:00
|
|
|
|
main.c (main): Avoid implicit int.
* libF77/main.c (main): Avoid implicit int.
* libI77/dfe.c (y_rsk, y_getc, c_dfe): Likewise.
* libI77/due.c (c_due): Likewise.
* libI77/err.c (f__canseek, f__nowreading, f__nowwriting):
Likewise.
* libI77/fmt.c (op_gen, ne_d, e_d, pars_f, type_f, en_fio):
Likewise.
* libI77/iio.c (z_getc, z_rnew, c_si, z_wnew): Likewise.
* libI77/lread.c (t_getc, c_le, l_read): Likewise.
* libI77/lwrite.c (l_write): Likewise.
* libI77/open.c (fk_open): Likewise.
* libI77/rdfmt.c (rd_ed, rd_ned): Likewise.
* libI77/rsfe.c (xrd_SL, x_getc, x_endp, x_rev): Likewise.
* libI77/rsne.c (t_getc, x_rsne): Likewise.
* libI77/sfe.c (c_sfe): Likewise.
* libI77/sue.c (c_sue): Likewise.
* libI77/uio.c (do_us): Likewise.
* libI77/wref.c (wrt_E, wrt_F): Likewise.
* libI77/wrtfmt.c (wrt_L, w_ed, w_ned): Likewise.
From-SVN: r54169
2002-06-02 15:01:12 +02:00
|
|
|
int
|
2002-06-01 14:38:32 +02:00
|
|
|
main (int argc, char **argv)
|
1998-02-01 02:37:08 +01:00
|
|
|
{
|
2002-06-01 14:38:32 +02:00
|
|
|
f_setarg (argc, argv);
|
|
|
|
f_setsig ();
|
|
|
|
f_init ();
|
1998-02-01 02:37:08 +01:00
|
|
|
#ifndef NO_ONEXIT
|
2002-06-01 14:38:32 +02:00
|
|
|
ONEXIT (f_exit);
|
1998-02-01 02:37:08 +01:00
|
|
|
#endif
|
2002-06-01 14:38:32 +02:00
|
|
|
MAIN__ ();
|
1998-02-01 02:37:08 +01:00
|
|
|
#ifdef NO_ONEXIT
|
2002-06-01 14:38:32 +02:00
|
|
|
f_exit ();
|
1998-02-01 02:37:08 +01:00
|
|
|
#endif
|
2002-06-01 14:38:32 +02:00
|
|
|
exit (0); /* exit(0) rather than return(0) to bypass Cray bug */
|
|
|
|
return 0; /* For compilers that complain of missing return values; */
|
|
|
|
/* others will complain that this is unreachable code. */
|
1998-02-01 02:37:08 +01:00
|
|
|
}
|