void-packages/srcpkgs/libva-vdpau-driver/patches/fix-aarch64-musl.patch
Đoàn Trần Công Danh 861ac185a6 srcpkgs/l*: convert patches to -Np1
```sh
git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" |
while read template; do
	for p in ${template%/template}/patches/*; do
		sed -i '
			\,^[+-][+-][+-] /dev/null,b
			/^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b
			s,^[*][*][*] ,&a/,
			/^--- /{
				s,\(^--- \)\(./\)*,\1a/,
				s,[.][Oo][Rr][Ii][Gg]\([	/]\),\1,
				s/[.][Oo][Rr][Ii][Gg]$//
				s/[.]patched[.]\([^.]\)/.\1/
				h
			}
			/^+++ -/{
				g
				s/^--- a/+++ b/
				b
			}
			s,\(^+++ \)\(./\)*,\1b/,
		' "$p"
	done
	sed -i '/^patch_args=/d' $template
done
```
2021-06-20 13:17:29 +07:00

17 lines
385 B
Diff

utils.c: In function 'delay_usec':
utils.c:108:20: error: storage size of 'tv' isn't known
struct timeval tv;
^~
diff --git a/src/utils.c b/src/utils.c
index 1dac15c..3e2fa6a 100644
--- a/src/utils.c
+++ b/src/utils.c
@@ -21,6 +21,7 @@
#include "sysdeps.h"
#include "utils.h"
#include <time.h>
+#include <sys/time.h>
#include <errno.h>
#define DEBUG 1