Diff
Modified: trunk/Source/WTF/ChangeLog (147893 => 147894)
--- trunk/Source/WTF/ChangeLog 2013-04-08 04:20:38 UTC (rev 147893)
+++ trunk/Source/WTF/ChangeLog 2013-04-08 06:20:12 UTC (rev 147894)
@@ -1,3 +1,16 @@
+2013-04-07 Benjamin Poulain <[email protected]>
+
+ Remove the android code from WebKit Template Framework
+ https://bugs.webkit.org/show_bug.cgi?id=114138
+
+ Reviewed by Dirk Schulze.
+
+ * wtf/Assertions.cpp:
+ * wtf/Atomics.h:
+ * wtf/MathExtras.h:
+ * wtf/Platform.h:
+ * wtf/ThreadIdentifierDataPthreads.cpp:
+
2013-04-07 Oliver Hunt <[email protected]>
Add bounds checking for WTF::Vector::operator[]
Modified: trunk/Source/WTF/wtf/Assertions.cpp (147893 => 147894)
--- trunk/Source/WTF/wtf/Assertions.cpp 2013-04-08 04:20:38 UTC (rev 147893)
+++ trunk/Source/WTF/wtf/Assertions.cpp 2013-04-08 06:20:12 UTC (rev 147894)
@@ -61,16 +61,12 @@
#include <windows.h>
#endif
-#if (OS(DARWIN) || (OS(LINUX) && !defined(__UCLIBC__))) && !OS(ANDROID)
+#if OS(DARWIN) || (OS(LINUX) && !defined(__UCLIBC__))
#include <cxxabi.h>
#include <dlfcn.h>
#include <execinfo.h>
#endif
-#if OS(ANDROID)
-#include "android/log.h"
-#endif
-
#if PLATFORM(BLACKBERRY)
#include <BlackBerryPlatformLog.h>
#endif
@@ -119,8 +115,6 @@
#elif PLATFORM(BLACKBERRY)
BBLOGV(BlackBerry::Platform::LogLevelCritical, format, args);
-#elif OS(ANDROID)
- __android_log_vprint(ANDROID_LOG_WARN, "WebKit", format, args);
#elif HAVE(ISDEBUGGERPRESENT)
if (IsDebuggerPresent()) {
size_t size = 1024;
@@ -245,7 +239,7 @@
void WTFGetBacktrace(void** stack, int* size)
{
-#if (OS(DARWIN) || (OS(LINUX) && !defined(__UCLIBC__))) && !OS(ANDROID)
+#if OS(DARWIN) || (OS(LINUX) && !defined(__UCLIBC__))
*size = backtrace(stack, *size);
#elif OS(WINDOWS) && !OS(WINCE)
// The CaptureStackBackTrace function is available in XP, but it is not defined
@@ -284,8 +278,6 @@
# if defined(__GLIBC__) && !defined(__UCLIBC__)
# define WTF_USE_BACKTRACE_SYMBOLS 1
# endif
-# elif !OS(ANDROID)
-# define WTF_USE_DLADDR 1
# endif
#endif
Modified: trunk/Source/WTF/wtf/Atomics.h (147893 => 147894)
--- trunk/Source/WTF/wtf/Atomics.h 2013-04-08 04:20:38 UTC (rev 147893)
+++ trunk/Source/WTF/wtf/Atomics.h 2013-04-08 06:20:12 UTC (rev 147894)
@@ -67,8 +67,6 @@
#include <windows.h>
#elif OS(QNX)
#include <atomic.h>
-#elif OS(ANDROID)
-#include <sys/atomics.h>
#endif
namespace WTF {
@@ -100,13 +98,6 @@
inline int atomicIncrement(int volatile* addend) { return static_cast<int>(atomic_add_value(reinterpret_cast<unsigned volatile*>(addend), 1)) + 1; }
inline int atomicDecrement(int volatile* addend) { return static_cast<int>(atomic_sub_value(reinterpret_cast<unsigned volatile*>(addend), 1)) - 1; }
-#elif OS(ANDROID)
-#define WTF_USE_LOCKFREE_THREADSAFEREFCOUNTED 1
-
-// Note, __atomic_{inc, dec}() return the previous value of addend's content.
-inline int atomicIncrement(int volatile* addend) { return __atomic_inc(addend) + 1; }
-inline int atomicDecrement(int volatile* addend) { return __atomic_dec(addend) - 1; }
-
#elif COMPILER(GCC) && !CPU(SPARC64) // sizeof(_Atomic_word) != sizeof(int) on sparc64 gcc
#define WTF_USE_LOCKFREE_THREADSAFEREFCOUNTED 1
Modified: trunk/Source/WTF/wtf/MathExtras.h (147893 => 147894)
--- trunk/Source/WTF/wtf/MathExtras.h 2013-04-08 04:20:38 UTC (rev 147893)
+++ trunk/Source/WTF/wtf/MathExtras.h 2013-04-08 06:20:12 UTC (rev 147894)
@@ -146,17 +146,17 @@
inline long long abs(long num) { return labs(num); }
#endif
-#if OS(ANDROID) || COMPILER(MSVC)
-// ANDROID and MSVC's math.h does not currently supply log2 or log2f.
+#if COMPILER(MSVC)
+// MSVC's math.h does not currently supply log2 or log2f.
inline double log2(double num)
{
- // This constant is roughly M_LN2, which is not provided by default on Windows and Android.
+ // This constant is roughly M_LN2, which is not provided by default on Windows.
return log(num) / 0.693147180559945309417232121458176568;
}
inline float log2f(float num)
{
- // This constant is roughly M_LN2, which is not provided by default on Windows and Android.
+ // This constant is roughly M_LN2, which is not provided by default on Windows.
return logf(num) / 0.693147180559945309417232121458176568f;
}
#endif
Modified: trunk/Source/WTF/wtf/Platform.h (147893 => 147894)
--- trunk/Source/WTF/wtf/Platform.h 2013-04-08 04:20:38 UTC (rev 147893)
+++ trunk/Source/WTF/wtf/Platform.h 2013-04-08 06:20:12 UTC (rev 147894)
@@ -181,8 +181,7 @@
#elif !defined(__ARM_EABI__) \
&& !defined(__EABI__) \
&& !defined(__VFP_FP__) \
- && !defined(_WIN32_WCE) \
- && !defined(ANDROID)
+ && !defined(_WIN32_WCE)
#define WTF_CPU_MIDDLE_ENDIAN 1
#endif
@@ -324,11 +323,6 @@
/* ==== OS() - underlying operating system; only to be used for mandated low-level services like
virtual memory, not to choose a GUI toolkit ==== */
-/* OS(ANDROID) - Android */
-#ifdef ANDROID
-#define WTF_OS_ANDROID 1
-#endif
-
/* OS(AIX) - AIX */
#ifdef _AIX
#define WTF_OS_AIX 1
@@ -416,7 +410,6 @@
/* OS(UNIX) - Any Unix-like system */
#if OS(AIX) \
- || OS(ANDROID) \
|| OS(DARWIN) \
|| OS(FREEBSD) \
|| OS(HURD) \
@@ -598,7 +591,7 @@
#define WTF_USE_PTHREADS 1
#endif /* OS(UNIX) */
-#if OS(UNIX) && !OS(ANDROID) && !OS(QNX)
+#if OS(UNIX) && !OS(QNX)
#define HAVE_LANGINFO_H 1
#endif
@@ -618,7 +611,7 @@
#endif
#endif
-#if !OS(WINDOWS) && !OS(SOLARIS) && !OS(ANDROID)
+#if !OS(WINDOWS) && !OS(SOLARIS)
#define HAVE_TM_GMTOFF 1
#define HAVE_TM_ZONE 1
#define HAVE_TIMEGM 1
Modified: trunk/Source/WTF/wtf/ThreadIdentifierDataPthreads.cpp (147893 => 147894)
--- trunk/Source/WTF/wtf/ThreadIdentifierDataPthreads.cpp 2013-04-08 04:20:38 UTC (rev 147893)
+++ trunk/Source/WTF/wtf/ThreadIdentifierDataPthreads.cpp 2013-04-08 06:20:12 UTC (rev 147894)
@@ -36,7 +36,7 @@
#include "Threading.h"
-#if OS(ANDROID) || OS(HURD)
+#if OS(HURD)
// PTHREAD_KEYS_MAX is not defined in bionic nor in Hurd, so explicitly define it here.
#define PTHREAD_KEYS_MAX 1024
#else