aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar djsollen <djsollen@google.com>2016-08-05 13:04:41 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2016-08-05 13:04:41 -0700
commit300405a7a21aea994061fc0fabaf13465fb31f09 (patch)
tree4bc7fb05049e0a6ac13307209f7a4290c2f65ff5
parent1ec04d9553af68b458c8dd6bd18d8c25ebd41d7a (diff)
Enable SK_DEBUG/SK_RELEASE to be defined in the user config.
-rw-r--r--include/core/SkPostConfig.h8
-rw-r--r--include/core/SkPreConfig.h10
2 files changed, 8 insertions, 10 deletions
diff --git a/include/core/SkPostConfig.h b/include/core/SkPostConfig.h
index fa65ee6d47..b67c863887 100644
--- a/include/core/SkPostConfig.h
+++ b/include/core/SkPostConfig.h
@@ -14,6 +14,14 @@
# define SK_BUILD_FOR_WIN
#endif
+#if !defined(SK_DEBUG) && !defined(SK_RELEASE)
+ #ifdef NDEBUG
+ #define SK_RELEASE
+ #else
+ #define SK_DEBUG
+ #endif
+#endif
+
#if defined(SK_DEBUG) && defined(SK_RELEASE)
# error "cannot define both SK_DEBUG and SK_RELEASE"
#elif !defined(SK_DEBUG) && !defined(SK_RELEASE)
diff --git a/include/core/SkPreConfig.h b/include/core/SkPreConfig.h
index d8dd65b910..94d48b6dd5 100644
--- a/include/core/SkPreConfig.h
+++ b/include/core/SkPreConfig.h
@@ -52,14 +52,6 @@
//////////////////////////////////////////////////////////////////////
-#if !defined(SK_DEBUG) && !defined(SK_RELEASE)
- #ifdef NDEBUG
- #define SK_RELEASE
- #else
- #define SK_DEBUG
- #endif
-#endif
-
#ifdef SK_BUILD_FOR_WIN32
#if !defined(SK_RESTRICT)
#define SK_RESTRICT __restrict
@@ -69,8 +61,6 @@
#endif
#endif
-//////////////////////////////////////////////////////////////////////
-
#if !defined(SK_RESTRICT)
#define SK_RESTRICT __restrict__
#endif