blob: fbe61a4f46d9f70100bef4535b7d14e69f1e7d77 [file] [log] [blame]
Ivan Lozano183a3212019-10-18 14:18:45 -07001package cc
2
3import (
4 "github.com/google/blueprint"
5
6 "android/soong/android"
7)
8
9type LinkableInterface interface {
10 Module() android.Module
11 CcLibrary() bool
12 CcLibraryInterface() bool
13
Ivan Lozano183a3212019-10-18 14:18:45 -070014 OutputFile() android.OptionalPath
15
Ivan Lozanoe0833b12019-11-06 19:15:49 -080016 IncludeDirs() android.Paths
Ivan Lozano183a3212019-10-18 14:18:45 -070017 SetDepsInLinkOrder([]android.Path)
18 GetDepsInLinkOrder() []android.Path
19
20 HasStaticVariant() bool
21 GetStaticVariant() LinkableInterface
22
Ivan Lozano2b262972019-11-21 12:30:50 -080023 NonCcVariants() bool
24
Ivan Lozano183a3212019-10-18 14:18:45 -070025 StubsVersions() []string
Ivan Lozano52767be2019-10-18 14:49:46 -070026 BuildStubs() bool
Ivan Lozano183a3212019-10-18 14:18:45 -070027 SetBuildStubs()
28 SetStubsVersions(string)
Jooyung Han03b51852020-02-26 22:45:42 +090029 StubsVersion() string
Ivan Lozano52767be2019-10-18 14:49:46 -070030 HasStubsVariants() bool
31 SelectedStl() string
32 ApiLevel() string
Ivan Lozano183a3212019-10-18 14:18:45 -070033
34 BuildStaticVariant() bool
35 BuildSharedVariant() bool
36 SetStatic()
37 SetShared()
Ivan Lozano52767be2019-10-18 14:49:46 -070038 Static() bool
39 Shared() bool
40 Toc() android.OptionalPath
41
Yifan Hong1b3348d2020-01-21 15:53:22 -080042 InRamdisk() bool
43 OnlyInRamdisk() bool
44
Ivan Lozano52767be2019-10-18 14:49:46 -070045 InRecovery() bool
46 OnlyInRecovery() bool
47
Colin Crossc511bc52020-04-07 16:50:32 +000048 UseSdk() bool
Ivan Lozano52767be2019-10-18 14:49:46 -070049 UseVndk() bool
50 MustUseVendorVariant() bool
51 IsVndk() bool
52 HasVendorVariant() bool
53
54 SdkVersion() string
Colin Crossc511bc52020-04-07 16:50:32 +000055 AlwaysSdk() bool
Ivan Lozano52767be2019-10-18 14:49:46 -070056
57 ToolchainLibrary() bool
58 NdkPrebuiltStl() bool
59 StubDecorator() bool
Ivan Lozano183a3212019-10-18 14:18:45 -070060}
61
62type DependencyTag struct {
63 blueprint.BaseDependencyTag
64 Name string
65 Library bool
66 Shared bool
67
68 ReexportFlags bool
69
70 ExplicitlyVersioned bool
Jiyong Parkd7536ba2020-01-16 17:14:23 +090071
72 FromStatic bool
Ivan Lozano183a3212019-10-18 14:18:45 -070073}
74
75var (
76 SharedDepTag = DependencyTag{Name: "shared", Library: true, Shared: true}
77 StaticDepTag = DependencyTag{Name: "static", Library: true}
78
Jiyong Parkd7536ba2020-01-16 17:14:23 +090079 // Same as SharedDepTag, but from a static lib
80 SharedFromStaticDepTag = DependencyTag{Name: "shared from static", Library: true, Shared: true, FromStatic: true}
81
Ivan Lozano183a3212019-10-18 14:18:45 -070082 CrtBeginDepTag = DependencyTag{Name: "crtbegin"}
83 CrtEndDepTag = DependencyTag{Name: "crtend"}
84)