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 "com.android.geotz", 45 ], 46} 47 48// A bundle of the S2 geometry lib and its tests. 49// 50// atest --host s2-geometry-library-java-tests 51java_test { 52 name: "s2-geometry-library-java-tests", 53 host_supported: true, 54 sdk_version: "current", 55 srcs: ["tests/**/*.java"], 56 static_libs: [ 57 "s2-geometry-library-java", 58 ], 59 libs: [ 60 "junit", 61 ], 62 test_suites: ["general-tests"], 63} 64 65// Device tests: atest S2GeometryLibraryJavaTests 66android_test { 67 name: "S2GeometryLibraryJavaTests", 68 sdk_version: "current", 69 manifest: "AndroidManifest.xml", 70 static_libs: [ 71 "s2-geometry-library-java-tests", 72 "androidx.test.rules", 73 "junit", 74 ], 75} 76