X-Git-Url: http://git.sourceforge.jp/view?a=blobdiff_plain;ds=sidebyside;f=libf2c%2Ff2cext.c;h=56f9490c6f5191f0078e2d3ed0ce1953b2b88986;hb=905324d03694883c66ecc6e2a39f377a73561333;hp=d5ac815c9b4a4be62b1bbd08583574eae594c59f;hpb=a9fe81af3b8d02e1529b3f1f2a679b93cd9c36e1;p=pf3gnuchains%2Fgcc-fork.git diff --git a/libf2c/f2cext.c b/libf2c/f2cext.c index d5ac815c9b4..56f9490c6f5 100644 --- a/libf2c/f2cext.c +++ b/libf2c/f2cext.c @@ -16,9 +16,9 @@ License along with GNU Fortran; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ - +#include /* for j0 et al */ #include -typedef int (*sig_proc)(int); +typedef void *sig_proc; /* For now, this will have to do. */ #ifdef Labort int abort_ (void) { @@ -98,8 +98,8 @@ ftnint iargc_ (void) { #endif #ifdef Lsignal -ftnint signal_ (integer *sigp, sig_proc proc) { - extern ftnint G77_signal_0 (integer *sigp, sig_proc proc); +void *signal_ (integer *sigp, sig_proc proc) { + extern void *G77_signal_0 (integer *sigp, sig_proc proc); return G77_signal_0 (sigp, proc); } #endif @@ -203,10 +203,23 @@ void ctime_ (char *chtime, const ftnlen Lchtime, longint *xstime) { } #endif -#ifdef Ldate +#ifdef Ldate_y2kbuggy int date_ (char *buf, ftnlen buf_len) { - extern int G77_date_0 (char *buf, ftnlen buf_len); - return G77_date_0 (buf, buf_len); + /* Fail to link, so user sees attempt to invoke non-Y2K-compliant + routine. */ + extern int G77_date_y2kbuggy_0 (char *buf, ftnlen buf_len); + return G77_date_y2kbuggy_0 (buf, buf_len); +} +#endif + +#ifdef Ldate_y2kbug +int date_y2kbug__ (char *buf, ftnlen buf_len) { + /* If user wants to invoke the non-Y2K-compliant routine via + an `EXTERNAL' interface, avoiding the warning via g77's + `INTRINSIC' interface, force coding of "y2kbug" string in + user's program. */ + extern int G77_date_y2kbug_0 (char *buf, ftnlen buf_len); + return G77_date_y2kbug_0 (buf, buf_len); } #endif @@ -512,13 +525,6 @@ integer symlnk_ (const char *path1, const char *path2, const ftnlen Lpath1, cons } #endif -#ifdef Lsclock -int system_clock_ (integer *count, integer *count_rate, integer *count_max) { - extern int G77_system_clock_0 (integer *count, integer *count_rate, integer *count_max); - return G77_system_clock_0 (count, count_rate, count_max); -} -#endif - #ifdef Ltime longint time_ (void) { extern longint G77_time_0 (void); @@ -547,10 +553,23 @@ integer unlink_ (const char *str, const ftnlen Lstr) { } #endif -#ifdef Lvxtidt +#ifdef Lvxtidt_y2kbuggy int vxtidate_ (integer *m, integer *d, integer *y) { - extern int G77_vxtidate_0 (integer *m, integer *d, integer *y); - return G77_vxtidate_0 (m, d, y); + /* Fail to link, so user sees attempt to invoke non-Y2K-compliant + routine. */ + extern int G77_vxtidate_y2kbuggy_0 (integer *m, integer *d, integer *y); + return G77_vxtidate_y2kbuggy_0 (m, d, y); +} +#endif + +#ifdef Lvxtidt_y2kbug +int vxtidate_y2kbug__ (integer *m, integer *d, integer *y) { + /* If user wants to invoke the non-Y2K-compliant routine via + an `EXTERNAL' interface, avoiding the warning via g77's + `INTRINSIC' interface, force coding of "y2kbug" string in + user's program. */ + extern int G77_vxtidate_y2kbug_0 (integer *m, integer *d, integer *y); + return G77_vxtidate_y2kbug_0 (m, d, y); } #endif