blob: 426464ea574e64d530bfee2211642e772fcb226c [file] [log] [blame]
Kohsuke Yatohbc718222021-01-31 23:48:46 -08001// Copyright (C) 2021 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
Bob Badourd5949582021-02-23 13:18:34 -080015package {
16 // See: http://go/android-license-faq
17 // A large-scale-change added 'default_applicable_licenses' to import
18 // all of the 'license_kinds' from "frameworks_base_license"
19 // to get the below license kinds:
20 // SPDX-license-identifier-Apache-2.0
21 default_applicable_licenses: ["frameworks_base_license"],
22}
23
Kohsuke Yatoh5ef0ea12021-06-25 21:48:03 +000024// An existing module name is reused to avoid merge conflicts.
25// TODO: fix the font and module name.
26filegroup {
27 name: "NotoColorEmojiTtf",
28 srcs: ["NotoColorEmoji.ttf"],
29}
30
Kohsuke Yatohbc718222021-01-31 23:48:46 -080031filegroup {
32 name: "UpdatableSystemFontTestKeyPem",
33 srcs: ["UpdatableSystemFontTestKey.pem"],
34}
35
36filegroup {
37 name: "UpdatableSystemFontTestCertPem",
38 srcs: ["UpdatableSystemFontTestCert.pem"],
39}
40
41filegroup {
42 name: "UpdatableSystemFontTestCertDer",
43 srcs: ["UpdatableSystemFontTestCert.der"],
44}
45
46genrule_defaults {
47 name: "updatable_system_font_increment_font_revision_default",
Kohsuke Yatohbd636d82021-04-08 12:54:29 -070048}
49
50genrule {
51 name: "UpdatableSystemFontTestNotoColorEmojiV0Ttf",
52 srcs: [":NotoColorEmojiTtf"],
53 out: ["UpdatableSystemFontTestNotoColorEmojiV0.ttf"],
54 tools: ["update_font_metadata"],
55 cmd: "$(location update_font_metadata) " +
56 "--input=$(in) " +
57 "--output=$(out) " +
58 "--revision=0",
59}
60
61genrule {
62 name: "UpdatableSystemFontTestNotoColorEmojiVPlus1Ttf",
63 srcs: [":NotoColorEmojiTtf"],
64 out: ["UpdatableSystemFontTestNotoColorEmojiVPlus1.ttf"],
Kohsuke Yatohbc718222021-01-31 23:48:46 -080065 tools: ["update_font_metadata"],
66 cmd: "$(location update_font_metadata) " +
67 "--input=$(in) " +
68 "--output=$(out) " +
69 "--revision=+1",
70}
71
72genrule {
Kohsuke Yatohbd636d82021-04-08 12:54:29 -070073 name: "UpdatableSystemFontTestNotoColorEmojiVPlus2Ttf",
Kohsuke Yatohbc718222021-01-31 23:48:46 -080074 srcs: [":NotoColorEmojiTtf"],
Kohsuke Yatohbd636d82021-04-08 12:54:29 -070075 out: ["UpdatableSystemFontTestNotoColorEmojiVPlus2.ttf"],
76 tools: ["update_font_metadata"],
77 cmd: "$(location update_font_metadata) " +
78 "--input=$(in) " +
79 "--output=$(out) " +
80 "--revision=+2",
Kohsuke Yatohbc718222021-01-31 23:48:46 -080081}
82
83genrule_defaults {
84 name: "updatable_system_font_sig_gen_default",
85 tools: ["fsverity"],
Kohsuke Yatohbd636d82021-04-08 12:54:29 -070086 tool_files: [
87 ":UpdatableSystemFontTestKeyPem",
88 ":UpdatableSystemFontTestCertPem",
89 ],
Kohsuke Yatohbc718222021-01-31 23:48:46 -080090 cmd: "$(location fsverity) sign $(in) $(out) " +
91 "--key=$(location :UpdatableSystemFontTestKeyPem) " +
92 "--cert=$(location :UpdatableSystemFontTestCertPem) " +
93 "> /dev/null",
94}
95
96genrule {
97 name: "UpdatableSystemFontTestNotoColorEmojiTtfFsvSig",
98 defaults: ["updatable_system_font_sig_gen_default"],
99 srcs: [":NotoColorEmojiTtf"],
100 out: ["UpdatableSystemFontTestNotoColorEmoji.ttf.fsv_sig"],
101}
102
103genrule {
Kohsuke Yatohbd636d82021-04-08 12:54:29 -0700104 name: "UpdatableSystemFontTestNotoColorEmojiV0TtfFsvSig",
Kohsuke Yatohbc718222021-01-31 23:48:46 -0800105 defaults: ["updatable_system_font_sig_gen_default"],
Kohsuke Yatohbd636d82021-04-08 12:54:29 -0700106 srcs: [":UpdatableSystemFontTestNotoColorEmojiV0Ttf"],
107 out: ["UpdatableSystemFontTestNotoColorEmojiV0.ttf.fsv_sig"],
Kohsuke Yatohbc718222021-01-31 23:48:46 -0800108}
109
110genrule {
Kohsuke Yatohbd636d82021-04-08 12:54:29 -0700111 name: "UpdatableSystemFontTestNotoColorEmojiVPlus1TtfFsvSig",
Kohsuke Yatohbc718222021-01-31 23:48:46 -0800112 defaults: ["updatable_system_font_sig_gen_default"],
Kohsuke Yatohbd636d82021-04-08 12:54:29 -0700113 srcs: [":UpdatableSystemFontTestNotoColorEmojiVPlus1Ttf"],
114 out: ["UpdatableSystemFontTestNotoColorEmojiVPlus1.ttf.fsv_sig"],
115}
116
117genrule {
118 name: "UpdatableSystemFontTestNotoColorEmojiVPlus2TtfFsvSig",
119 defaults: ["updatable_system_font_sig_gen_default"],
120 srcs: [":UpdatableSystemFontTestNotoColorEmojiVPlus2Ttf"],
121 out: ["UpdatableSystemFontTestNotoColorEmojiVPlus2.ttf.fsv_sig"],
Kohsuke Yatohbc718222021-01-31 23:48:46 -0800122}