1*2fd832c6SAndroid Build Coastguard Worker// Copyright (C) 2019 The Android Open Source Project 2*2fd832c6SAndroid Build Coastguard Worker// 3*2fd832c6SAndroid Build Coastguard Worker// Licensed under the Apache License, Version 2.0 (the "License"); 4*2fd832c6SAndroid Build Coastguard Worker// you may not use this file except in compliance with the License. 5*2fd832c6SAndroid Build Coastguard Worker// You may obtain a copy of the License at 6*2fd832c6SAndroid Build Coastguard Worker// 7*2fd832c6SAndroid Build Coastguard Worker// http://www.apache.org/licenses/LICENSE-2.0 8*2fd832c6SAndroid Build Coastguard Worker// 9*2fd832c6SAndroid Build Coastguard Worker// Unless required by applicable law or agreed to in writing, software 10*2fd832c6SAndroid Build Coastguard Worker// distributed under the License is distributed on an "AS IS" BASIS, 11*2fd832c6SAndroid Build Coastguard Worker// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12*2fd832c6SAndroid Build Coastguard Worker// See the License for the specific language governing permissions and 13*2fd832c6SAndroid Build Coastguard Worker// limitations under the License. 14*2fd832c6SAndroid Build Coastguard Worker 15*2fd832c6SAndroid Build Coastguard Workerpackage { 16*2fd832c6SAndroid Build Coastguard Worker default_applicable_licenses: ["system_timezone_output_data_iana_license"], 17*2fd832c6SAndroid Build Coastguard Worker} 18*2fd832c6SAndroid Build Coastguard Worker 19*2fd832c6SAndroid Build Coastguard Worker// Added automatically by a large-scale-change that took the approach of 20*2fd832c6SAndroid Build Coastguard Worker// 'apply every license found to every target'. While this makes sure we respect 21*2fd832c6SAndroid Build Coastguard Worker// every license restriction, it may not be entirely correct. 22*2fd832c6SAndroid Build Coastguard Worker// 23*2fd832c6SAndroid Build Coastguard Worker// e.g. GPL in an MIT project might only apply to the contrib/ directory. 24*2fd832c6SAndroid Build Coastguard Worker// 25*2fd832c6SAndroid Build Coastguard Worker// Please consider splitting the single license below into multiple licenses, 26*2fd832c6SAndroid Build Coastguard Worker// taking care not to lose any license_kind information, and overriding the 27*2fd832c6SAndroid Build Coastguard Worker// default license using the 'licenses: [...]' property on targets as needed. 28*2fd832c6SAndroid Build Coastguard Worker// 29*2fd832c6SAndroid Build Coastguard Worker// For unused files, consider creating a 'filegroup' with "//visibility:private" 30*2fd832c6SAndroid Build Coastguard Worker// to attach the license to, and including a comment whether the files may be 31*2fd832c6SAndroid Build Coastguard Worker// used in the current project. 32*2fd832c6SAndroid Build Coastguard Worker// http://go/android-license-faq 33*2fd832c6SAndroid Build Coastguard Workerlicense { 34*2fd832c6SAndroid Build Coastguard Worker name: "system_timezone_output_data_iana_license", 35*2fd832c6SAndroid Build Coastguard Worker visibility: [":__subpackages__"], 36*2fd832c6SAndroid Build Coastguard Worker license_kinds: [ 37*2fd832c6SAndroid Build Coastguard Worker "legacy_unencumbered", 38*2fd832c6SAndroid Build Coastguard Worker ], 39*2fd832c6SAndroid Build Coastguard Worker license_text: [ 40*2fd832c6SAndroid Build Coastguard Worker "NOTICE", 41*2fd832c6SAndroid Build Coastguard Worker ], 42*2fd832c6SAndroid Build Coastguard Worker} 43*2fd832c6SAndroid Build Coastguard Worker 44*2fd832c6SAndroid Build Coastguard Worker// Build rules related to the tzdata file. 45*2fd832c6SAndroid Build Coastguard Worker// tzdata is a binary file used by bionic functions like mktime / localtime and 46*2fd832c6SAndroid Build Coastguard Worker// Android's implementation of java.util.TimeZone, ZoneInfoDb. Both these users 47*2fd832c6SAndroid Build Coastguard Worker// look for the file in multiple locations. Also see the com.android.tzdata 48*2fd832c6SAndroid Build Coastguard Worker// APEX definition. 49*2fd832c6SAndroid Build Coastguard Worker 50*2fd832c6SAndroid Build Coastguard Worker// The on-device version of the tzdata file in /system/usr/share/zoneinfo/ 51*2fd832c6SAndroid Build Coastguard Worker// This is the ultimate fallback for bionic for situations where the 52*2fd832c6SAndroid Build Coastguard Worker// tzdata APEX is not mounted. For example, bionic in initd. It is also 53*2fd832c6SAndroid Build Coastguard Worker// referenced by old copies of bionic that may be statically linked 54*2fd832c6SAndroid Build Coastguard Worker// via the NDK. It is no longer used by ZoneInfoDb. 55*2fd832c6SAndroid Build Coastguard Workerprebuilt_usr_share { 56*2fd832c6SAndroid Build Coastguard Worker name: "tzdata_prebuilt", 57*2fd832c6SAndroid Build Coastguard Worker src: "tzdata", 58*2fd832c6SAndroid Build Coastguard Worker filename_from_src: true, 59*2fd832c6SAndroid Build Coastguard Worker sub_dir: "zoneinfo", 60*2fd832c6SAndroid Build Coastguard Worker} 61*2fd832c6SAndroid Build Coastguard Worker 62*2fd832c6SAndroid Build Coastguard Worker// The host version of the tzdata file equivalent to the definition above. 63*2fd832c6SAndroid Build Coastguard Worker// Used by bionic on host; bionic is being increasingly used on host for tooling. 64*2fd832c6SAndroid Build Coastguard Workerprebuilt_usr_share_host { 65*2fd832c6SAndroid Build Coastguard Worker name: "tzdata_host", 66*2fd832c6SAndroid Build Coastguard Worker src: "tzdata", 67*2fd832c6SAndroid Build Coastguard Worker filename_from_src: true, 68*2fd832c6SAndroid Build Coastguard Worker sub_dir: "zoneinfo", 69*2fd832c6SAndroid Build Coastguard Worker target: { 70*2fd832c6SAndroid Build Coastguard Worker darwin: { 71*2fd832c6SAndroid Build Coastguard Worker enabled: false, 72*2fd832c6SAndroid Build Coastguard Worker }, 73*2fd832c6SAndroid Build Coastguard Worker }, 74*2fd832c6SAndroid Build Coastguard Worker} 75*2fd832c6SAndroid Build Coastguard Worker 76*2fd832c6SAndroid Build Coastguard Workerprebuilt_root_host { 77*2fd832c6SAndroid Build Coastguard Worker name: "tzdata_host_tzdata_apex", 78*2fd832c6SAndroid Build Coastguard Worker src: "tzdata", 79*2fd832c6SAndroid Build Coastguard Worker filename_from_src: true, 80*2fd832c6SAndroid Build Coastguard Worker relative_install_path: "com.android.tzdata/etc/tz", 81*2fd832c6SAndroid Build Coastguard Worker} 82