| 1 |
// REQUIRES: zlib |
| 2 |
|
| 3 |
// RUN: %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -Wa,-compress-debug-sections -c %s 2>&1 | FileCheck -check-prefix CHECK-_COMPRESS_DEBUG_SECTIONS %s |
| 4 |
// CHECK-_COMPRESS_DEBUG_SECTIONS: "-compress-debug-sections" |
| 5 |
|
| 6 |
// RUN: %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -Wa,--compress-debug-sections -c %s 2>&1 | FileCheck -check-prefix CHECK-__COMPRESS_DEBUG_SECTIONS %s |
| 7 |
// CHECK-__COMPRESS_DEBUG_SECTIONS: "--compress-debug-sections" |
| 8 |
|
| 9 |
// RUN: %clang -### --target=i386-pc-solaris2.11 -fno-integrated-as -Wa,-compress-debug-sections=zlib -c %s 2>&1 | FileCheck -check-prefix CHECK-_COMPRESS_DEBUG_SECTIONS-ZLIB %s |
| 10 |
// CHECK-_COMPRESS_DEBUG_SECTIONS-ZLIB: "-compress-debug-sections=zlib" |
| 11 |
|
| 12 |
// RUN: %clang -### --target=i386-pc-solaris2.11 -fno-integrated-as -Wa,--compress-debug-sections=zlib -c %s 2>&1 | FileCheck -check-prefix CHECK-__COMPRESS_DEBUG_SECTIONS-ZLIB %s |
| 13 |
// CHECK-__COMPRESS_DEBUG_SECTIONS-ZLIB: "--compress-debug-sections=zlib" |
| 14 |
|
| 15 |
// RUN: %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -Wa,--compress-debug-sections -Wa,--nocompress-debug-sections -c %s 2>&1 | FileCheck -check-prefix CHECK-POSNEG %s |
| 16 |
// CHECK-POSNEG: "--compress-debug-sections" |
| 17 |
// CHECK-POSNEG: "--nocompress-debug-sections" |
| 18 |
|
| 19 |
// RUN: %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -Wa,-compress-debug-sections -Wa,--compress-debug-sections -c %s 2>&1 | FileCheck -check-prefix CHECK-MULTIPLE %s |
| 20 |
// CHECK-MULTIPLE: "-compress-debug-sections" |
| 21 |
// CHECK-MULTIPLE: "--compress-debug-sections" |
| 22 |
|
| 23 |
// RUN: %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -gz -x assembler -c %s 2>&1 | FileCheck -check-prefix CHECK-OPT_GZ %s |
| 24 |
// RUN: %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -gz -c %s 2>&1 | FileCheck -check-prefix CHECK-OPT_GZ %s |
| 25 |
// CHECK-OPT_GZ: "--compress-debug-sections=zlib" |
| 26 |
|
| 27 |
// RUN: %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -gz=none -x assembler -c %s 2>&1 | FileCheck -check-prefix CHECK-OPT_GZ_EQ_NONE %s |
| 28 |
// RUN: %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -gz=none -c %s 2>&1 | FileCheck -check-prefix CHECK-OPT_GZ_EQ_NONE %s |
| 29 |
// CHECK-OPT_GZ_EQ_NONE: "--compress-debug-sections=none" |
| 30 |
|
| 31 |
// RUN: %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -gz=zlib -x assembler -c %s 2>&1 | FileCheck -check-prefix CHECK-OPT_GZ_EQ_ZLIB %s |
| 32 |
// RUN: %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -gz=zlib -c %s 2>&1 | FileCheck -check-prefix CHECK-OPT_GZ_EQ_ZLIB %s |
| 33 |
// CHECK-OPT_GZ_EQ_ZLIB: "--compress-debug-sections=zlib" |
| 34 |
|
| 35 |
// RUN: not %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -gz=invalid -x assembler -c %s 2>&1 | FileCheck -check-prefix CHECK-OPT_GZ_EQ_INVALID %s |
| 36 |
// RUN: not %clang -### -target i686-unknown-linux-gnu -fno-integrated-as -gz=invalid -c %s 2>&1 | FileCheck -check-prefix CHECK-OPT_GZ_EQ_INVALID %s |
| 37 |
// CHECK-OPT_GZ_EQ_INVALID: error: unsupported argument 'invalid' to option '-gz=' |
| 38 |
|