Commit 0ba1bd72 authored by Bernhard Reutner-Fischer's avatar Bernhard Reutner-Fischer
Browse files

- bump version and make it behave of LFS is off

parent 4c82ddf0
Loading
Loading
Loading
Loading
+760 −0

File added.

Preview size limit exceeded, changes collapsed.

+21 −0
Original line number Diff line number Diff line
--- strace-4.5.15.orig/syscall.c	2007-01-29 17:23:38.000000000 +0100
+++ strace-4.5.15/syscall.c	2007-01-29 18:02:17.000000000 +0100
@@ -125,6 +125,18 @@
 #define TP TRACE_PROCESS
 #define TS TRACE_SIGNAL
 
+#ifndef HAVE_STATFS64
+/*
+ * Ugly hacks for systems that do not have LFS
+ */
+
+#define sys_truncate64  sys_truncate
+#define sys_ftruncate64 sys_ftruncate
+#define sys_getdents64  sys_getdents
+#define sys_statfs64    sys_statfs
+#define sys_fstatfs64   sys_fstatfs
+#endif
+
 static const struct sysent sysent0[] = {
 #include "syscallent.h"
 };
+53 −0
Original line number Diff line number Diff line
diff -dup strace-4.5.15.orig/acinclude.m4 strace-4.5.15/acinclude.m4
--- strace-4.5.15.orig/acinclude.m4	2004-04-14 04:21:01.000000000 +0200
+++ strace-4.5.15/acinclude.m4	2007-01-29 17:31:37.000000000 +0100
@@ -210,6 +210,26 @@ then
 fi
 ])
 
+dnl ### A macro to determine whether statfs64 is defined.
+AC_DEFUN([AC_STATFS64],
+[AC_MSG_CHECKING(for statfs64 in sys/(statfs|vfs).h)
+AC_CACHE_VAL(ac_cv_type_statfs64,
+[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#ifdef LINUX
+#include <linux/types.h>
+#include <sys/statfs.h>
+#else
+#include <sys/vfs.h>
+#endif]], [[struct statfs64 st;]])],[ac_cv_type_statfs64=yes],[ac_cv_type_statfs64=no])])
+AC_MSG_RESULT($ac_cv_type_statfs64)
+if test "$ac_cv_type_statfs64" = yes
+then
+	AC_DEFINE([HAVE_STATFS64], 1,
+[Define if statfs64 is available in sys/statfs.h or sys/vfs.h.])
+fi
+])
+
+
+
 dnl ### A macro to determine if off_t is a long long
 AC_DEFUN([AC_OFF_T_IS_LONG_LONG],
 [AC_MSG_CHECKING(for long long off_t)
diff -dup strace-4.5.15.orig/configure.ac strace-4.5.15/configure.ac
--- strace-4.5.15.orig/configure.ac	2007-01-11 12:37:55.000000000 +0100
+++ strace-4.5.15/configure.ac	2007-01-29 17:32:02.000000000 +0100
@@ -169,6 +169,7 @@ AC_CHECK_MEMBERS([struct stat.st_blksize
 		  struct stat.st_level,
 		  struct stat.st_rdev])
 AC_STAT64
+AC_STATFS64
 
 AC_TYPE_SIGNAL
 AC_TYPE_UID_T
diff -dup strace-4.5.15.orig/file.c strace-4.5.15/file.c
--- strace-4.5.15.orig/file.c	2007-01-15 21:25:52.000000000 +0100
+++ strace-4.5.15/file.c	2007-01-29 17:33:15.000000000 +0100
@@ -1635,7 +1635,7 @@ struct tcb *tcp;
 	return 0;
 }
 
-#ifdef LINUX
+#ifdef HAVE_STATFS64
 static void
 printstatfs64(tcp, addr)
 struct tcb *tcp;
+22 −0
Original line number Diff line number Diff line
--- strace-4.5.15.orig/configure.ac	2007-01-11 12:37:55.000000000 +0100
+++ strace-4.5.15/configure.ac	2007-01-29 17:38:26.000000000 +0100
@@ -91,14 +91,14 @@ hppa*|parisc*)
 	arch=hppa
 	AC_DEFINE([HPPA], 1, [Define for the HPPA architecture.])
 	;;
-sh)
-	arch=sh
-	AC_DEFINE([SH], 1, [Define for the SH architecture.])
-	;;
 sh64)
 	arch=sh64
 	AC_DEFINE([SH64], 1, [Define for the SH64 architecture.])
 	;;
+sh*)
+	arch=sh
+	AC_DEFINE([SH], 1, [Define for the SH architecture.])
+	;;
 x86?64*)
 	arch=x86_64
 	AC_DEFINE([X86_64], 1, [Define for the AMD x86-64 architecture.])
+0 −28
Original line number Diff line number Diff line
--- strace/configure
+++ strace/configure
@@ -1993,19 +1993,19 @@
 _ACEOF
 
 	;;
-sh)
-	arch=sh
+sh64)
+	arch=sh64
 
 cat >>confdefs.h <<\_ACEOF
-#define SH 1
+#define SH64 1
 _ACEOF
 
 	;;
-sh64)
-	arch=sh64
+sh*)
+	arch=sh
 
 cat >>confdefs.h <<\_ACEOF
-#define SH64 1
+#define SH 1
 _ACEOF
 
 	;;
Loading