Bug 1176730: Don't use pthread for libvpx in mingw builds. r=rillian

Based on a patch by Jacek Caban.
This commit is contained in:
Jan Gerber 2015-06-23 02:19:00 -07:00
parent b1106be045
commit 73b378ca3c
4 changed files with 58 additions and 2 deletions

View File

@ -0,0 +1,52 @@
From: Jacek Caban <jacek@codeweavers.com>
Don't use pthread for libvpx in mingw builds.
diff --git a/media/libvpx/vpx_config_x86-win32-gcc.h b/media/libvpx/vpx_config_x86-win32-gcc.h
index c5452c0..12b5c84 100644
--- a/media/libvpx/vpx_config_x86-win32-gcc.h
+++ b/media/libvpx/vpx_config_x86-win32-gcc.h
@@ -30,17 +30,18 @@
#define HAVE_SSSE3 1
#define HAVE_SSE4_1 1
#define HAVE_AVX 1
#define HAVE_AVX2 1
#define HAVE_ALTIVEC 0
#define HAVE_VPX_PORTS 1
#define HAVE_STDINT_H 1
#define HAVE_ALT_TREE_LAYOUT 0
-#define HAVE_PTHREAD_H 1
+#undef HAVE_PTHREAD_H
+#define HAVE_PTHREAD_H 0
#define HAVE_SYS_MMAN_H 1
#define HAVE_UNISTD_H 1
#define CONFIG_DEPENDENCY_TRACKING 1
#define CONFIG_EXTERNAL_BUILD 0
#define CONFIG_INSTALL_DOCS 0
#define CONFIG_INSTALL_BINS 1
#define CONFIG_INSTALL_LIBS 1
#define CONFIG_INSTALL_SRCS 0
diff --git a/media/libvpx/vpx_config_x86_64-win64-gcc.h b/media/libvpx/vpx_config_x86_64-win64-gcc.h
index 04f382b..4d75a4b 100644
--- a/media/libvpx/vpx_config_x86_64-win64-gcc.h
+++ b/media/libvpx/vpx_config_x86_64-win64-gcc.h
@@ -30,17 +30,18 @@
#define HAVE_SSSE3 1
#define HAVE_SSE4_1 1
#define HAVE_AVX 1
#define HAVE_AVX2 1
#define HAVE_ALTIVEC 0
#define HAVE_VPX_PORTS 1
#define HAVE_STDINT_H 1
#define HAVE_ALT_TREE_LAYOUT 0
-#define HAVE_PTHREAD_H 1
+#undef HAVE_PTHREAD_H
+#define HAVE_PTHREAD_H 0
#define HAVE_SYS_MMAN_H 1
#define HAVE_UNISTD_H 1
#define CONFIG_DEPENDENCY_TRACKING 1
#define CONFIG_EXTERNAL_BUILD 0
#define CONFIG_INSTALL_DOCS 0
#define CONFIG_INSTALL_BINS 1
#define CONFIG_INSTALL_LIBS 1
#define CONFIG_INSTALL_SRCS 0

View File

@ -556,6 +556,8 @@ def apply_patches():
os.system("patch -p1 < msvc2015.patch")
# Patch to fix a crash caused by MSVC 2013
os.system("patch -p3 < bug1137614.patch")
# Bug 1176730 - Don't use pthread for libvpx in mingw builds.
os.system("patch -p3 < disable_pthread_on_mingw.patch")
def update_readme(commit):
with open('README_MOZILLA') as f:

View File

@ -35,7 +35,8 @@
#define HAVE_VPX_PORTS 1
#define HAVE_STDINT_H 1
#define HAVE_ALT_TREE_LAYOUT 0
#define HAVE_PTHREAD_H 1
#undef HAVE_PTHREAD_H
#define HAVE_PTHREAD_H 0
#define HAVE_SYS_MMAN_H 1
#define HAVE_UNISTD_H 1
#define CONFIG_DEPENDENCY_TRACKING 1

View File

@ -35,7 +35,8 @@
#define HAVE_VPX_PORTS 1
#define HAVE_STDINT_H 1
#define HAVE_ALT_TREE_LAYOUT 0
#define HAVE_PTHREAD_H 1
#undef HAVE_PTHREAD_H
#define HAVE_PTHREAD_H 0
#define HAVE_SYS_MMAN_H 1
#define HAVE_UNISTD_H 1
#define CONFIG_DEPENDENCY_TRACKING 1