#include <sys/param.h>
#include <sys/mount.h>
#include <sys/stat.h>
+#endif
+
+#if HAVE_LONG_LONG_OFF_T
+/*
+ * Ugly hacks for systems that have typedef long long off_t
+ */
#define stat64 stat
#define HAVE_STAT64 1 /* Ugly hack */
+
+#define sys_stat64 sys_stat
+#define sys_fstat64 sys_fstat
+#define sys_lstat64 sys_lstat
+#define sys_lseek64 sys_lseek
+#define sys_truncate64 sys_truncate
+#define sys_ftruncate64 sys_ftruncate
#endif
#ifdef MAJOR_IN_SYSMACROS
{ 0, NULL },
};
-#ifndef FREEBSD
+#ifndef HAVE_LONG_LONG_OFF_T
int
sys_lseek(tcp)
struct tcb *tcp;
}
#endif
-#if _LFS64_LARGEFILE || FREEBSD
+#if _LFS64_LARGEFILE || HAVE_LONG_LONG_OFF_T
int
sys_lseek64 (tcp)
struct tcb *tcp;
if (entering(tcp)) {
long long offset;
ALIGN64 (tcp, 1); /* FreeBSD aligns off_t args */
- offset = get64(tcp->u_arg [1], tcp->u_arg[2]);
+ offset = LONG_LONG(tcp->u_arg [1], tcp->u_arg[2]);
if (tcp->u_arg[3] == SEEK_SET)
tprintf("%ld, %llu, ", tcp->u_arg[0], offset);
else
}
#endif
-#ifndef FREEBSD
+#ifndef HAVE_LONG_LONG_OFF_T
int
sys_truncate(tcp)
struct tcb *tcp;
}
#endif
-#if _LFS64_LARGEFILE || FREEBSD
+#if _LFS64_LARGEFILE || HAVE_LONG_LONG_OFF_T
int
sys_truncate64(tcp)
struct tcb *tcp;
if (entering(tcp)) {
ALIGN64 (tcp, 1);
printpath(tcp, tcp->u_arg[0]);
- tprintf(", %llu", get64(tcp->u_arg[1],tcp->u_arg[2]));
+ tprintf(", %llu", LONG_LONG(tcp->u_arg[1],tcp->u_arg[2]));
}
return 0;
}
#endif
-#ifndef FREEBSD
+#ifndef HAVE_LONG_LONG_OFF_T
int
sys_ftruncate(tcp)
struct tcb *tcp;
}
#endif
-#if _LFS64_LARGEFILE || FREEBSD
+#if _LFS64_LARGEFILE || HAVE_LONG_LONG_OFF_T
int
sys_ftruncate64(tcp)
struct tcb *tcp;
if (entering(tcp)) {
ALIGN64 (tcp, 1);
tprintf("%ld, %llu", tcp->u_arg[0],
- get64(tcp->u_arg[1] ,tcp->u_arg[2]));
+ LONG_LONG(tcp->u_arg[1] ,tcp->u_arg[2]));
}
return 0;
}
}
#endif
-#ifndef FREEBSD
+#ifndef HAVE_LONG_LONG_OFF_T
static void
realprintstat(tcp, statbuf)
struct tcb *tcp;
realprintstat(tcp, &statbuf);
}
-#endif /* !FREEBSD */
+#endif /* !HAVE_LONG_LONG_OFF_T */
#ifdef HAVE_STAT64
static void
}
#endif /* linux && !IA64 */
-#ifndef FREEBSD
+#ifndef HAVE_LONG_LONG_OFF_T
int
sys_stat(tcp)
struct tcb *tcp;
# endif /* !IA64 */
#endif /* linux */
-#ifndef FREEBSD
+#ifndef HAVE_LONG_LONG_OFF_T
int
sys_fstat(tcp)
struct tcb *tcp;
# endif /* !IA64 */
#endif
-#ifndef FREEBSD
+#ifndef HAVE_LONG_LONG_OFF_T
int
sys_lstat(tcp)
struct tcb *tcp;