36 lines · plain
1# REQUIRES: x862# RUN: llvm-mc -filetype=obj -triple=x86_64 %s -o %t.o3 4# RUN: echo 'foo { *; }; bar { *; };' > %t.ver5# RUN: ld.lld --version-script %t.ver %t.o -shared -o %t.so 2>&1 | \6# RUN: FileCheck --check-prefix=MULTVER %s7 8# RUN: echo '{ global: *; local: *;};' > %t.ver9# RUN: ld.lld --version-script %t.ver %t.o -shared -o %t.so 2>&1 | \10# RUN: FileCheck --check-prefix=LOCGLOB %s11 12# RUN: echo 'V1 { global: *; }; V2 { local: *;};' > %t.ver13# RUN: ld.lld --version-script %t.ver %t.o -shared -o %t.so 2>&1 | \14# RUN: FileCheck --check-prefix=LOCGLOB %s15 16# RUN: echo 'V1 { local: *; }; V2 { global: *;};' > %t.ver17# RUN: ld.lld --version-script %t.ver %t.o -shared -o %t.so 2>&1 | \18# RUN: FileCheck --check-prefix=LOCGLOB %s19 20# RUN: echo 'V1 { local: *; }; V2 { local: *;};' > %t.ver21# RUN: ld.lld --version-script %t.ver %t.o -shared -o %t.so --fatal-warnings22 23## --retain-symbols-file uses the same internal infrastructure as the support24## for version scripts. Do not show the warings if they both are used.25# RUN: echo 'foo' > %t_retain.txt26# RUN: echo '{ local: *; };' > %t_local.ver27# RUN: echo '{ global: *; };' > %t_global.ver28# RUN: ld.lld --retain-symbols-file=%t_retain.txt --version-script %t_local.ver %t.o -shared -o %t.so --fatal-warnings29# RUN: ld.lld --retain-symbols-file=%t_retain.txt --version-script %t_global.ver %t.o -shared -o %t.so --fatal-warnings30 31# MULTVER: warning: wildcard pattern '*' is used for multiple version definitions in version script32# LOCGLOB: warning: wildcard pattern '*' is used for both 'local' and 'global' scopes in version script33 34.globl foo35foo:36