1 |
commit: 82c03e208fc056e60ea1fda5dc7b797a488f404a |
2 |
Author: Tiziano Müller <dev-zero <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Nov 24 09:14:06 2018 +0000 |
4 |
Commit: Tiziano Müller <dev-zero <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Nov 24 09:15:20 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=82c03e20 |
7 |
|
8 |
app-emulation/libcacard: add patch to fix test failures |
9 |
|
10 |
backported from upstream |
11 |
|
12 |
Package-Manager: Portage-2.3.52, Repoman-2.3.12 |
13 |
Signed-off-by: Tiziano Müller <dev-zero <AT> gentoo.org> |
14 |
|
15 |
.../files/libcacard-2.6.0-simpletlv-test-fix.patch | 31 ++++++++++++++++++++++ |
16 |
app-emulation/libcacard/libcacard-2.6.0.ebuild | 4 +++ |
17 |
2 files changed, 35 insertions(+) |
18 |
|
19 |
diff --git a/app-emulation/libcacard/files/libcacard-2.6.0-simpletlv-test-fix.patch b/app-emulation/libcacard/files/libcacard-2.6.0-simpletlv-test-fix.patch |
20 |
new file mode 100644 |
21 |
index 00000000000..40e2a9d21e2 |
22 |
--- /dev/null |
23 |
+++ b/app-emulation/libcacard/files/libcacard-2.6.0-simpletlv-test-fix.patch |
24 |
@@ -0,0 +1,31 @@ |
25 |
+diff --git a/tests/simpletlv.c b/tests/simpletlv.c |
26 |
+index cd0cd69c4dfb504a52e3f7314e4a01657377eb68..9ddc5b999f73d56f35f85810479760b301330282 100644 |
27 |
+--- a/tests/simpletlv.c |
28 |
++++ b/tests/simpletlv.c |
29 |
+@@ -48,7 +48,7 @@ static void test_length_simple(void) |
30 |
+ |
31 |
+ static void test_length_nested(void) |
32 |
+ { |
33 |
+- size_t length = 0; |
34 |
++ int length = 0; |
35 |
+ unsigned char simple_value[] = "\x12\x14"; |
36 |
+ static struct simpletlv_member simple[1] = { |
37 |
+ {0x25, 2, {/*.value = simple_value*/}, SIMPLETLV_TYPE_LEAF} |
38 |
+@@ -102,7 +102,7 @@ static void test_length_skipped(void) |
39 |
+ static void test_encode_simple(void) |
40 |
+ { |
41 |
+ unsigned char *result = NULL; |
42 |
+- size_t result_len = 0; |
43 |
++ int result_len = 0; |
44 |
+ unsigned char simple_value[] = "\x10\x11"; |
45 |
+ unsigned char simple_encoded[] = "\x25\x02\x10\x11"; |
46 |
+ unsigned char long_value[256] = "Long data value"; |
47 |
+@@ -168,7 +168,7 @@ static void test_encode_simple(void) |
48 |
+ static void test_encode_nested(void) |
49 |
+ { |
50 |
+ unsigned char *result = NULL; |
51 |
+- size_t result_len = 0; |
52 |
++ int result_len = 0; |
53 |
+ unsigned char simple_value[] = "\x12\x14"; |
54 |
+ unsigned char encoded[] = "\x72\x04\x25\x02\x12\x14"; |
55 |
+ static struct simpletlv_member simple[1] = { |
56 |
|
57 |
diff --git a/app-emulation/libcacard/libcacard-2.6.0.ebuild b/app-emulation/libcacard/libcacard-2.6.0.ebuild |
58 |
index 39e02adda5a..a465af83fa1 100644 |
59 |
--- a/app-emulation/libcacard/libcacard-2.6.0.ebuild |
60 |
+++ b/app-emulation/libcacard/libcacard-2.6.0.ebuild |
61 |
@@ -18,6 +18,10 @@ RDEPEND=">=dev-libs/nss-3.13 |
62 |
DEPEND="${RDEPEND} |
63 |
virtual/pkgconfig" |
64 |
|
65 |
+PATCHES=( |
66 |
+ "${FILESDIR}/${P}-simpletlv-test-fix.patch" |
67 |
+ ) |
68 |
+ |
69 |
src_prepare() { |
70 |
default |