aboutsummaryrefslogtreecommitdiffhomepage
path: root/site/user/build.md
diff options
context:
space:
mode:
authorGravatar Mike Klein <mtklein@chromium.org>2017-03-03 09:21:30 -0500
committerGravatar Mike Klein <mtklein@chromium.org>2017-03-03 15:41:24 +0000
commite459afd6ce2c2ccbad500dc2e77e0ac287af90eb (patch)
treec4f8fd5eb74eaefae0eb3731e3033106c8d70ae3 /site/user/build.md
parent05cb4c3e509449b0b7332ad563acfcb194b86a07 (diff)
Strengthen is_official_build, update docs.
This makes is_official_build turn off all development targets and features in Skia, including building third-party dependencies from source. This will intentionally break some external users, who will find themselves no longer able to find third-party headers or link against third-party libraries. These users have been building with our testing third-party dependencies unknowingly. They'll need to either explicitly turn back on building each dependency from source (skia_use_system_foo=false) or disable that dependency entirely (skia_use_foo=false). is_skia_standalone is now basically !is_official_build, so I've propagated that through, removing is_skia_standalone. In a few places we were using it as a stand-in for defined(ndk), so I've just written defined(ndk) there. Duh. gn_to_bp: is_offical_build's new strength also makes gn_to_bp.py simpler to write. In spirit, Android builds are official Skia builds that also build DM and nanobench. It seems that SkJumper (src/jumper/*) is (unintentionally) enabled on Android. Switching to an is_official_build would have disabled that. But as that accidental launch seems to have gone fine, I've kept it explicitly enabled. In the end, no changes to Android.bp or its SkUserConfig.h. The -Mini builder no longer needs to explicitly disable tools. CQ_INCLUDE_TRYBOTS=skia.primary:Build-Ubuntu-Clang-x86_64-Release-Mini Change-Id: Id06e53268a5caf55c6046ada354a0863c3031c73 Reviewed-on: https://skia-review.googlesource.com/9190 Reviewed-by: Leon Scroggins <scroggo@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
Diffstat (limited to 'site/user/build.md')
-rw-r--r--site/user/build.md46
1 files changed, 26 insertions, 20 deletions
diff --git a/site/user/build.md b/site/user/build.md
index 17f7857fe4..36ef63c89d 100644
--- a/site/user/build.md
+++ b/site/user/build.md
@@ -7,6 +7,32 @@ Skia](./download).
Skia uses [GN](https://chromium.googlesource.com/chromium/src/tools/gn/) to
configure its builds.
+`is_official_build` and Third-party Dependencies
+------------------------------------------------
+
+Most users of Skia should set `is_official_build=true`, and most developers
+should leave it to its `false` default.
+
+This mode configures Skia in a way that's suitable to ship: an optimized build
+with no debug symbols, dynamically linked against its third-party dependencies
+using the ordinary library search path.
+
+In contrast, the developer-oriented default is an unoptimized build with full
+debug symbols and all third-party dependencies built from source and embedded
+into libskia. This is how do all our manual and automated testing.
+
+Skia offers several features that make use of third-party libraries, like
+libpng, libwebp, or libjpeg-turbo to decode images, or ICU and sftnly to subset
+fonts. All these third-party dependencies are optional and can be controlled
+by a GN argument that looks something like `skia_use_foo` for appropriate
+`foo`.
+
+If `skia_use_foo` is enabled, enabling `skia_use_system_foo` will build and
+link Skia against the headers and libaries found on the system paths.
+`is_official_build=true` enables all `skia_use_system_foo` by default. You can
+use `extra_cflags` and `extra_ldflags` to add include or library paths if
+needed.
+
Quickstart
----------
@@ -142,23 +168,3 @@ We have added a GN-to-CMake translator mainly for use with IDEs that like CMake
project descriptions. This is not meant for any purpose beyond development.
bin/gn gen out/config --ide=json --json-ide-script=../../gn/gn_to_cmake.py
-
-Third-party Dependencies
-------------------------
-
-Skia offers several features that make use of third-party libraries, like
-libpng, libwebp, or libjpeg-turbo to decode images, or ICU and sftnly to subset
-fonts. All these third-party dependencies are optional, and can be controlled
-by a GN argument that looks something like `skia_use_foo` for appropriate
-`foo`.
-
-Most of these third-party dependencies can also be satisfied by pre-built
-system libraries. If `skia_use_foo` is enabled, turn on `skia_use_system_foo`
-to build and link Skia against the headers and libaries found on the system
-paths. You can use `extra_cflags` and `extra_ldflags` to add include or
-library paths if needed.
-
-By default Skia will build and embed its own copies of these third-party
-libraries. This configuration is for development only. We do not recommend
-shipping Skia this way. However, this is the only configuration of Skia that
-receives significant testing.