Avoid ODR violations when building fuzzers in component builds.

Avoid depending on both the specific bits being fuzzed and on
libpdfium.so, which would link in two copies of certain objects.

Bug: chromium:1217515,chromium:1218073
Change-Id: Icd1b9712937ea71ce887dc61c2a30d7722d1f36a
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/81770
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
diff --git a/testing/fuzzers/BUILD.gn b/testing/fuzzers/BUILD.gn
index 8cbec03..0f88d23 100644
--- a/testing/fuzzers/BUILD.gn
+++ b/testing/fuzzers/BUILD.gn
@@ -89,7 +89,10 @@
   testonly = true
   sources = [ "pdf_fuzzer_init.cc" ]
   include_dirs = [ "../.." ]
-  deps = [ "../../:pdfium_public_headers" ]
+  deps = [
+    "../../:pdfium_public_headers",
+    "../../fpdfsdk",
+  ]
 }
 
 if (pdf_enable_xfa) {
@@ -115,6 +118,7 @@
   deps = [
     ":fuzzer_utils",
     "../../:pdfium_public_headers",
+    "../../fpdfsdk",
   ]
   if (pdf_enable_v8) {
     configs += [ "//v8:external_startup_data" ]
@@ -150,6 +154,7 @@
   configs += [ ":fuzzer_config" ]
   deps = [
     "../../:pdfium_public_headers",
+    "../../fpdfsdk",
     "../../third_party:pdfium_base",
   ]
 }
@@ -189,7 +194,7 @@
       testonly = true
       sources = [ "component_fuzzer_template.cc" ]
       deps = [
-        "../../:pdfium",
+        "../../:pdfium_public_headers",
         init_dep,
       ]
       configs += [ ":fuzzer_config" ]