Reland "SkSL CPP and H backends no longer emitted in non-dev builds"
This is a reland of bc6fb279fe9714947ecd1fadcff22ef84785c349
Original change's description:
> SkSL CPP and H backends no longer emitted in non-dev builds
>
> As these backends are never used at runtime, it's pointless to include
> them in the Skia binaries. We still include them in GR_TEST_UTILS mode
> to support unit tests.
>
> Change-Id: I9ec9cc9300b74c501985656323ec894008255a70
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311454
> Commit-Queue: Brian Osman <brianosman@google.com>
> Reviewed-by: John Stiles <johnstiles@google.com>
> Reviewed-by: Brian Osman <brianosman@google.com>
Change-Id: I214d6d952befbe77f301cf252fe4795f8c411a76
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312242
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
diff --git a/src/sksl/SkSLCPPCodeGenerator.cpp b/src/sksl/SkSLCPPCodeGenerator.cpp
index 5f9b821..478f0f5 100644
--- a/src/sksl/SkSLCPPCodeGenerator.cpp
+++ b/src/sksl/SkSLCPPCodeGenerator.cpp
@@ -15,6 +15,8 @@
#include <algorithm>
+#if defined(SKSL_STANDALONE) || defined(GR_TEST_UTILS)
+
namespace SkSL {
static bool needs_uniform_var(const Variable& var) {
@@ -1393,3 +1395,5 @@
}
} // namespace SkSL
+
+#endif // defined(SKSL_STANDALONE) || defined(GR_TEST_UTILS)