From ec82215b44bec8a89e7deb01d06036bc69df2c8f Mon Sep 17 00:00:00 2001 From: "sgjesse@chromium.org" Date: Thu, 17 Mar 2011 07:34:37 +0000 Subject: [PATCH] Add a preprocessor symbol to have printing on Android use stdout instead of the system log This is convenient for debugging on Android as one don't have to go to the system log for printf based debugging. Review URL: http://codereview.chromium.org/6672041 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7211 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- src/platform-posix.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/platform-posix.cc b/src/platform-posix.cc index 256dc75..9118818 100644 --- a/src/platform-posix.cc +++ b/src/platform-posix.cc @@ -139,7 +139,7 @@ void OS::Print(const char* format, ...) { void OS::VPrint(const char* format, va_list args) { -#if defined(ANDROID) +#if defined(ANDROID) && !defined(V8_ANDROID_LOG_STDOUT) LOG_PRI_VA(ANDROID_LOG_INFO, LOG_TAG, format, args); #else vprintf(format, args); @@ -156,7 +156,7 @@ void OS::FPrint(FILE* out, const char* format, ...) { void OS::VFPrint(FILE* out, const char* format, va_list args) { -#if defined(ANDROID) +#if defined(ANDROID) && !defined(V8_ANDROID_LOG_STDOUT) LOG_PRI_VA(ANDROID_LOG_INFO, LOG_TAG, format, args); #else vfprintf(out, format, args); @@ -173,7 +173,7 @@ void OS::PrintError(const char* format, ...) { void OS::VPrintError(const char* format, va_list args) { -#if defined(ANDROID) +#if defined(ANDROID) && !defined(V8_ANDROID_LOG_STDOUT) LOG_PRI_VA(ANDROID_LOG_ERROR, LOG_TAG, format, args); #else vfprintf(stderr, format, args); -- 2.7.4