summaryrefslogtreecommitdiff
path: root/chromium/components/external_intents/android/BUILD.gn
blob: 2eccc0ef9a0add5185cb474d8803b0588519c817 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
# Copyright 2020 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

import("//build/config/android/rules.gni")

android_library("java") {
  sources = [
    "java/src/org/chromium/components/external_intents/AuthenticatorNavigationInterceptor.java",
    "java/src/org/chromium/components/external_intents/ExternalIntentsFeatureList.java",
    "java/src/org/chromium/components/external_intents/ExternalIntentsSwitches.java",
    "java/src/org/chromium/components/external_intents/ExternalNavigationDelegate.java",
    "java/src/org/chromium/components/external_intents/ExternalNavigationHandler.java",
    "java/src/org/chromium/components/external_intents/ExternalNavigationParams.java",
    "java/src/org/chromium/components/external_intents/InterceptNavigationDelegateClient.java",
    "java/src/org/chromium/components/external_intents/InterceptNavigationDelegateImpl.java",
    "java/src/org/chromium/components/external_intents/RedirectHandler.java",
  ]

  annotation_processor_deps = [ "//base/android/jni_generator:jni_processor" ]
  deps = [
    ":java_resources",
    "//base:base_java",
    "//base:jni_java",
    "//components/embedder_support/android:util_java",
    "//components/navigation_interception/android:navigation_interception_java",
    "//components/webapk/android/libs/client:java",
    "//content/public/android:content_java",
    "//services/network/public/mojom:mojom_java",
    "//third_party/android_deps:androidx_annotation_annotation_java",
    "//third_party/android_deps:androidx_appcompat_appcompat_java",
    "//ui/android:ui_java",
    "//url:gurl_java",
    "//url:origin_java",
  ]
  resources_package = "org.chromium.components.external_intents"
}

android_resources("java_resources") {
  sources = []
  deps = [
    "//components/browser_ui/strings/android:browser_ui_strings_grd",
    "//components/browser_ui/styles/android:java_resources",
  ]
}

generate_jni("jni_headers") {
  sources = [
    "java/src/org/chromium/components/external_intents/ExternalIntentsFeatureList.java",
    "java/src/org/chromium/components/external_intents/InterceptNavigationDelegateImpl.java",
  ]
}

static_library("android") {
  sources = [
    "external_intents_feature_list.cc",
    "external_intents_feature_list.h",
    "intercept_navigation_delegate_impl.cc",
  ]

  deps = [
    ":jni_headers",
    "//base",
    "//components/navigation_interception",
    "//content/public/browser",
  ]
}

android_library("javatests") {
  testonly = true

  sources = [
    "javatests/src/org/chromium/components/external_intents/ExternalNavigationHandlerTest.java",
    "javatests/src/org/chromium/components/external_intents/RedirectHandlerTest.java",
  ]
  deps = [
    ":java",
    "//base:base_java",
    "//base:base_java_test_support",
    "//content/public/android:content_java",
    "//content/public/test/android:content_java_test_support",
    "//third_party/android_deps:androidx_core_core_java",
    "//third_party/android_deps:androidx_test_runner_java",
    "//third_party/android_sdk:android_test_mock_java",
    "//third_party/android_sdk/androidx_browser:androidx_browser_java",
    "//third_party/android_support_test_runner:runner_java",
    "//third_party/junit",
    "//ui/android:ui_java",
    "//url:origin_java",
  ]
}