llvm-capstone/lld/test/COFF/implib-name.test
Joel Jones a5752e199c [lld] Add REQUIRES: x86 where needed to tests
If building lld without x86 support, tests that require that support should
be treated as unsupported, not errors.

Tested using:
  1. cmake '-DLLVM_TARGETS_TO_BUILD=AArch64;X86'
     make check-lld
     =>
     Expected Passes    : 1406
     Unsupported Tests  : 287

  2. cmake '-DLLVM_TARGETS_TO_BUILD=AArch64'
     make check-lld
     =>
     Expected Passes    : 410
     Unsupported Tests  : 1283

Patch by Joel Jones

Differential Revision: https://reviews.llvm.org/D47748

llvm-svn: 334095
2018-06-06 13:56:51 +00:00

73 lines
3.0 KiB
Plaintext

# REQUIRES: x86
# RUN: mkdir -p %T
# RUN: llvm-mc -triple x86_64-unknown-windows-msvc -filetype obj -o %T/object.obj %S/Inputs/object.s
# RUN: lld-link /dll /machine:x64 /def:%S/Inputs/named.def /out:%T/library.dll %T/object.obj /entry:f /subsystem:CONSOLE
# RUN: llvm-ar t %T/library.lib | FileCheck %s -check-prefix CHECK-DEFAULT-DLL-EXT
# RUN: lld-link /machine:x64 /def:%S/Inputs/named.def /out:%T/library.lib
# RUN: llvm-ar t %T/library.lib | FileCheck %s -check-prefix CHECK-DEFAULT-DLL-EXT
CHECK-DEFAULT-DLL-EXT: library.dll
CHECK-DEFAULT-DLL-EXT: library.dll
CHECK-DEFAULT-DLL-EXT: library.dll
CHECK-DEFAULT-DLL-EXT: library.dll
# RUN: lld-link /machine:x64 /def:%S/Inputs/named.def /out:%T/library.exe %T/object.obj /entry:f /subsystem:CONSOLE
# RUN: llvm-ar t %T/library.lib | FileCheck %s -check-prefix CHECK-DEFAULT-EXE-EXT
CHECK-DEFAULT-EXE-EXT: library.exe
CHECK-DEFAULT-EXE-EXT: library.exe
CHECK-DEFAULT-EXE-EXT: library.exe
CHECK-DEFAULT-EXE-EXT: library.exe
# RUN: lld-link /dll /machine:x64 /def:%S/Inputs/extension.def /out:%T/extension.dll /entry:f /subsystem:CONSOLE
# RUN: llvm-ar t %T/extension.lib | FileCheck %s -check-prefix CHECK-EXTENSION
# RUN: lld-link /machine:x64 /def:%S/Inputs/extension.def /out:%T/extension.exe /entry:f /subsystem:CONSOLE
# RUN: llvm-ar t %T/extension.lib | FileCheck %s -check-prefix CHECK-EXTENSION
# RUN: lld-link /machine:x64 /def:%S/Inputs/extension.def /out:%T/extension.lib
# RUN: llvm-ar t %T/extension.lib | FileCheck %s -check-prefix CHECK-EXTENSION
CHECK-EXTENSION: library.ext
CHECK-EXTENSION: library.ext
CHECK-EXTENSION: library.ext
CHECK-EXTENSION: library.ext
# RUN: lld-link /dll /machine:x64 /def:%S/Inputs/default.def /out:%T/default.dll /entry:f /subsystem:CONSOLE
# RUN: llvm-ar t %T/default.lib | FileCheck %s -check-prefix CHECK-OUTPUT-NAME-DLL
# RUN: lld-link /machine:x64 /def:%S/Inputs/default.def /out:%T/default.lib
# RUN: llvm-ar t %T/default.lib | FileCheck %s -check-prefix CHECK-OUTPUT-NAME-DLL
CHECK-OUTPUT-NAME-DLL: default.dll
CHECK-OUTPUT-NAME-DLL: default.dll
CHECK-OUTPUT-NAME-DLL: default.dll
CHECK-OUTPUT-NAME-DLL: default.dll
# RUN: lld-link /machine:x64 /def:%S/Inputs/default.def /out:%T/default.exe %T/object.obj /entry:f /subsystem:CONSOLE
# RUN: llvm-ar t %T/default.lib | FileCheck %s -check-prefix CHECK-OUTPUT-NAME-EXE
CHECK-OUTPUT-NAME-EXE: default.exe
CHECK-OUTPUT-NAME-EXE: default.exe
CHECK-OUTPUT-NAME-EXE: default.exe
CHECK-OUTPUT-NAME-EXE: default.exe
# RUN: lld-link /machine:x64 /out:%T/default.exe %T/object.obj /entry:f /subsystem:CONSOLE
# RUN: llvm-ar t %T/default.lib | FileCheck %s -check-prefix CHECK-NODEF-EXE
CHECK-NODEF-EXE: default.exe
CHECK-NODEF-EXE: default.exe
CHECK-NODEF-EXE: default.exe
CHECK-NODEF-EXE: default.exe
# RUN: lld-link /machine:x64 /dll /out:%T/default.dll %T/object.obj /entry:f /subsystem:CONSOLE
# RUN: llvm-ar t %T/default.lib | FileCheck %s -check-prefix CHECK-NODEF-DLL
CHECK-NODEF-DLL: default.dll
CHECK-NODEF-DLL: default.dll
CHECK-NODEF-DLL: default.dll
CHECK-NODEF-DLL: default.dll