XFA: Sync build and documentation differences with master.

This Cl syncs the AUTHORS, and README.md and build scripts in XFA to match master where possible.

R=tsepez@chromium.org

Review URL: https://codereview.chromium.org/1415423002 .
diff --git a/AUTHORS b/AUTHORS
index 78aad77..c57cb51 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -10,8 +10,10 @@
 
 Andrey Khalyavin <halyavin@chromium.org>
 Brett Wilson <brettw@chromium.org>
+Bruce Dawson <brucedawson@chromium.org>
 Chris Palmer <palmer@chromium.org>
 Finnur Thorarinsson <finnur@chromium.org>
+Jiang Jiang <jiangj@opera.com>
 Jochen Eisinger <jochen@chromium.org>
 John Abd-El-Malek <jam@chromium.org>
 Julien Tinnes <jln@chromium.org>
@@ -25,8 +27,8 @@
 Raymes Khoury <raymes@chromium.org>
 Reid Kleckner <rnk@chromium.org>
 Robert Sesek <rsesek@chromium.org>
+Sam Clegg <sbc@chromium.org>
 Thomas Sepez <tsepez@chromium.org>
-Jiang Jiang <jiangj@opera.com>
 
 Foxit Software Inc <*@foxitsoftware.com>
 Google Inc. <*@google.com>
diff --git a/BUILD.gn b/BUILD.gn
index dfb7935..27a2b07 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -97,7 +97,10 @@
 
   libs = []
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 
   deps = [
     "third_party:bigint",
@@ -121,11 +124,18 @@
   }
 
   if (is_win) {
-    libs += [ "advapi32.lib", "gdi32.lib", "user32.lib" ]
+    libs += [
+      "advapi32.lib",
+      "gdi32.lib",
+      "user32.lib",
+    ]
   }
 
   if (is_mac) {
-    libs += [ "AppKit.framework", "CoreFoundation.framework" ]
+    libs += [
+      "AppKit.framework",
+      "CoreFoundation.framework",
+    ]
   }
 
   if (pdfium_bundle_freetype) {
@@ -183,7 +193,10 @@
     "core/src/fdrm/crypto/fx_crypt_sha.cpp",
   ]
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 }
 
 static_library("fpdfdoc") {
@@ -213,13 +226,14 @@
     "core/src/fpdfdoc/tagged_int.h",
   ]
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 }
 
