libv4l: fix libdvbv5 musl compile
PATCH 1/1 libv4l: fix libdvbv5 musl compile
Add optional copy of TEMP_FAILURE_RETRY macro.
Fixes [1]:
../../lib/libdvbv5/.libs/libdvbv5.so: undefined reference to `TEMP_FAILURE_RETRY'
[1] http://autobuild.buildroot.net/results/7aea0cbb9e7fe7d9919c9be04ba4567ddcf4e15e
--- ...d-optional-copy-of-TEMP_FAILURE_RETRY-mac.patch | 38 ++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 package/libv4l/0003-libdvbv5-add-optional-copy-of-TEMP_FAILURE_RETRY-mac.patch
package/libv4l/0003-libdvbv5-add-optional-copy-of-TEMP_FAILURE_RETRY-mac.patch new file +38 -0
@@ -0,0 +1,38 @@ +From abfe3e7b2b4af1de9b891f3a7a996b70533b0a27 Mon Sep 17 00:00:00 2001 +From: Peter Seiderer <[email protected]> +Date: Sun, 4 Mar 2018 09:07:51 +0100 +Subject: [PATCH] libdvbv5: add optional copy of TEMP_FAILURE_RETRY macro (fix + musl compile) + +Fixes: + + ../../lib/libdvbv5/.libs/libdvbv5.so: undefined reference to `TEMP_FAILURE_RETRY' + +Signed-off-by: Peter Seiderer <[email protected]> +--- + lib/libdvbv5/dvb-dev-local.c | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/lib/libdvbv5/dvb-dev-local.c b/lib/libdvbv5/dvb-dev-local.c +index 8bc99d1..7a76d65 100644 +--- a/lib/libdvbv5/dvb-dev-local.c ++++ b/lib/libdvbv5/dvb-dev-local.c +@@ -44,6 +44,15 @@ + # define _(string) string + #endif + ++/* taken from glibc unistd.h */ ++#ifndef TEMP_FAILURE_RETRY ++#define TEMP_FAILURE_RETRY(expression) \ ++ ({ long int __result; \ ++ do __result = (long int) (expression); \ ++ while (__result == -1L && errno == EINTR); \ ++ __result; }) ++#endif ++ + struct dvb_dev_local_priv { + dvb_dev_change_t notify_dev_change; + +-- +2.16.2 +
Signature · 1 line
2.16.2
PATCH 1/1 libv4l: fix libdvbv5 musl compile
Hi Peter,
Quoted 21 lines · Peter Seiderer
Add optional copy of
TEMP_FAILURE_RETRYmacro.Fixes [1]:
../../lib/libdvbv5/.libs/libdvbv5.so: undefined reference to `TEMP_FAILURE_RETRY'
[1] http://autobuild.buildroot.net/results/7aea0cbb9e7fe7d9919c9be04ba4567ddcf4e15e
Signed-off-by Peter Seiderer <[email protected]>--- ...d-optional-copy-of-TEMP_FAILURE_RETRY-mac.patch | 38 ++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 package/libv4l/0003-libdvbv5-add-optional-copy-of-TEMP_FAILURE_RETRY-mac.patchpackage/libv4l/0003-libdvbv5-add-optional-copy-of-TEMP_FAILURE_RETRY-mac.patch new file +1
-0@@ -0,0 +1,38 @@ +From abfe3e7b2b4af1de9b891f3a7a996b70533b0a27 Mon Sep 17 00:00:00 2001
package/libv4l/0003-libdvbv5-add-optional-copy-of-TEMP_FAILURE_RETRY-mac.patch line 11
Quoted 10 lines
package/libv4l/0003-libdvbv5-add-optional-copy-of-TEMP_FAILURE_RETRY-mac.patch new file +10
-0+From: Peter Seiderer <[email protected]> +Date: Sun, 4 Mar 2018 09:07:51 +0100 +Subject: [PATCH] libdvbv5: add optional copy of TEMP_FAILURE_RETRY macro (fix + musl compile) + +Fixes: + + ../../lib/libdvbv5/.libs/libdvbv5.so: undefined reference to `TEMP_FAILURE_RETRY' + +Signed-off-by: Peter Seiderer <[email protected]>
Link to your upstream submission:
https://www.mail-archive.com/linux-media at vger.kernel.org/msg127134.html
baruch
Quoted 23 lines
package/libv4l/0003-libdvbv5-add-optional-copy-of-TEMP_FAILURE_RETRY-mac.patch new file +23
-0+--- + lib/libdvbv5/dvb-dev-local.c | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/lib/libdvbv5/dvb-dev-local.c b/lib/libdvbv5/dvb-dev-local.c +index 8bc99d1..7a76d65 100644 +--- a/lib/libdvbv5/dvb-dev-local.c ++++ b/lib/libdvbv5/dvb-dev-local.c +@@ -44,6 +44,15 @@ + # define _(string) string + #endif + ++/* taken from glibc unistd.h */ ++#ifndef TEMP_FAILURE_RETRY ++#define TEMP_FAILURE_RETRY(expression) \ ++ ({ long int __result; \ ++ do __result = (long int) (expression); \ ++ while (__result == -1L && errno == EINTR); \ ++ __result; }) ++#endif ++ + struct dvb_dev_local_priv { + dvb_dev_change_t notify_dev_change;
Signature · 3 lines
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -PATCH 1/1 libv4l: fix libdvbv5 musl compile
In reply to Peter SeidererQuoted 10 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Peter" == Peter Seiderer <[email protected]> writes:
Add optional copy of
TEMP_FAILURE_RETRYmacro.
Fixes [1]:../../lib/libdvbv5/.libs/libdvbv5.so: undefined reference to `TEMP_FAILURE_RETRY'
[1] http://autobuild.buildroot.net/results/7aea0cbb9e7fe7d9919c9be04ba4567ddcf4e15e
Signed-off-by Peter Seiderer <[email protected]>
Committed after adding the upstream submission link as suggested by Baruch, thanks!
Signature · 1 line
Bye, Peter Korsgaard