summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2016-11-15 02:50:51 +0000
committerMartin Jansa <Martin.Jansa@gmail.com>2016-11-26 01:07:04 +0100
commit856ac210ab223da1adb6e8a30298a10f1d05d61a (patch)
treec7757147ff3938bce83abda6478d7a02e9b7be4b
parentfa8f71b4b15ba1cce7634bcf354a440766824810 (diff)
downloadmeta-openembedded-856ac210ab223da1adb6e8a30298a10f1d05d61a.tar.gz
md5deep: Fix build with clang
Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r--meta-oe/recipes-extended/md5deep/files/0001-Fix-errors-found-by-clang.patch32
-rw-r--r--meta-oe/recipes-extended/md5deep/md5deep_4.4.bb1
2 files changed, 33 insertions, 0 deletions
diff --git a/meta-oe/recipes-extended/md5deep/files/0001-Fix-errors-found-by-clang.patch b/meta-oe/recipes-extended/md5deep/files/0001-Fix-errors-found-by-clang.patch
new file mode 100644
index 000000000..cc7cdc336
--- /dev/null
+++ b/meta-oe/recipes-extended/md5deep/files/0001-Fix-errors-found-by-clang.patch
@@ -0,0 +1,32 @@
1From 6ef69a26126ee4e69a25392fd456b8a66c51dffd Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Tue, 15 Nov 2016 02:46:55 +0000
4Subject: [PATCH] Fix errors found by clang
5
6Fixes errors like
7
8../../git/src/hash.cpp:282:19: error: ordered comparison between pointer and zero ('const unsigned char *' and 'int')
9 if(fdht->base>0){
10 ~~~~~~~~~~^~
11
12Signed-off-by: Khem Raj <raj.khem@gmail.com>
13---
14 src/hash.cpp | 2 +-
15 1 file changed, 1 insertion(+), 1 deletion(-)
16
17diff --git a/src/hash.cpp b/src/hash.cpp
18index 4216157..52f419b 100644
19--- a/src/hash.cpp
20+++ b/src/hash.cpp
21@@ -279,7 +279,7 @@ void file_data_hasher_t::hash()
22 MAP_FILE|
23 #endif
24 MAP_SHARED,fd,0);
25- if(fdht->base>0){
26+ if(fdht->base != (void *) -1){
27 /* mmap is successful, so set the bounds.
28 * if it is not successful, we default to reading the fd
29 */
30--
311.9.1
32
diff --git a/meta-oe/recipes-extended/md5deep/md5deep_4.4.bb b/meta-oe/recipes-extended/md5deep/md5deep_4.4.bb
index 960e00f61..bb30abedd 100644
--- a/meta-oe/recipes-extended/md5deep/md5deep_4.4.bb
+++ b/meta-oe/recipes-extended/md5deep/md5deep_4.4.bb
@@ -9,6 +9,7 @@ SRCREV = "cd2ed7416685a5e83eb10bb659d6e9bec01244ae"
9 9
10SRC_URI = "git://github.com/jessek/hashdeep.git \ 10SRC_URI = "git://github.com/jessek/hashdeep.git \
11 file://wrong-variable-expansion.patch \ 11 file://wrong-variable-expansion.patch \
12 file://0001-Fix-errors-found-by-clang.patch \
12 " 13 "
13 14
14S = "${WORKDIR}/git" 15S = "${WORKDIR}/git"