gn build: (manually) Port ae032e27 and 21f83113.

__register_frame and __deregister_frame are associated with the
.eh_frame section, which I think is used on all of our platforms
except Windows and 32-bit ARM (which uses the ARM EHABI).

Also add a file that was added to lld/MachO.
This commit is contained in:
Peter Collingbourne 2020-11-10 15:46:21 -08:00
parent 3726b14428
commit c052510c0b
2 changed files with 13 additions and 0 deletions

View File

@ -28,6 +28,7 @@ static_library("MachO2") {
"ExportTrie.cpp",
"InputFiles.cpp",
"InputSection.cpp",
"LTO.cpp",
"MergedOutputSection.cpp",
"ObjC.cpp",
"OutputSection.cpp",

View File

@ -190,6 +190,18 @@ write_cmake_config("config") {
]
}
if (current_os == "win" || current_cpu == "arm") {
values += [
"HAVE_DEREGISTER_FRAME=",
"HAVE_REGISTER_FRAME=",
]
} else {
values += [
"HAVE_DEREGISTER_FRAME=1",
"HAVE_REGISTER_FRAME=1",
]
}
if (current_os == "win") {
values += [
"HAVE_DECL_STRERROR_S=1",