summaryrefslogtreecommitdiff
path: root/staging/clamav/gcc47.patch
blob: 17fc924d966ef5c864062d61bb4465b84f267c26 (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
From 8b6757e866d1480c997d5ae497e0512000d82b35 Mon Sep 17 00:00:00 2001
From: =?utf8?q?T=C3=B6r=C3=B6k=20Edvin?= <edwin@clamav.net>
Date: Mon, 14 May 2012 20:13:21 +0300
Subject: [PATCH 1/2] Fix build with gcc-4.7

---
 .../c++/llvm/lib/ExecutionEngine/JIT/Intercept.cpp |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/libclamav/c++/llvm/lib/ExecutionEngine/JIT/Intercept.cpp b/libclamav/c++/llvm/lib/ExecutionEngine/JIT/Intercept.cpp
index 274f816..a4e7eee 100644
--- a/libclamav/c++/llvm/lib/ExecutionEngine/JIT/Intercept.cpp
+++ b/libclamav/c++/llvm/lib/ExecutionEngine/JIT/Intercept.cpp
@@ -19,6 +19,7 @@
 #include "llvm/Support/ErrorHandling.h"
 #include "llvm/System/DynamicLibrary.h"
 #include "llvm/Config/config.h"
+#include <unistd.h>
 using namespace llvm;
 
 // AtExitHandlers - List of functions to call when the program exits,
-- 
1.7.2.3


From c609c8ea0409b2882aa3e6ef4dc48c210cf2d292 Mon Sep 17 00:00:00 2001
From: =?utf8?q?T=C3=B6r=C3=B6k=20Edvin?= <edwin@clamav.net>
Date: Tue, 15 May 2012 23:36:29 +0300
Subject: [PATCH 2/2] wrap unistd in ifdef

---
 .../c++/llvm/lib/ExecutionEngine/JIT/Intercept.cpp |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/libclamav/c++/llvm/lib/ExecutionEngine/JIT/Intercept.cpp b/libclamav/c++/llvm/lib/ExecutionEngine/JIT/Intercept.cpp
index a4e7eee..c1cd5e8 100644
--- a/libclamav/c++/llvm/lib/ExecutionEngine/JIT/Intercept.cpp
+++ b/libclamav/c++/llvm/lib/ExecutionEngine/JIT/Intercept.cpp
@@ -19,7 +19,9 @@
 #include "llvm/Support/ErrorHandling.h"
 #include "llvm/System/DynamicLibrary.h"
 #include "llvm/Config/config.h"
+#ifdef HAVE_UNISTD_H
 #include <unistd.h>
+#endif
 using namespace llvm;
 
 // AtExitHandlers - List of functions to call when the program exits,
-- 
1.7.2.3