This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
amigaos4: use afstat for fstat
authorAndy Broad <andy@broad.ology.org.uk>
Thu, 20 Aug 2015 00:03:03 +0000 (20:03 -0400)
committerJarkko Hietaniemi <jhi@iki.fi>
Sat, 5 Sep 2015 15:12:46 +0000 (11:12 -0400)
unixish.h

index 2f0d8f3..0c7de45 100644 (file)
--- a/unixish.h
+++ b/unixish.h
 #define fwrite1 fwrite
 
 #define Stat(fname,bufptr) stat((fname),(bufptr))
-#define Fstat(fd,bufptr)   fstat((fd),(bufptr))
+
+#if defined(__amigaos4__)
+int afstat(int fd, struct stat *statb);
+#    define Fstat(fd,bufptr) afstat((fd),(bufptr))
+#endif
+
+#ifndef Fstat
+#    define Fstat(fd,bufptr)   fstat((fd),(bufptr))
+#endif
+
 #define Fflush(fp)         fflush(fp)
 #define Mkdir(path,mode)   mkdir((path),(mode))