1// 2// Copyright (C) 2020 The Android Open Source Project 3// 4// Licensed under the Apache License, Version 2.0 (the "License"); 5// you may not use this file except in compliance with the License. 6// You may obtain a copy of the License at 7// 8// http://www.apache.org/licenses/LICENSE-2.0 9// 10// Unless required by applicable law or agreed to in writing, software 11// distributed under the License is distributed on an "AS IS" BASIS, 12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13// See the License for the specific language governing permissions and 14// limitations under the License. 15// 16 17// The Java S2 geometry lib. 18package { 19 default_applicable_licenses: ["external_s2-geometry-library-java_license"], 20} 21 22// Added automatically by a large-scale-change 23// See: http://go/android-license-faq 24license { 25 name: "external_s2-geometry-library-java_license", 26 visibility: [":__subpackages__"], 27 license_kinds: [ 28 "SPDX-license-identifier-Apache-2.0", 29 ], 30 license_text: [ 31 "LICENSE", 32 ], 33} 34 35java_library { 36 name: "s2-geometry-library-java", 37 host_supported: true, 38 sdk_version: "30", 39 srcs: ["src/**/*.java"], 40 static_libs: [ 41 "guava", 42 ], 43 apex_available: [ 44 "//apex_available:platform", 45 "com.android.geotz", 46 ], 47} 48 49// A bundle of the S2 geometry lib and its tests. 50// 51// atest --host s2-geometry-library-java-tests 52java_test { 53 name: "s2-geometry-library-java-tests", 54 host_supported: true, 55 sdk_version: "current", 56 srcs: ["tests/**/*.java"], 57 static_libs: [ 58 "s2-geometry-library-java", 59 ], 60 libs: [ 61 "junit", 62 ], 63 test_suites: ["general-tests"], 64} 65 66// Device tests: atest S2GeometryLibraryJavaTests 67android_test { 68 name: "S2GeometryLibraryJavaTests", 69 sdk_version: "current", 70 manifest: "AndroidManifest.xml", 71 static_libs: [ 72 "s2-geometry-library-java-tests", 73 "androidx.test.rules", 74 "junit", 75 ], 76} 77