George Rimar | 36b2c0a | 2016-06-28 08:07:26 +0000 | [diff] [blame] | 1 | # REQUIRES: x86 |
| 2 | |
Rui Ueyama | a3b7546 | 2016-09-07 20:50:41 +0000 | [diff] [blame^] | 3 | # RUN: echo "VERSION_1.0 { global: bar; };" > %t.script |
George Rimar | 36b2c0a | 2016-06-28 08:07:26 +0000 | [diff] [blame] | 4 | # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.o |
| 5 | # RUN: not ld.lld --version-script %t.script -shared --no-undefined-version \ |
| 6 | # RUN: %t.o -o %t.so 2>&1 | FileCheck -check-prefix=ERR1 %s |
| 7 | # ERR1: version script assignment of VERSION_1.0 to symbol bar failed: symbol not defined |
| 8 | |
Rui Ueyama | a3b7546 | 2016-09-07 20:50:41 +0000 | [diff] [blame^] | 9 | # RUN: echo "VERSION_1.0 { global: und; };" > %t2.script |
George Rimar | 36b2c0a | 2016-06-28 08:07:26 +0000 | [diff] [blame] | 10 | # RUN: not ld.lld --version-script %t2.script -shared --no-undefined-version \ |
| 11 | # RUN: %t.o -o %t.so 2>&1 | FileCheck -check-prefix=ERR2 %s |
| 12 | # ERR2: version script assignment of VERSION_1.0 to symbol und failed: symbol not defined |
| 13 | |
| 14 | .text |
| 15 | .globl foo |
| 16 | .type foo,@function |
| 17 | foo: |
| 18 | callq und@PLT |