Merge "[arm64] Build NDK with PAuth and BTI" am: a175126009
am: bfe770d03f
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1558552 MUST ONLY BE SUBMITTED BY AUTOMERGER Change-Id: I6b18c0c39feea4fec7015a61b908a6beacc469ff
This commit is contained in:
commit
bb4c44e0c2
|
@ -1442,7 +1442,7 @@ type archConfig struct {
|
||||||
func getNdkAbisConfig() []archConfig {
|
func getNdkAbisConfig() []archConfig {
|
||||||
return []archConfig{
|
return []archConfig{
|
||||||
{"arm", "armv7-a", "", []string{"armeabi-v7a"}},
|
{"arm", "armv7-a", "", []string{"armeabi-v7a"}},
|
||||||
{"arm64", "armv8-a", "", []string{"arm64-v8a"}},
|
{"arm64", "armv8-a-branchprot", "", []string{"arm64-v8a"}},
|
||||||
{"x86", "", "", []string{"x86"}},
|
{"x86", "", "", []string{"x86"}},
|
||||||
{"x86_64", "", "", []string{"x86_64"}},
|
{"x86_64", "", "", []string{"x86_64"}},
|
||||||
}
|
}
|
||||||
|
|
|
@ -41,6 +41,7 @@ var archVariants = map[ArchType][]string{
|
||||||
},
|
},
|
||||||
Arm64: {
|
Arm64: {
|
||||||
"armv8_a",
|
"armv8_a",
|
||||||
|
"armv8_a_branchprot",
|
||||||
"armv8_2a",
|
"armv8_2a",
|
||||||
"armv8-2a-dotprod",
|
"armv8-2a-dotprod",
|
||||||
"cortex-a53",
|
"cortex-a53",
|
||||||
|
|
|
@ -31,6 +31,10 @@ var (
|
||||||
"armv8-a": []string{
|
"armv8-a": []string{
|
||||||
"-march=armv8-a",
|
"-march=armv8-a",
|
||||||
},
|
},
|
||||||
|
"armv8-a-branchprot": []string{
|
||||||
|
"-march=armv8-a",
|
||||||
|
"-mbranch-protection=standard",
|
||||||
|
},
|
||||||
"armv8-2a": []string{
|
"armv8-2a": []string{
|
||||||
"-march=armv8.2-a",
|
"-march=armv8.2-a",
|
||||||
},
|
},
|
||||||
|
@ -102,6 +106,7 @@ func init() {
|
||||||
pctx.StaticVariable("Arm64ClangCppflags", strings.Join(ClangFilterUnknownCflags(arm64Cppflags), " "))
|
pctx.StaticVariable("Arm64ClangCppflags", strings.Join(ClangFilterUnknownCflags(arm64Cppflags), " "))
|
||||||
|
|
||||||
pctx.StaticVariable("Arm64ClangArmv8ACflags", strings.Join(arm64ArchVariantCflags["armv8-a"], " "))
|
pctx.StaticVariable("Arm64ClangArmv8ACflags", strings.Join(arm64ArchVariantCflags["armv8-a"], " "))
|
||||||
|
pctx.StaticVariable("Arm64ClangArmv8ABranchProtCflags", strings.Join(arm64ArchVariantCflags["armv8-a-branchprot"], " "))
|
||||||
pctx.StaticVariable("Arm64ClangArmv82ACflags", strings.Join(arm64ArchVariantCflags["armv8-2a"], " "))
|
pctx.StaticVariable("Arm64ClangArmv82ACflags", strings.Join(arm64ArchVariantCflags["armv8-2a"], " "))
|
||||||
pctx.StaticVariable("Arm64ClangArmv82ADotprodCflags", strings.Join(arm64ArchVariantCflags["armv8-2a-dotprod"], " "))
|
pctx.StaticVariable("Arm64ClangArmv82ADotprodCflags", strings.Join(arm64ArchVariantCflags["armv8-2a-dotprod"], " "))
|
||||||
|
|
||||||
|
@ -124,6 +129,7 @@ func init() {
|
||||||
var (
|
var (
|
||||||
arm64ClangArchVariantCflagsVar = map[string]string{
|
arm64ClangArchVariantCflagsVar = map[string]string{
|
||||||
"armv8-a": "${config.Arm64ClangArmv8ACflags}",
|
"armv8-a": "${config.Arm64ClangArmv8ACflags}",
|
||||||
|
"armv8-a-branchprot": "${config.Arm64ClangArmv8ABranchProtCflags}",
|
||||||
"armv8-2a": "${config.Arm64ClangArmv82ACflags}",
|
"armv8-2a": "${config.Arm64ClangArmv82ACflags}",
|
||||||
"armv8-2a-dotprod": "${config.Arm64ClangArmv82ADotprodCflags}",
|
"armv8-2a-dotprod": "${config.Arm64ClangArmv82ADotprodCflags}",
|
||||||
}
|
}
|
||||||
|
@ -202,6 +208,7 @@ func (toolchainArm64) LibclangRuntimeLibraryArch() string {
|
||||||
func arm64ToolchainFactory(arch android.Arch) Toolchain {
|
func arm64ToolchainFactory(arch android.Arch) Toolchain {
|
||||||
switch arch.ArchVariant {
|
switch arch.ArchVariant {
|
||||||
case "armv8-a":
|
case "armv8-a":
|
||||||
|
case "armv8-a-branchprot":
|
||||||
case "armv8-2a":
|
case "armv8-2a":
|
||||||
case "armv8-2a-dotprod":
|
case "armv8-2a-dotprod":
|
||||||
// Nothing extra for armv8-a/armv8-2a
|
// Nothing extra for armv8-a/armv8-2a
|
||||||
|
|
|
@ -26,9 +26,10 @@ var (
|
||||||
Arm64LinkFlags = []string{}
|
Arm64LinkFlags = []string{}
|
||||||
|
|
||||||
Arm64ArchVariantRustFlags = map[string][]string{
|
Arm64ArchVariantRustFlags = map[string][]string{
|
||||||
"armv8-a": []string{},
|
"armv8-a": []string{},
|
||||||
"armv8-2a": []string{},
|
"armv8-a-branchprot": []string{},
|
||||||
"armv8-2a-dotprod": []string{},
|
"armv8-2a": []string{},
|
||||||
|
"armv8-2a-dotprod": []string{},
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue