Allow C symbol file to be arch variant

The libclang_rt.* prebuilt libraries have an autogenerated map.txt for
each arch. e.g.
```
$ ls prebuilts/clang/host/linux-x86/clang-r530567/lib/clang/19/lib/linux/libclang_rt.asan*map.txt
prebuilts/clang/host/linux-x86/clang-r530567/lib/clang/19/lib/linux/libclang_rt.asan-aarch64-android.map.txt  prebuilts/clang/host/linux-x86/clang-r530567/lib/clang/19/lib/linux/libclang_rt.asan-riscv64-android.map.txt
prebuilts/clang/host/linux-x86/clang-r530567/lib/clang/19/lib/linux/libclang_rt.asan-arm-android.map.txt      prebuilts/clang/host/linux-x86/clang-r530567/lib/clang/19/lib/linux/libclang_rt.asan-x86_64-android.map.txt
prebuilts/clang/host/linux-x86/clang-r530567/lib/clang/19/lib/linux/libclang_rt.asan-i686-android.map.txt
```

These map.txt files are currently a noop, but will be used to compile
stub srcs. In preparation for that, make stubs.symbol_file and
llndk.symbol_file arch variant

Test: m nothing # no diff in ninja file
Bug: 220898484
Change-Id: I7316546905c1327c764ee67a48c77a2a68465d77
This commit is contained in:
Spandan Das
2024-07-24 01:21:53 +00:00
parent 1f22939d81
commit 02be101893
2 changed files with 4 additions and 4 deletions

View File

@@ -64,7 +64,7 @@ type LibraryProperties struct {
Stubs struct {
// Relative path to the symbol map. The symbol map provides the list of
// symbols that are exported for stubs variant of this library.
Symbol_file *string `android:"path"`
Symbol_file *string `android:"path,arch_variant"`
// List versions to generate stubs libs for. The version name "current" is always
// implicitly added.
@@ -75,7 +75,7 @@ type LibraryProperties struct {
// implementation is made available by some other means, e.g. in a Microdroid
// virtual machine.
Implementation_installable *bool
}
} `android:"arch_variant"`
// set the name of the output
Stem *string `android:"arch_variant"`
@@ -118,7 +118,7 @@ type LibraryProperties struct {
// If this is an LLNDK library, properties to describe the LLNDK stubs. Will be copied from
// the module pointed to by llndk_stubs if it is set.
Llndk llndkLibraryProperties
Llndk llndkLibraryProperties `android:"arch_variant"`
// If this is a vendor public library, properties to describe the vendor public library stubs.
Vendor_public_library vendorPublicLibraryProperties

View File

@@ -30,7 +30,7 @@ var (
type llndkLibraryProperties struct {
// Relative path to the symbol map.
// An example file can be seen here: TODO(danalbert): Make an example.
Symbol_file *string
Symbol_file *string `android:"path,arch_variant"`
// Whether to export any headers as -isystem instead of -I. Mainly for use by
// bionic/libc.