-
 static_library("fpdfapi") {
   sources = [
-    "core/include/fpdfapi/fpdfapi.h",
     "core/include/fpdfapi/fpdf_module.h",
     "core/include/fpdfapi/fpdf_objects.h",
     "core/include/fpdfapi/fpdf_page.h",
@@ -228,12 +242,11 @@
     "core/include/fpdfapi/fpdf_render.h",
     "core/include/fpdfapi/fpdf_resource.h",
     "core/include/fpdfapi/fpdf_serial.h",
+    "core/include/fpdfapi/fpdfapi.h",
     "core/src/fpdfapi/fpdf_basic_module.cpp",
-    "core/src/fpdfapi/fpdf_cmaps/cmap_int.h",
     "core/src/fpdfapi/fpdf_cmaps/CNS1/Adobe-CNS1-UCS2_5.cpp",
     "core/src/fpdfapi/fpdf_cmaps/CNS1/B5pc-H_0.cpp",
     "core/src/fpdfapi/fpdf_cmaps/CNS1/B5pc-V_0.cpp",
-    "core/src/fpdfapi/fpdf_cmaps/CNS1/cmaps_cns1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/CNS1/CNS-EUC-H_0.cpp",
     "core/src/fpdfapi/fpdf_cmaps/CNS1/CNS-EUC-V_0.cpp",
     "core/src/fpdfapi/fpdf_cmaps/CNS1/ETen-B5-H_0.cpp",
@@ -245,9 +258,8 @@
     "core/src/fpdfapi/fpdf_cmaps/CNS1/UniCNS-UCS2-H_3.cpp",
     "core/src/fpdfapi/fpdf_cmaps/CNS1/UniCNS-UCS2-V_3.cpp",
     "core/src/fpdfapi/fpdf_cmaps/CNS1/UniCNS-UTF16-H_0.cpp",
-    "core/src/fpdfapi/fpdf_cmaps/fpdf_cmaps.cpp",
+    "core/src/fpdfapi/fpdf_cmaps/CNS1/cmaps_cns1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/GB1/Adobe-GB1-UCS2_5.cpp",
-    "core/src/fpdfapi/fpdf_cmaps/GB1/cmaps_gb1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/GB1/GB-EUC-H_0.cpp",
     "core/src/fpdfapi/fpdf_cmaps/GB1/GB-EUC-V_0.cpp",
     "core/src/fpdfapi/fpdf_cmaps/GB1/GBK-EUC-H_2.cpp",
@@ -260,6 +272,7 @@
     "core/src/fpdfapi/fpdf_cmaps/GB1/GBpc-EUC-V_0.cpp",
     "core/src/fpdfapi/fpdf_cmaps/GB1/UniGB-UCS2-H_4.cpp",
     "core/src/fpdfapi/fpdf_cmaps/GB1/UniGB-UCS2-V_4.cpp",
+    "core/src/fpdfapi/fpdf_cmaps/GB1/cmaps_gb1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Japan1/83pv-RKSJ-H_1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Japan1/90ms-RKSJ-H_2.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Japan1/90ms-RKSJ-V_2.cpp",
@@ -269,7 +282,6 @@
     "core/src/fpdfapi/fpdf_cmaps/Japan1/Add-RKSJ-H_1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Japan1/Add-RKSJ-V_1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Japan1/Adobe-Japan1-UCS2_4.cpp",
-    "core/src/fpdfapi/fpdf_cmaps/Japan1/cmaps_japan1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Japan1/EUC-H_1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Japan1/EUC-V_1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Japan1/Ext-RKSJ-H_2.cpp",
@@ -280,8 +292,8 @@
     "core/src/fpdfapi/fpdf_cmaps/Japan1/UniJIS-UCS2-H_4.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Japan1/UniJIS-UCS2-V_4.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Japan1/V_1.cpp",
+    "core/src/fpdfapi/fpdf_cmaps/Japan1/cmaps_japan1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Korea1/Adobe-Korea1-UCS2_2.cpp",
-    "core/src/fpdfapi/fpdf_cmaps/Korea1/cmaps_korea1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Korea1/KSC-EUC-H_0.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Korea1/KSC-EUC-V_0.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Korea1/KSCms-UHC-HW-H_1.cpp",
@@ -292,6 +304,9 @@
     "core/src/fpdfapi/fpdf_cmaps/Korea1/UniKS-UCS2-H_1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Korea1/UniKS-UCS2-V_1.cpp",
     "core/src/fpdfapi/fpdf_cmaps/Korea1/UniKS-UTF16-H_0.cpp",
+    "core/src/fpdfapi/fpdf_cmaps/Korea1/cmaps_korea1.cpp",
+    "core/src/fpdfapi/fpdf_cmaps/cmap_int.h",
+    "core/src/fpdfapi/fpdf_cmaps/fpdf_cmaps.cpp",
     "core/src/fpdfapi/fpdf_edit/editint.h",
     "core/src/fpdfapi/fpdf_edit/fpdf_edit_content.cpp",
     "core/src/fpdfapi/fpdf_edit/fpdf_edit_create.cpp",
@@ -333,7 +348,10 @@
     "core/src/fpdfapi/fpdf_render/render_int.h",
   ]
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 }
 
 static_library("fpdftext") {
@@ -349,7 +367,10 @@
     "core/src/fpdftext/unicodenormalizationdata.h",
   ]
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 }
 
 static_library("fxcodec") {
@@ -431,7 +452,19 @@
     # conversion to check that an address is 16-bit aligned (benign).
     cflags_c = [ "-Wno-pointer-to-int-cast" ]
   }
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
+}
+
+config("fxge_warnings") {
+  if (is_clang) {
+    cflags = [
+      # http://code.google.com/p/pdfium/issues/detail?id=188
+      "-Wno-switch",
+    ]
+  }
 }
 
 static_library("fxcrt") {
@@ -448,12 +481,6 @@
     "core/include/fxcrt/fx_ucd.h",
     "core/include/fxcrt/fx_xml.h",
     "core/src/fxcrt/extension.h",
-    "core/src/fxcrt/fxcrt_platforms.cpp",
-    "core/src/fxcrt/fxcrt_platforms.h",
-    "core/src/fxcrt/fxcrt_posix.cpp",
-    "core/src/fxcrt/fxcrt_posix.h",
-    "core/src/fxcrt/fxcrt_windows.cpp",
-    "core/src/fxcrt/fxcrt_windows.h",
     "core/src/fxcrt/fx_arabic.cpp",
     "core/src/fxcrt/fx_arabic.h",
     "core/src/fxcrt/fx_basic_array.cpp",
@@ -473,11 +500,20 @@
     "core/src/fxcrt/fx_unicode.cpp",
     "core/src/fxcrt/fx_xml_composer.cpp",
     "core/src/fxcrt/fx_xml_parser.cpp",
+    "core/src/fxcrt/fxcrt_platforms.cpp",
+    "core/src/fxcrt/fxcrt_platforms.h",
+    "core/src/fxcrt/fxcrt_posix.cpp",
+    "core/src/fxcrt/fxcrt_posix.h",
+    "core/src/fxcrt/fxcrt_windows.cpp",
+    "core/src/fxcrt/fxcrt_windows.h",
     "core/src/fxcrt/plex.h",
     "core/src/fxcrt/xml_int.h",
   ]
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 }
 
 static_library("fxge") {
@@ -544,7 +580,11 @@
   ]
 
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":fxge_warnings",
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 
   if (pdf_use_skia) {
     sources = [
@@ -594,7 +634,10 @@
     "fpdfsdk/src/fxedit/fxet_pageobjs.cpp",
   ]
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 }
 
 static_library("pdfwindow") {
@@ -637,7 +680,10 @@
     "fpdfsdk/src/pdfwindow/PWL_Wnd.cpp",
   ]
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 }
 
 static_library("javascript") {
@@ -728,7 +774,10 @@
     "fpdfsdk/src/formfiller/FFL_TextField.cpp",
   ]
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 }
 
 static_library("fpdfxfa") {
@@ -1443,7 +1492,10 @@
   ]
   include_dirs = [ "." ]
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 }
 
 test("pdfium_embeddertests") {
@@ -1485,5 +1537,8 @@
     ]
   }
   configs -= [ "//build/config/compiler:chromium_code" ]
