blob: 80cd6b8a233eb0a12e50053270caaa66c3092ae4 [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
48 UseVndk() bool
49 MustUseVendorVariant() bool
50 IsVndk() bool
51 HasVendorVariant() bool
52
53 SdkVersion() string
54
55 ToolchainLibrary() bool
56 NdkPrebuiltStl() bool
57 StubDecorator() bool
Ivan Lozano183a3212019-10-18 14:18:45 -070058}
59
60type DependencyTag struct {
61 blueprint.BaseDependencyTag
62 Name string
63 Library bool
64 Shared bool
65
66 ReexportFlags bool
67
68 ExplicitlyVersioned bool
Jiyong Parkd7536ba2020-01-16 17:14:23 +090069
70 FromStatic bool
Ivan Lozano183a3212019-10-18 14:18:45 -070071}
72
73var (
74 SharedDepTag = DependencyTag{Name: "shared", Library: true, Shared: true}
75 StaticDepTag = DependencyTag{Name: "static", Library: true}
76
Jiyong Parkd7536ba2020-01-16 17:14:23 +090077 // Same as SharedDepTag, but from a static lib
78 SharedFromStaticDepTag = DependencyTag{Name: "shared from static", Library: true, Shared: true, FromStatic: true}
79
Ivan Lozano183a3212019-10-18 14:18:45 -070080 CrtBeginDepTag = DependencyTag{Name: "crtbegin"}
81 CrtEndDepTag = DependencyTag{Name: "crtend"}
82)