aboutsummaryrefslogtreecommitdiff
Copied from Debian.

Description: Fix build of  WebRTC on non-Linux systems
 * Define the WEBRTC_LINUX macro only on Linux, and not on GNU/Hurd or FreeBSD.
 * Fix type cast in the CurrentThreadId function.
Bug-Debian: https://bugs.debian.org/920851
Author: Nicholas Guriev <guriev-ns@ya.ru>
Last-Update: Tue, 29 Jan 2019 23:26:44 +0300

--- a/libtgvoip.gyp
+++ b/libtgvoip.gyp
@@ -869,20 +869,18 @@
             '"<(OS)" == "linux"', {
               'defines': [
                 'WEBRTC_POSIX',
-                'WEBRTC_LINUX',
               ],
               'conditions': [
                 [ '"<!(uname -m)" == "i686"', {
                   'cflags_cc': [
                     '-msse2',
                   ],
+                }], ['"<!(uname -s)" == "Linux"', {
+                  'defines': [
+                    'WEBRTC_LINUX',
+                  ],
                 }]
               ],
-              'direct_dependent_settings': {
-                'libraries': [
-
-                ],
-              },
             },
           ],
         ],
--- a/webrtc_dsp/rtc_base/platform_thread_types.cc
+++ b/webrtc_dsp/rtc_base/platform_thread_types.cc
@@ -31,7 +31,7 @@ PlatformThreadId CurrentThreadId() {
   return syscall(__NR_gettid);
 #else
   // Default implementation for nacl and solaris.
-  return reinterpret_cast<pid_t>(pthread_self());
+  return static_cast<pid_t>(pthread_self());
 #endif
 #endif  // defined(WEBRTC_POSIX)
 }
tion. * guix/store/deduplication.scm (%deduplication-minimum-size): New variable. (deduplicate)[loop]: Do not recurse when FILE's size is below %DEDUPLICATION-MINIMUM-SIZE. (dump-port): New procedure. (dump-file/deduplicate)[hash]: Turn into... [dump-and-compute-hash]: ... this thunk. Call 'deduplicate' only when SIZE is greater than %DEDUPLICATION-MINIMUM-SIZE; otherwise call 'dump-port'. * nix/libstore/gc.cc (LocalStore::removeUnusedLinks): Drop files where st.st_size < deduplicationMinSize. * nix/libstore/local-store.hh (deduplicationMinSize): New declaration. * nix/libstore/optimise-store.cc (deduplicationMinSize): New variable. (LocalStore::optimisePath_): Return when PATH is a symlink or smaller than 'deduplicationMinSize'. * tests/derivations.scm ("identical files are deduplicated"): Produce files bigger than %DEDUPLICATION-MINIMUM-SIZE. * tests/nar.scm ("restore-file-set with directories (signed, valid)"): Likewise. * tests/store-deduplication.scm ("deduplicate, below %deduplication-minimum-size"): New test. ("deduplicate", "deduplicate, ENOSPC"): Produce files bigger than %DEDUPLICATION-MINIMUM-SIZE. * tests/store.scm ("substitute, deduplication"): Likewise. Ludovic Courtès