xref: /aosp_15_r20/external/cronet/build/android/gradle/java.jinja (revision 6777b5387eb2ff775bb5750e3f5d96f37fb7352b)
1{# Copyright 2016 The Chromium Authors #}
2{# Use of this source code is governed by a BSD-style license that can be #}
3{# found in the LICENSE file. #}
4// Generated by //build/android/generate_gradle.py
5
6apply plugin: "java"
7{% if template_type == 'java_binary' %}
8apply plugin: "application"
9{% endif %}
10
11sourceSets {
12    main {
13        java.srcDirs = [
14{% for path in main.java_dirs %}
15            "{{ path }}",
16{% endfor %}
17        ]
18{% if main.java_excludes is defined %}
19        java.filter.exclude([
20{% for path in main.java_excludes %}
21            "{{ path }}",
22{% endfor %}
23        ])
24{% endif %}
25    }
26}
27
28sourceCompatibility = JavaVersion.VERSION_17
29targetCompatibility = JavaVersion.VERSION_17
30
31{% if template_type == 'java_binary' %}
32applicationName = "{{ target_name }}"
33{% if main_class %}
34mainClassName = "{{ main_class }}"
35{% endif %}
36{% endif %}
37{% if template_type in ('java_binary', 'java_library') %}
38archivesBaseName = "{{ target_name }}"
39{% endif %}
40
41{% include 'dependencies.jinja' %}
42