Renato Golin 4854d80c39 [EABI] Add Clang support for -meabi flag
The -meabi flag to control LLVM EABI version.

Without '-meabi' or with '-meabi default' imply LLVM triple default.
With '-meabi gnu' sets EABI GNU.
With '-meabi 4' or '-meabi 5' set EABI version 4 and 5 respectively.

A similar patch was introduced in LLVM.

Patch by Vinicius Tinti.

llvm-svn: 252463
2015-11-09 12:40:41 +00:00

14 lines
532 B
C

// RUN: %clang %s -meabi 4 -### 2>&1 \
// RUN: | FileCheck -check-prefix=CHECK-EABI4 %s
// RUN: %clang %s -meabi 5 -### 2>&1 \
// RUN: | FileCheck -check-prefix=CHECK-EABI5 %s
// RUN: %clang %s -meabi gnu -### 2>&1 \
// RUN: | FileCheck -check-prefix=CHECK-GNUEABI %s
// RUN: not %clang %s -meabi unknown 2>&1 \
// RUN: | FileCheck -check-prefix=CHECK-UNKNOWN %s
// CHECK-EABI4: "-meabi" "4"
// CHECK-EABI5: "-meabi" "5"
// CHECK-GNUEABI: "-meabi" "gnu"
// CHECK-UNKNOWN: error: invalid value 'unknown' in '-meabi unknown'