• Daniel Bratell's avatar
    Fixing dependency problem for the mojo Range class · 8e397e63
    Daniel Bratell authored
    The mojo Range class needs range_struct_traits.h and the build
    system wasn't setup to allow that. Simplest for everyone is to integrate
    the struct_traits target into the mojom target and let the mojo system
    figure out dependencies. This made everything simpler.
    
    Without this fix you got errors like the one below:
    
    ERROR at //out/Default/gen/content/common/input/input_handler.mojom-test-utils.cc:49:11: Can't include this header from here.
              ^--------------------------------------
    The target:
      //content/common:mojo_bindings
    is including a file from the target:
      //ui/gfx/range/mojo:struct_traits
    
    It's usually best to depend directly on the destination target.
    In some cases, the destination target is considered a subcomponent
    of an intermediate target. In this case, the intermediate target
    should depend publicly on the destination to forward the ability
    to include headers.
    
    Dependency chain (there may also be others):
      //content/common:mojo_bindings -->
      //services/ws/public/mojom/ime:ime --[private]-->
      //ui/gfx/range/mojo:struct_traits
    
    Bug: 938893
    Change-Id: If01554d38ca3d5f4280d32c658d1f7044f14c29e
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1536056Reviewed-by: default avatarDaniel Cheng <dcheng@chromium.org>
    Reviewed-by: default avatarSadrul Chowdhury <sadrul@chromium.org>
    Commit-Queue: Daniel Bratell <bratell@opera.com>
    Cr-Commit-Position: refs/heads/master@{#644390}
    8e397e63
BUILD.gn 742 Bytes