# HG changeset patch
# Parent  e88786724ab69befc700c4acacdc74ddad1675e6

diff -r e88786724ab6 media/webrtc/trunk/webrtc/modules/video_capture/linux/device_info_linux.cc
--- a/media/webrtc/trunk/webrtc/modules/video_capture/linux/device_info_linux.cc	Thu Jul 23 14:16:49 2020 +0000
+++ b/media/webrtc/trunk/webrtc/modules/video_capture/linux/device_info_linux.cc	Thu Jul 30 10:19:35 2020 +0200
@@ -385,11 +385,13 @@
 
 bool DeviceInfoLinux::IsVideoCaptureDevice(struct v4l2_capability* cap)
 {
-  if (cap->capabilities & V4L2_CAP_DEVICE_CAPS) {
-    return cap->device_caps & V4L2_CAP_VIDEO_CAPTURE;
-  } else {
+// SLE-11 doesn't define V4L2_CAP_DEVICE_CAPS, so its obviously not available
+// so we use the fallback by default.
+//  if (cap->capabilities & V4L2_CAP_DEVICE_CAPS) {
+//    return cap->device_caps & V4L2_CAP_VIDEO_CAPTURE;
+//  } else {
     return cap->capabilities & V4L2_CAP_VIDEO_CAPTURE;
-  }
+//  }
 }
 
 int32_t DeviceInfoLinux::FillCapabilities(int fd) {
diff -r e88786724ab6 mozglue/build/ppc.cpp
--- a/mozglue/build/ppc.cpp	Thu Jul 23 14:16:49 2020 +0000
+++ b/mozglue/build/ppc.cpp	Thu Jul 30 10:19:35 2020 +0200
@@ -14,7 +14,7 @@
 #if defined(XP_LINUX)
 // Use the getauxval() function if available.
 // ARCH_3_00 wasn't defined until glibc 2.23, so include just in case.
-#  include <sys/auxv.h>
+//#  include <sys/auxv.h>
 #  ifndef PPC_FEATURE2_ARCH_3_00
 #    define PPC_FEATURE2_ARCH_3_00 0x00800000
 #  endif
@@ -35,18 +35,18 @@
 
 #if defined(XP_LINUX)
   // Try getauxval().
-  unsigned long int cap = getauxval(AT_HWCAP);
-  unsigned long int cap2 = getauxval(AT_HWCAP2);
+//  unsigned long int cap = getauxval(AT_HWCAP);
+//  unsigned long int cap2 = getauxval(AT_HWCAP2);
 
-  if (cap & PPC_FEATURE_HAS_ALTIVEC) {
-    cpu_flags |= PPC_FLAG_VMX;
-  }
-  if (cap & PPC_FEATURE_HAS_VSX) {
-    cpu_flags |= PPC_FLAG_VSX;
-  }
-  if (cap2 & PPC_FEATURE2_ARCH_3_00) {
-    cpu_flags |= PPC_FLAG_VSX3;
-  }
+//  if (cap & PPC_FEATURE_HAS_ALTIVEC) {
+//    cpu_flags |= PPC_FLAG_VMX;
+//  }
+//  if (cap & PPC_FEATURE_HAS_VSX) {
+//    cpu_flags |= PPC_FLAG_VSX;
+//  }
+//  if (cap2 & PPC_FEATURE2_ARCH_3_00) {
+//    cpu_flags |= PPC_FLAG_VSX3;
+//  }
 #else
   // Non-Linux detection here. Currently, on systems other than Linux,
   // no CPU SIMD features will be detected.
diff -r e88786724ab6 python/mozbuild/mozpack/executables.py
--- a/python/mozbuild/mozpack/executables.py	Thu Jul 23 14:16:49 2020 +0000
+++ b/python/mozbuild/mozpack/executables.py	Thu Jul 30 10:19:35 2020 +0200
@@ -2,7 +2,8 @@
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
-from __future__ import absolute_import, print_function, unicode_literals
+#from __future__ import absolute_import, print_function, unicode_literals
+from __future__ import absolute_import, print_function
 
 import os
 import struct
diff -r e88786724ab6 remote/mach_commands.py
--- a/remote/mach_commands.py	Thu Jul 23 14:16:49 2020 +0000
+++ b/remote/mach_commands.py	Thu Jul 30 10:19:35 2020 +0200
@@ -34,7 +34,6 @@
 )
 from mozbuild import nodeutil
 import mozlog
-import mozprofile
 
 
 EX_CONFIG = 78
@@ -332,6 +331,7 @@
         env["HEADLESS"] = str(params.get("headless", False))
 
         prefs = {}
+        import mozprofile
         for k, v in params.get("extra_prefs", {}).items():
             prefs[k] = mozprofile.Preferences.cast(v)
 
diff -r e88786724ab6 toolkit/system/unixproxy/nsLibProxySettings.cpp
--- a/toolkit/system/unixproxy/nsLibProxySettings.cpp	Thu Jul 23 14:16:49 2020 +0000
+++ b/toolkit/system/unixproxy/nsLibProxySettings.cpp	Thu Jul 30 10:19:35 2020 +0200
@@ -57,7 +57,7 @@
 
   char** proxyArray = nullptr;
   proxyArray = px_proxy_factory_get_proxies(mProxyFactory,
-                                            PromiseFlatCString(aSpec).get());
+                                            (char*)PromiseFlatCString(aSpec).get());
   NS_ENSURE_TRUE(proxyArray, NS_ERROR_NOT_AVAILABLE);
 
   // Translate libproxy's output to PAC string as expected
diff -r e88786724ab6 xpcom/threads/nsThread.cpp
--- a/xpcom/threads/nsThread.cpp	Thu Jul 23 14:16:49 2020 +0000
+++ b/xpcom/threads/nsThread.cpp	Thu Jul 30 10:19:35 2020 +0200
@@ -549,7 +549,12 @@
     // kernel report them as separate regions, even when they are adjacent to
     // heap memory. This allows us to accurately track the actual memory
     // consumption of our allocated stacks.
+
+// On SLE-11 SP1, this macro is not available. We don't really need to "accurately track memory consumption"
+// so hopefully deactivating that is ok
+#if defined(MADV_NOHUGEPAGE)
     madvise(mStackBase, stackSize, MADV_NOHUGEPAGE);
+#endif
 
     pthread_attr_destroy(&attr);
 #elif defined(XP_WIN)
