Gentoo Archives: gentoo-commits

From: "Anthony G. Basile" <blueness@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/musl:master commit in: x11-libs/libva-vdpau-driver/files/, x11-libs/libva-vdpau-driver/
Date: Wed, 25 Dec 2019 19:24:34
Message-Id: 1577301856.67277b88c7b5fa08205cffa49b10472b78a10137.blueness@gentoo
1 commit: 67277b88c7b5fa08205cffa49b10472b78a10137
2 Author: g3ngr33n <gengreen <AT> tutanota <DOT> com>
3 AuthorDate: Thu Dec 19 15:32:16 2019 +0000
4 Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
5 CommitDate: Wed Dec 25 19:24:16 2019 +0000
6 URL: https://gitweb.gentoo.org/proj/musl.git/commit/?id=67277b88
7
8 x11-libs/libva-vdpau-driver: Fix ebuild
9
10 Fix incorrect patch files
11
12 Package-Manager: Portage-2.3.79, Repoman-2.3.16
13 Signed-off-by: Anthony G. Basile <blueness <AT> gentoo.org>
14
15 .../files/0001-fix-headers-musl.patch | 10 ---------
16 ...au-driver-0.7.4-include-linux-videodev2.h.patch | 25 ++++++++++++++++++++++
17 .../libva-vdpau-driver-0.7.4-libvdpau-0.8.patch | 4 ++--
18 ...bva-vdpau-driver-0.7.4-missing-sys_time_h.patch | 5 ++---
19 .../libva-vdpau-driver-0.7.4-sigfpe-crash.patch | 21 ++++++++++++++++++
20 .../libva-vdpau-driver-0.7.4-r5.ebuild | 3 ++-
21 6 files changed, 52 insertions(+), 16 deletions(-)
22
23 diff --git a/x11-libs/libva-vdpau-driver/files/0001-fix-headers-musl.patch b/x11-libs/libva-vdpau-driver/files/0001-fix-headers-musl.patch
24 deleted file mode 100644
25 index 2529fb2..0000000
26 --- a/x11-libs/libva-vdpau-driver/files/0001-fix-headers-musl.patch
27 +++ /dev/null
28 @@ -1,10 +0,0 @@
29 ---- a/src/utils.c
30 -+++ b/src/utils.c
31 -@@ -21,6 +21,7 @@
32 - #include "sysdeps.h"
33 - #include "utils.h"
34 - #include <time.h>
35 -+#include <sys/time.h>
36 - #include <errno.h>
37 -
38 - #define DEBUG 1
39
40 diff --git a/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-include-linux-videodev2.h.patch b/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-include-linux-videodev2.h.patch
41 new file mode 100644
42 index 0000000..0d92074
43 --- /dev/null
44 +++ b/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-include-linux-videodev2.h.patch
45 @@ -0,0 +1,25 @@
46 +https://bugs.gentoo.org/689530
47 +
48 +libva commit 93c52a17b8d2 ("va_backend: remove unneeded
49 +linux/videodev2.h include") removed an include that provided the
50 +prototype of v4l2_format among other v4l2_* structs.
51 +
52 +Without this or a forward declaration of 'struct v4l2_format', the prototype
53 +and definition of vdpau_CreateSurfaceFromV4L2Buf() (which has a 'struct
54 +v4l2_format *' parameter) are seen as conflicting.
55 +
56 +Just include the removed header where we need it.
57 +
58 +diff --git a/src/vdpau_driver.h b/src/vdpau_driver.h
59 +index 6286d16..54d37fb 100644
60 +--- a/src/vdpau_driver.h
61 ++++ b/src/vdpau_driver.h
62 +@@ -21,6 +21,8 @@
63 + #ifndef VDPAU_DRIVER_H
64 + #define VDPAU_DRIVER_H
65 +
66 ++#include <linux/videodev2.h>
67 ++
68 + #include <va/va_backend.h>
69 + #include "vaapi_compat.h"
70 + #include "vdpau_gate.h"
71
72 diff --git a/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-libvdpau-0.8.patch b/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-libvdpau-0.8.patch
73 index 6d6d47a..412e9c3 100644
74 --- a/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-libvdpau-0.8.patch
75 +++ b/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-libvdpau-0.8.patch
76 @@ -1,7 +1,7 @@
77 http://bugs.gentoo.org/517778
78
79 ---- src/vdpau_decode.c
80 -+++ src/vdpau_decode.c
81 +--- a/src/vdpau_decode.c
82 ++++ b/src/vdpau_decode.c
83 @@ -1289,7 +1289,7 @@
84 driver_data,
85 obj_context->vdp_decoder,
86
87 diff --git a/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-missing-sys_time_h.patch b/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-missing-sys_time_h.patch
88 index d37784a..2529fb2 100644
89 --- a/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-missing-sys_time_h.patch
90 +++ b/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-missing-sys_time_h.patch
91 @@ -1,6 +1,5 @@
92 -diff -Naur libva-vdpau-driver-0.7.4.orig/src/utils.c libva-vdpau-driver-0.7.4/src/utils.c
93 ---- libva-vdpau-driver-0.7.4.orig/src/utils.c 2016-05-27 19:07:51.001006381 +0000
94 -+++ libva-vdpau-driver-0.7.4/src/utils.c 2016-05-27 18:23:39.534238312 +0000
95 +--- a/src/utils.c
96 ++++ b/src/utils.c
97 @@ -21,6 +21,7 @@
98 #include "sysdeps.h"
99 #include "utils.h"
100
101 diff --git a/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-sigfpe-crash.patch b/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-sigfpe-crash.patch
102 new file mode 100644
103 index 0000000..e2fe02c
104 --- /dev/null
105 +++ b/x11-libs/libva-vdpau-driver/files/libva-vdpau-driver-0.7.4-sigfpe-crash.patch
106 @@ -0,0 +1,21 @@
107 +Description: Fix a crash if a heap is destroyed before being initialized
108 +Author: Sebastian Ramacher <sramacher@××××××.org>
109 +Bug: https://bugs.freedesktop.org/show_bug.cgi?id=58836
110 +Bug-Debian: http://bugs.debian.org/748294
111 +Last-Update: 2014-06-02
112 +
113 +--- vdpau-video-0.7.4.orig/src/object_heap.c
114 ++++ vdpau-video-0.7.4/src/object_heap.c
115 +@@ -272,8 +272,10 @@ object_heap_destroy(object_heap_p heap)
116 + ASSERT(obj->next_free != ALLOCATED);
117 + }
118 +
119 +- for (i = 0; i < heap->heap_size / heap->heap_increment; i++) {
120 +- free(heap->bucket[i]);
121 ++ if (heap->bucket) {
122 ++ for (i = 0; i < heap->heap_size / heap->heap_increment; i++) {
123 ++ free(heap->bucket[i]);
124 ++ }
125 + }
126 +
127 + pthread_mutex_destroy(&heap->mutex);
128
129 diff --git a/x11-libs/libva-vdpau-driver/libva-vdpau-driver-0.7.4-r5.ebuild b/x11-libs/libva-vdpau-driver/libva-vdpau-driver-0.7.4-r5.ebuild
130 index 23e613e..15a4cc7 100644
131 --- a/x11-libs/libva-vdpau-driver/libva-vdpau-driver-0.7.4-r5.ebuild
132 +++ b/x11-libs/libva-vdpau-driver/libva-vdpau-driver-0.7.4-r5.ebuild
133 @@ -30,7 +30,8 @@ PATCHES=(
134 "${FILESDIR}"/${P}-libvdpau-0.8.patch
135 "${FILESDIR}"/${P}-sigfpe-crash.patch
136 "${FILESDIR}"/${P}-include-linux-videodev2.h.patch
137 - "${FILESDIR}"/0001-fix-headers-musl.patch
138 + "${FILESDIR}"/${P}-missing-sys_time_h.patch
139 +
140 )
141
142 src_prepare() {