forked from OSchip/llvm-project
34 lines
963 B
Plaintext
34 lines
963 B
Plaintext
# Tests the functionality of archive libraries reading
|
|
# and resolution
|
|
# Note: The binary files would not be required once we have support to generate
|
|
# binary archives from textual(yaml) input
|
|
#
|
|
# Tests generated using the source files below
|
|
# main file
|
|
#
|
|
#extern int __bss_start __attribute__ ((weak));
|
|
#int a;
|
|
#int main()
|
|
#{
|
|
# return 0;
|
|
#}
|
|
#
|
|
|
|
RUN: lld -flavor gnu -target i386 -e main %p/Inputs/writersyms.o -o %t1
|
|
RUN: llvm-nm -n %t1 | FileCheck -check-prefix CHECKSYMS %s
|
|
RUN: lld -flavor gnu -shared -target i386 -e main %p/Inputs/writersyms.o -o %t1
|
|
RUN: llvm-nm -n %t1 | FileCheck -check-prefix CHECKSHAREDSYMS %s
|
|
|
|
CHECKSYMS: 00000000 a 1.c
|
|
CHECKSYMS: 00000134 T main
|
|
CHECKSYMS: 00001000 A __bss_start
|
|
CHECKSYMS: 00001000 B a
|
|
CHECKSYMS: 00001004 A __bss_end
|
|
CHECKSYMS: 00001004 A _end
|
|
CHECKSYMS: 00001004 A end
|
|
|
|
CHECKSHAREDSYMS: 00000000 a 1.c
|
|
CHECKSHAREDSYMS: 0000010c T main
|
|
CHECKSHAREDSYMS: 00001000 B a
|
|
CHECKSHAREDSYMS: 00001004 A _end
|