diff options
author | Jisi Liu <jisi.liu@gmail.com> | 2017-08-11 12:08:00 -0700 |
---|---|---|
committer | Jisi Liu <jisi.liu@gmail.com> | 2017-08-11 12:08:00 -0700 |
commit | 564f02c91ec0e983806762de4b842a762e21bb47 (patch) | |
tree | 52a4a64303c8426f487f08624e5059b977b078cc /src/google/protobuf/stubs/io_win32.cc | |
parent | 7afa796bb914c911cc3d40aeeba1ce63b2f83f99 (diff) | |
download | protobuf-564f02c91ec0e983806762de4b842a762e21bb47.tar.gz protobuf-564f02c91ec0e983806762de4b842a762e21bb47.tar.bz2 protobuf-564f02c91ec0e983806762de4b842a762e21bb47.zip |
Make win32_io only for MSVC
This excludes cygwin and mingw from using the self implemented
functions.
Diffstat (limited to 'src/google/protobuf/stubs/io_win32.cc')
-rw-r--r-- | src/google/protobuf/stubs/io_win32.cc | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/google/protobuf/stubs/io_win32.cc b/src/google/protobuf/stubs/io_win32.cc index 25f672cc..d1ad6761 100644 --- a/src/google/protobuf/stubs/io_win32.cc +++ b/src/google/protobuf/stubs/io_win32.cc @@ -39,15 +39,13 @@ // // This file is only used on Windows, it's empty on other platforms. -#if defined(_WIN32) +#if defined(_MSC_VER) // Comment this out to fall back to using the ANSI versions (open, mkdir, ...) // instead of the Unicode ones (_wopen, _wmkdir, ...). Doing so can be useful to // debug failing tests if that's caused by the long path support. // Long path support is disabled in MinGW -#ifndef __MINGW32__ #define SUPPORT_LONGPATHS -#endif // !__MINGW32__ #include <ctype.h> #include <direct.h> @@ -361,5 +359,5 @@ wstring testonly_path_to_winpath(const string& path) { } // namespace protobuf } // namespace google -#endif // defined(_WIN32) +#endif // defined(_MSC_VER) |