[vlc-commits] configure: always pass -pthread on Linux

Rémi Denis-Courmont git at videolan.org
Mon Jun 18 19:09:31 CEST 2018


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Jun 17 12:07:06 2018 +0300| [fc8208ec86db8eff4ec666a4c9af1828a9ac5bdf] | committer: Rémi Denis-Courmont

configure: always pass -pthread on Linux

This appears to be the official way to get POSIX threads. In practice,
it pre-defines _REENTRANT to 1 and pulls -lpthread.
(This works with both GCC and Clang.)

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=fc8208ec86db8eff4ec666a4c9af1828a9ac5bdf
---

 configure.ac | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/configure.ac b/configure.ac
index c96778e04e..eaa17947b3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -102,7 +102,7 @@ case "${host_os}" in
     ;;
   linux*)
     SYS=linux
-    test "${host_cpu}" = "riscv64" && CFLAGS="${CFLAGS} -pthread"
+    CFLAGS="${CFLAGS} -pthread"
     ;;
   bsdi*)
     SYS=bsdi



More information about the vlc-commits mailing list