aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--tensorflow/core/platform/default/stacktrace.h3
-rw-r--r--tensorflow/core/platform/stacktrace_handler.cc4
2 files changed, 4 insertions, 3 deletions
diff --git a/tensorflow/core/platform/default/stacktrace.h b/tensorflow/core/platform/default/stacktrace.h
index 11ac21f229..436716d482 100644
--- a/tensorflow/core/platform/default/stacktrace.h
+++ b/tensorflow/core/platform/default/stacktrace.h
@@ -17,7 +17,8 @@ limitations under the License.
#define TENSORFLOW_CORE_PLATFORM_DEFAULT_STACKTRACE_H_
#include "tensorflow/core/platform/platform.h"
-#if defined(PLATFORM_POSIX) && (defined(__clang__) || defined(__GNUC__))
+#if !defined(IS_MOBILE_PLATFORM) && defined(PLATFORM_POSIX) && \
+ (defined(__clang__) || defined(__GNUC__))
#define TF_GENERATE_BACKTRACE
#endif
diff --git a/tensorflow/core/platform/stacktrace_handler.cc b/tensorflow/core/platform/stacktrace_handler.cc
index 12dd4e5e87..ff31c97be0 100644
--- a/tensorflow/core/platform/stacktrace_handler.cc
+++ b/tensorflow/core/platform/stacktrace_handler.cc
@@ -15,8 +15,8 @@ limitations under the License.
#include "tensorflow/core/platform/platform.h"
-#if !defined(PLATFORM_GOOGLE) && defined(PLATFORM_POSIX) && \
- (defined(__clang__) || defined(__GNUC__))
+#if !defined(PLATFORM_GOOGLE) && !defined(IS_MOBILE_PLATFORM) && \
+ defined(PLATFORM_POSIX) && (defined(__clang__) || defined(__GNUC__))
#define TF_GENERATE_STACKTRACE
#endif