File tree Expand file tree Collapse file tree 6 files changed +15
-10
lines changed
clang/test/Preprocessor/Inputs Expand file tree Collapse file tree 6 files changed +15
-10
lines changed Original file line number Diff line number Diff line change 1
1
#ifndef RC_INVOKED
2
- #error RC_INVOKED not defined
2
+ # error RC_INVOKED not defined
3
3
#endif
4
- #ifndef _WIN32
5
- #error _WIN32 not defined
6
- #endif
7
- #ifndef __MINGW32__
8
- #error __MINGW32__ not defined
4
+ #ifndef __CYGWIN__
5
+ # ifndef _WIN32
6
+ # error _WIN32 not defined
7
+ # endif
8
+ # ifndef __MINGW32__
9
+ # error __MINGW32__ not defined
10
+ # endif
9
11
#endif
10
12
#define MY_ID 42
Original file line number Diff line number Diff line change @@ -2051,7 +2051,7 @@ void TargetLoweringBase::insertSSPDeclarations(Module &M) const {
2051
2051
2052
2052
// FreeBSD has "__stack_chk_guard" defined externally on libc.so
2053
2053
if (M.getDirectAccessExternalData () &&
2054
- !TM.getTargetTriple ().isWindowsGNUEnvironment () &&
2054
+ !TM.getTargetTriple ().isOSCygMing () &&
2055
2055
!(TM.getTargetTriple ().isPPC64 () &&
2056
2056
TM.getTargetTriple ().isOSFreeBSD ()) &&
2057
2057
(!TM.getTargetTriple ().isOSDarwin () ||
Original file line number Diff line number Diff line change 6
6
; RUN: llc -mtriple=amd64-pc-openbsd < %s -o - | FileCheck --check-prefix=OPENBSD-AMD64 %s
7
7
; RUN: llc -mtriple=i386-pc-windows-msvc < %s -o - | FileCheck -check-prefix=MSVC-I386 %s
8
8
; RUN: llc -mtriple=x86_64-w64-mingw32 < %s -o - | FileCheck --check-prefix=MINGW-X64 %s
9
+ ; RUN: llc -mtriple=x86_64-pc-cygwin < %s -o - | FileCheck --check-prefix=MINGW-X64 %s
9
10
; RUN: llc -mtriple=x86_64-pc-linux-gnu < %s -o - | FileCheck --check-prefix=IGNORE_INTRIN %s
10
11
11
12
%struct.foo = type { [16 x i8 ] }
Original file line number Diff line number Diff line change 1
1
; RUN: llc -mtriple=x86_64-w64-mingw32 < %s -o - | FileCheck --check-prefix=MINGW %s
2
+ ; RUN: llc -mtriple=x86_64-pc-cygwin < %s -o - | FileCheck --check-prefix=MINGW %s
2
3
; RUN: llc -mtriple=x86_64-pc-windows-itanium < %s -o - | FileCheck --check-prefix=MSVC %s
3
4
; RUN: llc -mtriple=x86_64-pc-windows-msvc < %s -o - | FileCheck --check-prefix=MSVC %s
4
5
; RUN: llc -mtriple=i686-w64-mingw32 < %s -o - | FileCheck --check-prefix=MINGW %s
6
+ ; RUN: llc -mtriple=i686-pc-cygwin < %s -o - | FileCheck --check-prefix=MINGW %s
5
7
6
8
declare void @llvm.lifetime.start.p0 (i64 , ptr nocapture )
7
9
declare dso_local void @other (ptr )
Original file line number Diff line number Diff line change 4
4
5
5
; RUN: llvm-windres -### --include-dir %p/incdir1 --include %p/incdir2 "-DFOO1=\\\"foo bar\\\"" -UFOO2 -D FOO3 --preprocessor-arg "-DFOO4=\\\"baz baz\\\"" -DFOO5=\"bar\" %p/Inputs/empty.rc %t.res | FileCheck %s --check-prefix=CHECK1
6
6
; RUN: llvm-windres -### --include-dir %p/incdir1 --include %p/incdir2 "-DFOO1=\"foo bar\"" -UFOO2 -D FOO3 --preprocessor-arg "-DFOO4=\"baz baz\"" "-DFOO5=bar" %p/Inputs/empty.rc %t.res --use-temp-file | FileCheck %s --check-prefix=CHECK1
7
- ; CHECK1: {{^}} "clang" "--driver-mode=gcc" "-target" "{{.*}}-{{.*}}{{mingw32|windows-gnu}}" "-E" "-xc" "-DRC_INVOKED" "-I" "{{.*}}incdir1" "-I" "{{.*}}incdir2" "-D" "FOO1=\"foo bar\"" "-U" "FOO2" "-D" "FOO3" "-DFOO4=\"baz baz\"" "-D" "FOO5=bar" "{{.*}}empty.rc" "-o" "{{.*}}preproc-{{.*}}.rc"{{$}}
7
+ ; CHECK1: {{^}} "clang" "--driver-mode=gcc" "-target" "{{.*}}-{{.*}}{{mingw32|cygwin| windows-gnu|windows-cygnus }}" "-E" "-xc" "-DRC_INVOKED" "-I" "{{.*}}incdir1" "-I" "{{.*}}incdir2" "-D" "FOO1=\"foo bar\"" "-U" "FOO2" "-D" "FOO3" "-DFOO4=\"baz baz\"" "-D" "FOO5=bar" "{{.*}}empty.rc" "-o" "{{.*}}preproc-{{.*}}.rc"{{$}}
8
8
; RUN: llvm-windres -### --preprocessor "i686-w64-mingw32-gcc" --preprocessor-arg -E "-DFOO=\\\"foo bar\\\"" %p/Inputs/empty.rc %t.res | FileCheck %s --check-prefix=CHECK2
9
9
; CHECK2: {{^}} "{{.*}}i686-w64-mingw32-gcc" "-E" "-D" "FOO=\"foo bar\"" "{{.*}}empty.rc" "-o" "{{.*}}preproc-{{.*}}.rc"{{$}}
10
10
13
13
; RUN: rm -rf %t-bin/testbin
14
14
; RUN: mkdir -p %t-bin/testbin
15
15
; RUN: ln -s llvm-windres %t-bin/testbin/i686-w64-mingw32-gcc
16
- ; RUN: env PATH=%t-bin/testbin llvm-windres -### --preprocessor i686-w64-mingw32-gcc --preprocessor-arg -E --preprocessor-arg -xc -DRC_INVOKED %p/Inputs/empty.rc %t.res | FileCheck %s --check-prefix=CHECK3
16
+ ; RUN: env PATH=" %t-bin/testbin:$PATH" llvm-windres -### --preprocessor i686-w64-mingw32-gcc --preprocessor-arg -E --preprocessor-arg -xc -DRC_INVOKED %p/Inputs/empty.rc %t.res | FileCheck %s --check-prefix=CHECK3
17
17
; CHECK3: {{^}} "{{.*}}/testbin/i686-w64-mingw32-gcc" "-E" "-xc" "-D" "RC_INVOKED" "{{.*}}empty.rc" "-o" "{{.*}}preproc-{{.*}}.rc"{{$}}
18
18
19
19
Original file line number Diff line number Diff line change @@ -201,7 +201,7 @@ std::string getMingwTriple() {
201
201
Triple T (sys::getDefaultTargetTriple ());
202
202
if (!isUsableArch (T.getArch ()))
203
203
T.setArch (getDefaultFallbackArch ());
204
- if (T.isWindowsGNUEnvironment ())
204
+ if (T.isOSCygMing ())
205
205
return T.str ();
206
206
// Write out the literal form of the vendor/env here, instead of
207
207
// constructing them with enum values (which end up with them in
You can’t perform that action at this time.
0 commit comments