summaryrefslogtreecommitdiff
path: root/patches/ltrace/0.5.3/120-debian-ltrace_0.5.3-2.patch
blob: 483c7433a018ab64ee7470b54999c4348ac5ea88 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
Debian patch courtesy of the Debian ltrace maintainer Juan Cespedes <cespedes@debian.org>

--- ltrace-0.5.3.orig/sysdeps/linux-gnu/breakpoint.c
+++ ltrace-0.5.3/sysdeps/linux-gnu/breakpoint.c
@@ -6,8 +6,6 @@
 #include "common.h"
 #include "arch.h"
 
-static unsigned char break_insn[] = BREAKPOINT_VALUE;
-
 #ifdef ARCH_HAVE_ENABLE_BREAKPOINT
 extern void arch_enable_breakpoint(pid_t, Breakpoint *);
 void
@@ -20,6 +18,9 @@
 	arch_enable_breakpoint(pid, sbp);
 }
 #else
+
+static unsigned char break_insn[] = BREAKPOINT_VALUE;
+
 void
 enable_breakpoint(pid_t pid, Breakpoint *sbp) {
 	unsigned int i, j;
--- ltrace-0.5.3.orig/sysdeps/linux-gnu/arm/breakpoint.c
+++ ltrace-0.5.3/sysdeps/linux-gnu/arm/breakpoint.c
@@ -24,10 +24,7 @@
 
 #include <sys/ptrace.h>
 #include "config.h"
-#include "arch.h"
-#include "options.h"
-#include "output.h"
-#include "debug.h"
+#include "common.h"
 
 void
 arch_enable_breakpoint(pid_t pid, Breakpoint *sbp) {
@@ -59,8 +56,6 @@
 void
 arch_disable_breakpoint(pid_t pid, const Breakpoint *sbp) {
 	unsigned int i, j;
-	const unsigned char break_insn[] = BREAKPOINT_VALUE;
-	const unsigned char thumb_break_insn[] = THUMB_BREAKPOINT_VALUE;
 
 	debug(1, "arch_disable_breakpoint(%d,%p)", pid, sbp->addr);
 
--- ltrace-0.5.3.orig/sysdeps/linux-gnu/ia64/plt.c
+++ ltrace-0.5.3/sysdeps/linux-gnu/ia64/plt.c
@@ -1,4 +1,5 @@
 #include <gelf.h>
+#include <sys/ptrace.h>
 #include "common.h"
 
 /* A bundle is 128 bits */
--- ltrace-0.5.3.orig/sysdeps/linux-gnu/ia64/breakpoint.c
+++ ltrace-0.5.3/sysdeps/linux-gnu/ia64/breakpoint.c
@@ -6,10 +6,7 @@
 
 #include <sys/ptrace.h>
 #include <string.h>
-#include "arch.h"
-#include "options.h"
-#include "output.h"
-#include "debug.h"
+#include "common.h"
 
 static long long
 extract_bit_field(char *bundle, int from, int len) {
--- ltrace-0.5.3.orig/sysdeps/linux-gnu/ia64/regs.c
+++ ltrace-0.5.3/sysdeps/linux-gnu/ia64/regs.c
@@ -7,7 +7,6 @@
 #include <asm/rse.h>
 
 #include <stddef.h>
-#include "debug.h"
 #include "common.h"
 
 void *