From 44fe667d86bfc0cf16874ae864ca4b6cfff46287 Mon Sep 17 00:00:00 2001 From: "ronghuawu@google.com" Date: Mon, 18 Jul 2011 16:13:23 +0000 Subject: [PATCH] Fixes for the chromium build ARM and some old x86 platform: 1) Removed SSE2 for ARM in aec.gyp. 2) Removed the re-definition of DISALLOW_COPY_AND_ASSIGN in latebindingsymboltable.h. 3) SSE2 not always supported in some old x86 platform. Review URL: http://webrtc-codereview.appspot.com/80002 git-svn-id: http://webrtc.googlecode.com/svn/trunk@224 4adac7df-926f-26a2-2b94-8c16560cd09d --- .../main/source/Linux/latebindingsymboltable.h | 5 +---- src/modules/audio_processing/aec/main/source/aec.gyp | 10 ++++++++-- .../audio_processing/aec/main/source/aec_rdft_sse2.c | 3 +++ 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/src/modules/audio_device/main/source/Linux/latebindingsymboltable.h b/src/modules/audio_device/main/source/Linux/latebindingsymboltable.h index fbc581d7c8..0799869dee 100644 --- a/src/modules/audio_device/main/source/Linux/latebindingsymboltable.h +++ b/src/modules/audio_device/main/source/Linux/latebindingsymboltable.h @@ -32,12 +32,9 @@ #include // for NULL #include +#include "constructor_magic.h" #include "trace.h" -#define DISALLOW_COPY_AND_ASSIGN(TypeName) \ - TypeName(const TypeName&); \ - void operator=(const TypeName&) - // This file provides macros for creating "symbol table" classes to simplify the // dynamic loading of symbols from DLLs. Currently the implementation only // supports Linux and pure C symbols. diff --git a/src/modules/audio_processing/aec/main/source/aec.gyp b/src/modules/audio_processing/aec/main/source/aec.gyp index 0427e0021d..2299497c54 100644 --- a/src/modules/audio_processing/aec/main/source/aec.gyp +++ b/src/modules/audio_processing/aec/main/source/aec.gyp @@ -30,14 +30,20 @@ '../interface/echo_cancellation.h', 'echo_cancellation.c', 'aec_core.c', - 'aec_core_sse2.c', 'aec_rdft.h', 'aec_rdft.c', - 'aec_rdft_sse2.c', 'aec_core.h', 'resampler.c', 'resampler.h', ], + 'conditions': [ + ['target_arch == "ia32" or target_arch == "x64"', { + 'sources': [ + 'aec_core_sse2.c', + 'aec_rdft_sse2.c', + ], + }], + ], }, ], } diff --git a/src/modules/audio_processing/aec/main/source/aec_rdft_sse2.c b/src/modules/audio_processing/aec/main/source/aec_rdft_sse2.c index 901a1b1462..1d7c4572b2 100644 --- a/src/modules/audio_processing/aec/main/source/aec_rdft_sse2.c +++ b/src/modules/audio_processing/aec/main/source/aec_rdft_sse2.c @@ -8,6 +8,7 @@ * be found in the AUTHORS file in the root of the source tree. */ +#if defined(__SSE2__) #include #include "aec_rdft.h" @@ -207,3 +208,5 @@ void aec_rdft_init_sse2(void) { rftfsub_128 = rftfsub_128_SSE2; rftbsub_128 = rftbsub_128_SSE2; } + +#endif // __SSE2__