Introduce GN config pdfium_noshorten_config

Avoid conditionals every time this is used in BUILD.gn files.

Change-Id: Ic6214b4763350b27c9fd51a255d27f70ee629ab6
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/90631
Auto-Submit: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
diff --git a/BUILD.gn b/BUILD.gn
index 3276689..c344c9b 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -289,6 +289,13 @@
   ]
 }
 
+config("pdfium_noshorten_config") {
+  cflags = []
+  if (is_clang) {
+    cflags += [ "-Wshorten-64-to-32" ]
+  }
+}
+
 source_set("pdfium_public_headers_impl") {
   sources = [
     "public/cpp/fpdf_deleters.h",