-  configs += [ ":pdfium_config", "//build/config/compiler:no_chromium_code" ]
+  configs += [
+    ":pdfium_config",
+    "//build/config/compiler:no_chromium_code",
+  ]
 }
diff --git a/README b/README
deleted file mode 100644
index 3a2cbde..0000000
--- a/README
+++ /dev/null
@@ -1 +0,0 @@
-For build instructions visit https://code.google.com/p/pdfium/wiki/Build
\ No newline at end of file
diff --git a/docs/build.md b/README.md
similarity index 92%
rename from docs/build.md
rename to README.md
index a32f9fb..67d8448 100644
--- a/docs/build.md
+++ b/README.md
@@ -33,8 +33,8 @@
 Most PDFium developers use Ninja, as does our [continuous build system]
 (http://build.chromium.org/p/client.pdfium/).
 
- * On Windows: `build\gyp\_pdfium`
- * For all other platforms: `build/gyp\_pdfium`
+ * On Windows: `build\gyp_pdfium`
+ * For all other platforms: `build/gyp_pdfium`
 
 The second option is to generate platform-specific build files, i.e. Makefiles
 on Linux, sln files on Windows, and xcodeproj files on Mac. To do so, set the
@@ -44,12 +44,12 @@
 ## Building the code
 
 If you used Ninja, you can build the sample program by: `ninja -C out/Debug
-pdfium\_test` You can build the entire product (which includes a few unit
+pdfium_test` You can build the entire product (which includes a few unit
 tests) by: `ninja -C out/Debug`.
 
 If you're not using Ninja, then building is platform-specific.
 
- * On Linux: `make pdfium\_test`
+ * On Linux: `make pdfium_test`
  * On Mac: `open build/all.xcodeproj`
  * On Windows: open build\all.sln
 
@@ -57,7 +57,7 @@
 
 The pdfium\_test program supports reading, parsing, and rasterizing the pages of
 a .pdf file to .ppm or .png output image files (windows supports two other
-formats). For example: `out/Debug/pdfium\_test --ppm path/to/myfile.pdf`. Note
+formats). For example: `out/Debug/pdfium_test --ppm path/to/myfile.pdf`. Note
 that this will write output images to `path/to/myfile.pdf.<n>.ppm`.
 
 ## Testing
diff --git a/pdfium.gni b/pdfium.gni
index afb1d7b..7f08c71 100644
--- a/pdfium.gni
+++ b/pdfium.gni
@@ -18,4 +18,3 @@
   # Build PDFium against skia (experimental) rather than agg.
   pdf_use_skia = false
 }
-
diff --git a/pdfium.gyp b/pdfium.gyp
index edb9424..86e14da 100644
--- a/pdfium.gyp
+++ b/pdfium.gyp
@@ -534,6 +534,12 @@
         'core/src/fxge/ge/fx_ge_text.cpp',
         'core/src/fxge/ge/text_int.h',
       ],
+      'variables': {
+        'clang_warning_flags': [
+          # http://code.google.com/p/pdfium/issues/detail?id=188
+          '-Wno-switch',
+        ],
+      },
       'conditions': [
         ['pdf_use_skia==1', {
           'sources': [
@@ -770,8 +776,8 @@
         'core/src/fxcrt/fx_basic_memmgr_unittest.cpp',
         'core/src/fxcrt/fx_basic_wstring_unittest.cpp',
         'core/src/fxcrt/fx_system_unittest.cpp',
-        'testing/fx_string_testhelpers.cpp',
         'testing/fx_string_testhelpers.h',
+        'testing/fx_string_testhelpers.cpp',
         'third_party/base/nonstd_unique_ptr_unittest.cpp',
       ],
       'conditions': [