Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[dsymutil] Copy symbol table regardless of LINKEDIT segment
Ensure we copy the symbol table for MH_PRELOAD Mach-Os, which don't have a LINKEDIT segment, but (can) have a symbol table. rdar://88919473 Differential revision: https://reviews.llvm.org/D120583
- Loading branch information
1 parent
bbaeb1e
commit 03d4904
Showing
4 changed files
with
17 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
$ cat foo.c | ||
void start(void) asm("start"); | ||
void start(void) {} | ||
$ xcrun clang -c -o foo.o foo.c -g3 | ||
$ xcrun clang -o foo foo.o -g3 -Wl,-preload -nodefaultlibs | ||
|
||
RUN: dsymutil -oso-prepend-path %p/../Inputs %p/../Inputs/private/tmp/preload/foo -o %t.dSYM | ||
RUN: llvm-nm %p/../Inputs/private/tmp/preload/foo | FileCheck %s | ||
RUN: llvm-nm %t.dSYM/Contents/Resources/DWARF/foo | FileCheck %s | ||
CHECK: start |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters