31 lines · plain
1# REQUIRES: x862 3# RUN: echo "VERSION_1.0 { global: bar; };" > %t.script4# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.o5# RUN: not ld.lld --version-script %t.script -shared %t.o -o /dev/null \6# RUN: --fatal-warnings 2>&1 | FileCheck -check-prefix=ERR1 %s7# RUN: ld.lld --version-script %t.script -shared --undefined-version %t.o -o %t.so8# RUN: not ld.lld --version-script %t.script -shared --no-undefined-version \9# RUN: %t.o -o %t.so 2>&1 | FileCheck -check-prefix=ERR1 %s10# ERR1: version script assignment of 'VERSION_1.0' to symbol 'bar' failed: symbol not defined11 12# RUN: echo "VERSION_1.0 { global: und; };" > %t2.script13# RUN: not ld.lld --version-script %t2.script -shared --no-undefined-version \14# RUN: %t.o -o %t.so 2>&1 | FileCheck -check-prefix=ERR2 %s15# ERR2: version script assignment of 'VERSION_1.0' to symbol 'und' failed: symbol not defined16 17# RUN: echo "VERSION_1.0 { local: und; };" > %t3.script18# RUN: not ld.lld --version-script %t3.script -shared --no-undefined-version \19# RUN: %t.o -o %t.so 2>&1 | FileCheck -check-prefix=ERR3 %s20# ERR3: version script assignment of 'local' to symbol 'und' failed: symbol not defined21 22## Wildcard patterns do not error.23# RUN: echo "VERSION_1.0 { global: b*; local: u*; };" > %t4.script24# RUN: ld.lld --version-script %t4.script -shared --no-undefined-version --fatal-warnings %t.o -o /dev/null25 26.text27.globl foo28.type foo,@function29foo:30callq und@PLT31