1// Copyright (C) 2020 The Android Open Source Project 2// 3// Licensed under the Apache License, Version 2.0 (the "License"); 4// you may not use this file except in compliance with the License. 5// You may obtain a copy of the License at 6// 7// http://www.apache.org/licenses/LICENSE-2.0 8// 9// Unless required by applicable law or agreed to in writing, software 10// distributed under the License is distributed on an "AS IS" BASIS, 11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12// See the License for the specific language governing permissions and 13// limitations under the License. 14 15// A library containing common code within the geolocation dir. 16package { 17 default_applicable_licenses: ["Android-Apache-2.0"], 18} 19 20// Code intended for host usage only. 21java_library_host { 22 name: "geotz_host_common", 23 srcs: ["host/main/java/**/*.java"], 24} 25 26// Code intended for device or host usage. 27java_library { 28 name: "geotz_common", 29 host_supported: true, 30 srcs: ["src/main/java/**/*.java"], 31 libs: ["androidx.annotation_annotation"], 32 sdk_version: "31", 33 min_sdk_version: "31", 34 apex_available: [ 35 "com.android.geotz", 36 ], 37} 38 39// Device side tests for the geotz_common code. 40android_test { 41 name: "GeotzCommonTests", 42 srcs: ["src/test/java/**/*.java"], 43 manifest: "src/test/AndroidManifest.xml", 44 sdk_version: "31", 45 min_sdk_version: "31", 46 static_libs: [ 47 "androidx.test.runner", 48 "geotz_lookup", 49 "junit", 50 "truth-prebuilt", 51 ], 52 test_suites: ["general-tests"], 53} 54