Skip to contentSkip to conversation

package/mpv: needs NPTL

PATCH In review Fabrice Fontaine 2 participants 3 messages Mar 8, 2023 – Mar 15, 2023

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/mpv: needs NPTL

mpv unconditionally uses pthread_getcpuclockid since version 0.33.0 and
https://github.com/mpv-player/mpv/commit/fd3caa264ea0848e7e30db94390063c87e247003
resulting in the following build failure without NPTL since commit e3cf26dda31e6c1720c53e0229d93fe2a5ea18aa:

../common/stats.c: In function 'get_thread_cpu_time_ns':
../common/stats.c:75:9: error: implicit declaration of function 'pthread_getcpuclockid'; did you mean 'pthread_getspecific'? [-Werror=implicit-function-declaration]

   75 |     if (pthread_getcpuclockid(thread, &id) == 0 &&
      |         ^~~~~~~~~~~~~~~~~~~~~
      |         pthread_getspecific

Fixes:
- http://autobuild.buildroot.org/results/98cde5cbb0844c6ef483a75cf9a6f3fd3a46c693

---
 package/mpv/Config.in   | 6 +++---
 package/tovid/Config.in | 8 ++++----
 2 files changed, 7 insertions(+), 7 deletions(-)
package/mpv/Config.in +3 -3
index 6811497d73..8efb353c33 100644
@@ -8,7 +8,7 @@ config BR2_PACKAGE_MPV
 	bool "mpv"
 	depends on BR2_INSTALL_LIBSTDCPP # libass
 	depends on BR2_TOOLCHAIN_HAS_SYNC_4 # libass
-	depends on BR2_TOOLCHAIN_HAS_THREADS
+	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
 	depends on BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS
 	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # C11/stdatomic.h
 	depends on BR2_TOOLCHAIN_HAS_ATOMIC
@@ -34,10 +34,10 @@ config BR2_PACKAGE_MPV
 
 	  https://mpv.io/
 
-comment "mpv needs a toolchain w/ C++, threads, gcc >= 4.9"
+comment "mpv needs a toolchain w/ C++, NPTL, gcc >= 4.9"
 	depends on BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS
 	depends on BR2_TOOLCHAIN_HAS_ATOMIC
 	depends on BR2_TOOLCHAIN_HAS_SYNC_4
-	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+	depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL || \
 		!BR2_INSTALL_LIBSTDCPP || \
 		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
package/tovid/Config.in +4 -4
index 3dbb0e229e..c263acdd62 100644
@@ -1,7 +1,7 @@
 config BR2_PACKAGE_TOVID
 	bool "tovid"
 	depends on BR2_USE_MMU # fork()
-	depends on BR2_TOOLCHAIN_HAS_THREADS
+	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # mpv
 	depends on BR2_INSTALL_LIBSTDCPP
 	depends on BR2_USE_WCHAR
 	depends on BR2_PACKAGE_PYTHON3
@@ -29,12 +29,12 @@ config BR2_PACKAGE_TOVID
 
 	  http://tovid.wikia.com/wiki/Installing_tovid
 
-comment "tovid needs a toolchain w/ threads, C++, wchar, gcc >= 4.9"
+comment "tovid needs a toolchain w/ NPTL, C++, wchar, gcc >= 4.9"
 	depends on BR2_USE_MMU
 	depends on BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS
 	depends on BR2_TOOLCHAIN_HAS_ATOMIC
 	depends on BR2_TOOLCHAIN_HAS_SYNC_4
-	depends on !BR2_TOOLCHAIN_HAS_THREADS \
+	depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL \
 		|| !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 \
 		|| !BR2_INSTALL_LIBSTDCPP \
 		|| !BR2_USE_WCHAR
@@ -45,6 +45,6 @@ comment "tovid depends on python3"
 	depends on BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS
 	depends on BR2_TOOLCHAIN_HAS_ATOMIC
 	depends on BR2_TOOLCHAIN_HAS_SYNC_4
-	depends on !BR2_TOOLCHAIN_HAS_THREADS || \
+	depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL || \
 		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
 	depends on !BR2_TOOLCHAIN_EXTERNAL_SYNOPSYS_ARC
Signature · 6 lines
2.39.1

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#1 lore raw
Quoted 11 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Fabrice" == Fabrice Fontaine <[email protected]> writes:

mpv unconditionally uses pthread_getcpuclockid since version 0.33.0 and
https://github.com/mpv-player/mpv/commit/fd3caa264ea0848e7e30db94390063c87e247003
resulting in the following build failure without NPTL since commit e3cf26dda31e6c1720c53e0229d93fe2a5ea18aa:

../common/stats.c: In function 'get_thread_cpu_time_ns':
../common/stats.c:75:9: error: implicit declaration of function 'pthread_getcpuclockid'; did you mean 'pthread_getspecific'? [-Werror=implicit-function-declaration]

Quoted 8 lines
   75 |     if (pthread_getcpuclockid(thread, &id) == 0 &&
      |         ^~~~~~~~~~~~~~~~~~~~~
      |         pthread_getspecific

Fixes:
- http://autobuild.buildroot.org/results/98cde5cbb0844c6ef483a75cf9a6f3fd3a46c693

Committed, thanks.

Signature · 5 lines
Bye, Peter Korsgaard
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#2 lore raw
In reply to Fabrice Fontaine
Quoted 11 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Fabrice" == Fabrice Fontaine <[email protected]> writes:

mpv unconditionally uses pthread_getcpuclockid since version 0.33.0 and
https://github.com/mpv-player/mpv/commit/fd3caa264ea0848e7e30db94390063c87e247003
resulting in the following build failure without NPTL since commit e3cf26dda31e6c1720c53e0229d93fe2a5ea18aa:

../common/stats.c: In function 'get_thread_cpu_time_ns':
../common/stats.c:75:9: error: implicit declaration of function 'pthread_getcpuclockid'; did you mean 'pthread_getspecific'? [-Werror=implicit-function-declaration]

Quoted 8 lines
   75 |     if (pthread_getcpuclockid(thread, &id) == 0 &&
      |         ^~~~~~~~~~~~~~~~~~~~~
      |         pthread_getspecific

Fixes:
- http://autobuild.buildroot.org/results/98cde5cbb0844c6ef483a75cf9a6f3fd3a46c693

Committed to 2022.11.x and 2022.02.x, thanks.

Signature · 5 lines
Bye, Peter Korsgaard
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot