Merge "Generated headers may not be arch specific"
This commit is contained in:
commit
b2773e116f
|
@ -206,22 +206,22 @@ var includeDirProperties = []includeDirsProperty{
|
||||||
dirs: true,
|
dirs: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
// exportedGeneratedIncludeDirs lists directories that contains some header files
|
// ExportedGeneratedIncludeDirs lists directories that contains some header files
|
||||||
// that are explicitly listed in the exportedGeneratedHeaders property. So, the contents
|
// that are explicitly listed in the ExportedGeneratedHeaders property. So, the contents
|
||||||
// of these directories do not need to be copied, but these directories do need adding to
|
// of these directories do not need to be copied, but these directories do need adding to
|
||||||
// the export_include_dirs property in the prebuilt module in the snapshot.
|
// the export_include_dirs property in the prebuilt module in the snapshot.
|
||||||
pathsGetter: func(libInfo *nativeLibInfoProperties) android.Paths { return libInfo.exportedGeneratedIncludeDirs },
|
pathsGetter: func(libInfo *nativeLibInfoProperties) android.Paths { return libInfo.ExportedGeneratedIncludeDirs },
|
||||||
propertyName: "export_include_dirs",
|
propertyName: "export_include_dirs",
|
||||||
snapshotDir: nativeGeneratedIncludeDir,
|
snapshotDir: nativeGeneratedIncludeDir,
|
||||||
copy: false,
|
copy: false,
|
||||||
dirs: true,
|
dirs: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
// exportedGeneratedHeaders lists header files that are in one of the directories
|
// ExportedGeneratedHeaders lists header files that are in one of the directories
|
||||||
// specified in exportedGeneratedIncludeDirs must be copied into the snapshot.
|
// specified in ExportedGeneratedIncludeDirs must be copied into the snapshot.
|
||||||
// As they are in a directory in exportedGeneratedIncludeDirs they do not need adding to a
|
// As they are in a directory in ExportedGeneratedIncludeDirs they do not need adding to a
|
||||||
// property in the prebuilt module in the snapshot.
|
// property in the prebuilt module in the snapshot.
|
||||||
pathsGetter: func(libInfo *nativeLibInfoProperties) android.Paths { return libInfo.exportedGeneratedHeaders },
|
pathsGetter: func(libInfo *nativeLibInfoProperties) android.Paths { return libInfo.ExportedGeneratedHeaders },
|
||||||
propertyName: "",
|
propertyName: "",
|
||||||
snapshotDir: nativeGeneratedIncludeDir,
|
snapshotDir: nativeGeneratedIncludeDir,
|
||||||
copy: true,
|
copy: true,
|
||||||
|
@ -351,13 +351,13 @@ type nativeLibInfoProperties struct {
|
||||||
|
|
||||||
// The list of arch specific exported generated include dirs.
|
// The list of arch specific exported generated include dirs.
|
||||||
//
|
//
|
||||||
// This field is not exported as its contents are always arch specific.
|
// This field is exported as its contents may not be arch specific, e.g. protos.
|
||||||
exportedGeneratedIncludeDirs android.Paths
|
ExportedGeneratedIncludeDirs android.Paths `android:"arch_variant"`
|
||||||
|
|
||||||
// The list of arch specific exported generated header files.
|
// The list of arch specific exported generated header files.
|
||||||
//
|
//
|
||||||
// This field is not exported as its contents are is always arch specific.
|
// This field is exported as its contents may not be arch specific, e.g. protos.
|
||||||
exportedGeneratedHeaders android.Paths
|
ExportedGeneratedHeaders android.Paths `android:"arch_variant"`
|
||||||
|
|
||||||
// The list of possibly common exported system include dirs.
|
// The list of possibly common exported system include dirs.
|
||||||
//
|
//
|
||||||
|
@ -430,7 +430,7 @@ func (p *nativeLibInfoProperties) PopulateFromVariant(ctx android.SdkMemberConte
|
||||||
|
|
||||||
// Make sure that the include directories are unique.
|
// Make sure that the include directories are unique.
|
||||||
p.ExportedIncludeDirs = android.FirstUniquePaths(exportedIncludeDirs)
|
p.ExportedIncludeDirs = android.FirstUniquePaths(exportedIncludeDirs)
|
||||||
p.exportedGeneratedIncludeDirs = android.FirstUniquePaths(exportedGeneratedIncludeDirs)
|
p.ExportedGeneratedIncludeDirs = android.FirstUniquePaths(exportedGeneratedIncludeDirs)
|
||||||
|
|
||||||
// Take a copy before filtering out duplicates to avoid changing the slice owned by the
|
// Take a copy before filtering out duplicates to avoid changing the slice owned by the
|
||||||
// ccModule.
|
// ccModule.
|
||||||
|
@ -456,7 +456,7 @@ func (p *nativeLibInfoProperties) PopulateFromVariant(ctx android.SdkMemberConte
|
||||||
}
|
}
|
||||||
p.SystemSharedLibs = specifiedDeps.systemSharedLibs
|
p.SystemSharedLibs = specifiedDeps.systemSharedLibs
|
||||||
}
|
}
|
||||||
p.exportedGeneratedHeaders = exportedInfo.GeneratedHeaders
|
p.ExportedGeneratedHeaders = exportedInfo.GeneratedHeaders
|
||||||
|
|
||||||
if !p.memberType.noOutputFiles && addOutputFile {
|
if !p.memberType.noOutputFiles && addOutputFile {
|
||||||
p.outputFile = getRequiredMemberOutputFile(ctx, ccModule)
|
p.outputFile = getRequiredMemberOutputFile(ctx, ccModule)
|
||||||
|
|
|
@ -494,31 +494,26 @@ cc_prebuilt_library_shared {
|
||||||
apex_available: ["//apex_available:platform"],
|
apex_available: ["//apex_available:platform"],
|
||||||
stl: "none",
|
stl: "none",
|
||||||
compile_multilib: "both",
|
compile_multilib: "both",
|
||||||
export_include_dirs: ["include/myinclude"],
|
export_include_dirs: [
|
||||||
|
"include/myinclude",
|
||||||
|
"include_gen/generated_foo/gen",
|
||||||
|
"include_gen/generated_foo/gen/protos",
|
||||||
|
],
|
||||||
arch: {
|
arch: {
|
||||||
arm64: {
|
arm64: {
|
||||||
srcs: ["arm64/lib/mynativelib.so"],
|
srcs: ["arm64/lib/mynativelib.so"],
|
||||||
export_include_dirs: [
|
|
||||||
"arm64/include_gen/generated_foo/gen",
|
|
||||||
"arm64/include_gen/generated_foo/gen/protos",
|
|
||||||
],
|
|
||||||
},
|
},
|
||||||
arm: {
|
arm: {
|
||||||
srcs: ["arm/lib/mynativelib.so"],
|
srcs: ["arm/lib/mynativelib.so"],
|
||||||
export_include_dirs: [
|
|
||||||
"arm/include_gen/generated_foo/gen",
|
|
||||||
"arm/include_gen/generated_foo/gen/protos",
|
|
||||||
],
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
`),
|
`),
|
||||||
checkAllCopyRules(`
|
checkAllCopyRules(`
|
||||||
myinclude/Test.h -> include/myinclude/Test.h
|
myinclude/Test.h -> include/myinclude/Test.h
|
||||||
|
.intermediates/generated_foo/gen/generated_foo/protos/foo/bar.h -> include_gen/generated_foo/gen/generated_foo/protos/foo/bar.h
|
||||||
.intermediates/mynativelib/android_arm64_armv8-a_shared/mynativelib.so -> arm64/lib/mynativelib.so
|
.intermediates/mynativelib/android_arm64_armv8-a_shared/mynativelib.so -> arm64/lib/mynativelib.so
|
||||||
.intermediates/generated_foo/gen/generated_foo/protos/foo/bar.h -> arm64/include_gen/generated_foo/gen/generated_foo/protos/foo/bar.h
|
|
||||||
.intermediates/mynativelib/android_arm_armv7-a-neon_shared/mynativelib.so -> arm/lib/mynativelib.so
|
.intermediates/mynativelib/android_arm_armv7-a-neon_shared/mynativelib.so -> arm/lib/mynativelib.so
|
||||||
.intermediates/generated_foo/gen/generated_foo/protos/foo/bar.h -> arm/include_gen/generated_foo/gen/generated_foo/protos/foo/bar.h
|
|
||||||
`),
|
`),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -1858,7 +1853,10 @@ cc_prebuilt_library_static {
|
||||||
host_supported: true,
|
host_supported: true,
|
||||||
stl: "none",
|
stl: "none",
|
||||||
compile_multilib: "64",
|
compile_multilib: "64",
|
||||||
export_include_dirs: ["include/myinclude"],
|
export_include_dirs: [
|
||||||
|
"include/myinclude",
|
||||||
|
"include_gen/mynativelib/linux_glibc_x86_64_static/gen/aidl",
|
||||||
|
],
|
||||||
target: {
|
target: {
|
||||||
host: {
|
host: {
|
||||||
enabled: false,
|
enabled: false,
|
||||||
|
@ -1866,7 +1864,6 @@ cc_prebuilt_library_static {
|
||||||
linux_glibc_x86_64: {
|
linux_glibc_x86_64: {
|
||||||
enabled: true,
|
enabled: true,
|
||||||
srcs: ["x86_64/lib/mynativelib.a"],
|
srcs: ["x86_64/lib/mynativelib.a"],
|
||||||
export_include_dirs: ["x86_64/include_gen/mynativelib/linux_glibc_x86_64_static/gen/aidl"],
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
@ -1884,7 +1881,10 @@ cc_prebuilt_library_static {
|
||||||
installable: false,
|
installable: false,
|
||||||
stl: "none",
|
stl: "none",
|
||||||
compile_multilib: "64",
|
compile_multilib: "64",
|
||||||
export_include_dirs: ["include/myinclude"],
|
export_include_dirs: [
|
||||||
|
"include/myinclude",
|
||||||
|
"include_gen/mynativelib/linux_glibc_x86_64_static/gen/aidl",
|
||||||
|
],
|
||||||
target: {
|
target: {
|
||||||
host: {
|
host: {
|
||||||
enabled: false,
|
enabled: false,
|
||||||
|
@ -1892,7 +1892,6 @@ cc_prebuilt_library_static {
|
||||||
linux_glibc_x86_64: {
|
linux_glibc_x86_64: {
|
||||||
enabled: true,
|
enabled: true,
|
||||||
srcs: ["x86_64/lib/mynativelib.a"],
|
srcs: ["x86_64/lib/mynativelib.a"],
|
||||||
export_include_dirs: ["x86_64/include_gen/mynativelib/linux_glibc_x86_64_static/gen/aidl"],
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
@ -1916,10 +1915,10 @@ module_exports_snapshot {
|
||||||
`),
|
`),
|
||||||
checkAllCopyRules(`
|
checkAllCopyRules(`
|
||||||
myinclude/Test.h -> include/myinclude/Test.h
|
myinclude/Test.h -> include/myinclude/Test.h
|
||||||
|
.intermediates/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/Test.h -> include_gen/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/Test.h
|
||||||
|
.intermediates/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/BnTest.h -> include_gen/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/BnTest.h
|
||||||
|
.intermediates/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/BpTest.h -> include_gen/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/BpTest.h
|
||||||
.intermediates/mynativelib/linux_glibc_x86_64_static/mynativelib.a -> x86_64/lib/mynativelib.a
|
.intermediates/mynativelib/linux_glibc_x86_64_static/mynativelib.a -> x86_64/lib/mynativelib.a
|
||||||
.intermediates/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/Test.h -> x86_64/include_gen/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/Test.h
|
|
||||||
.intermediates/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/BnTest.h -> x86_64/include_gen/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/BnTest.h
|
|
||||||
.intermediates/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/BpTest.h -> x86_64/include_gen/mynativelib/linux_glibc_x86_64_static/gen/aidl/aidl/foo/bar/BpTest.h
|
|
||||||
`),
|
`),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue