From 1cb99ea59b76a8d0f236f5220ef428ae4dfe0e67 Mon Sep 17 00:00:00 2001 From: Steven Moreland Date: Tue, 17 Sep 2019 16:08:09 -0700 Subject: [PATCH] libutils: Trace.h for everything but windows libcutils has trace implemented for host. In order to increase code portability, opening that up for libutils Trace.h usage as well. Bug: 124524556 Test: use Trace.h on host glinux Change-Id: Ia873f88e7436a18f6c0f761000bf697c68ffea17 --- libutils/include/utils/Trace.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/libutils/include/utils/Trace.h b/libutils/include/utils/Trace.h index 4b9c91ec5..fec0ffa82 100644 --- a/libutils/include/utils/Trace.h +++ b/libutils/include/utils/Trace.h @@ -17,7 +17,12 @@ #ifndef ANDROID_TRACE_H #define ANDROID_TRACE_H -#if defined(__ANDROID__) +#if defined(_WIN32) + +#define ATRACE_NAME(...) +#define ATRACE_CALL() + +#else // !_WIN32 #include @@ -51,11 +56,6 @@ private: } // namespace android -#else // !__ANDROID__ - -#define ATRACE_NAME(...) -#define ATRACE_CALL() - -#endif // __ANDROID__ +#endif // _WIN32 #endif // ANDROID_TRACE_H