blob: c39688cb8f2d5afb0fd287c5c2f8456471d3c741 [file] [log] [blame]
Eric Holkc4239ac2018-09-05 10:43:31 -07001//
2// Copyright (C) 2018 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
Eric Holkdbc36e22018-09-20 12:03:10 -070017cc_defaults {
18 name: "viewcompiler_defaults",
Eric Holkfaefd4f2018-10-11 16:25:57 -070019 header_libs: [
20 "libbase_headers",
21 ],
Eric Holkdbc36e22018-09-20 12:03:10 -070022 shared_libs: [
Eric Holkfaefd4f2018-10-11 16:25:57 -070023 "libbase",
Eric Holkdbc36e22018-09-20 12:03:10 -070024 "libdexfile",
25 "slicer",
26 ],
Eric Holkfaefd4f2018-10-11 16:25:57 -070027 cppflags: ["-std=c++17"],
Eric Holkdbc36e22018-09-20 12:03:10 -070028}
29
Eric Holkc4239ac2018-09-05 10:43:31 -070030cc_library_host_static {
31 name: "libviewcompiler",
Eric Holkdbc36e22018-09-20 12:03:10 -070032 defaults: ["viewcompiler_defaults"],
Eric Holkc4239ac2018-09-05 10:43:31 -070033 srcs: [
Eric Holkdbc36e22018-09-20 12:03:10 -070034 "dex_builder.cc",
Eric Holkc4239ac2018-09-05 10:43:31 -070035 "java_lang_builder.cc",
36 "util.cc",
37 ],
Eric Holkc4239ac2018-09-05 10:43:31 -070038}
39
40cc_binary_host {
41 name: "viewcompiler",
Eric Holkdbc36e22018-09-20 12:03:10 -070042 defaults: ["viewcompiler_defaults"],
Eric Holkc4239ac2018-09-05 10:43:31 -070043 srcs: [
44 "main.cc",
45 ],
46 static_libs: [
Eric Holkc4239ac2018-09-05 10:43:31 -070047 "libtinyxml2",
48 "libgflags",
49 "libviewcompiler",
50 ],
51}
52
53cc_test_host {
54 name: "view-compiler-tests",
Eric Holkdbc36e22018-09-20 12:03:10 -070055 defaults: ["viewcompiler_defaults"],
Eric Holkc4239ac2018-09-05 10:43:31 -070056 srcs: [
Eric Holkdbc36e22018-09-20 12:03:10 -070057 "dex_builder_test.cc",
Eric Holkc4239ac2018-09-05 10:43:31 -070058 "util_test.cc",
59 ],
60 static_libs: [
61 "libviewcompiler",
Eric Holkdbc36e22018-09-20 12:03:10 -070062 ],
Eric Holkfaefd4f2018-10-11 16:25:57 -070063 test_suites: ["general-tests"],
Eric Holkc4239ac2018-09-05 10:43:31 -070064}