Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(707)

Unified Diff: runtime/platform/globals.h

Issue 10823209: Add support for building the Dart VM for Android OS. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: runtime/platform/globals.h
diff --git a/runtime/platform/globals.h b/runtime/platform/globals.h
index 8ca5065ac611dbb17eca14bf79e35bcd4d00e33d..0b53d62e9a56dde2d46f0a0607bc1f314fec4598 100644
--- a/runtime/platform/globals.h
+++ b/runtime/platform/globals.h
@@ -52,7 +52,9 @@
// for more information on predefined macros:
// - http://msdn.microsoft.com/en-us/library/b0084kay.aspx
// - with gcc, run: "echo | gcc -E -dM -"
-#if defined(__linux__) || defined(__FreeBSD__)
+#if defined(__ANDROID__)
+#define TARGET_OS_ANDROID
+#elif defined(__linux__) || defined(__FreeBSD__)
#define TARGET_OS_LINUX 1
#elif defined(__APPLE__)
#define TARGET_OS_MACOS 1
@@ -330,7 +332,11 @@ inline D bit_copy(const S& source) {
#if defined(memcpy)
#undef memcpy
#endif
-#if !defined(TARGET_OS_WINDOWS)
+#if defined(TARGET_OS_ANDROID)
+ // Need to allow memcpy, it's used by stlport headers
cshapiro 2012/08/07 20:56:54 Why not mention android in the comment on line 330
jackpal 2012/08/07 21:43:26 Done.
+#elif defined(TARGET_OS_WINDOWS)
+ // Allow memcpy
+#else
#define memcpy "Please use memmove instead of memcpy."
#endif

Powered by Google App Engine
This is Rietveld 408576698