diff options
author | Roger Meier <roger@apache.org> | 2015-05-15 12:01:38 +0200 |
---|---|---|
committer | Roger Meier <roger@apache.org> | 2015-05-15 15:44:22 +0200 |
commit | 86fded21b55573bb9240552a284f1f3d7255bd32 (patch) | |
tree | 6b7f0184cde4350fd73ca41c16940e9d792d58c4 /compiler/cpp/CMakeLists.txt | |
parent | 516e28a42d481725156d3d521d453c55b1dfd992 (diff) | |
download | thrift-86fded21b55573bb9240552a284f1f3d7255bd32.tar.gz |
THRIFT-2850 CMake: improve Windows support
use YY_NO_UNISTD_H and remove --wincompat
Diffstat (limited to 'compiler/cpp/CMakeLists.txt')
-rw-r--r-- | compiler/cpp/CMakeLists.txt | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/compiler/cpp/CMakeLists.txt b/compiler/cpp/CMakeLists.txt index 5642d16bf..01e229d81 100644 --- a/compiler/cpp/CMakeLists.txt +++ b/compiler/cpp/CMakeLists.txt @@ -19,10 +19,8 @@ # Windows has a different header if(MSVC) - set(FLEX_FLAGS "--wincompat") # Don't use unistd.h on windows configure_file(${CMAKE_CURRENT_SOURCE_DIR}/src/windows/version.h.in ${CMAKE_CURRENT_BINARY_DIR}/version.h) else() - set(FLEX_FLAGS " ") configure_file(${CMAKE_CURRENT_SOURCE_DIR}/version.h.in ${CMAKE_CURRENT_BINARY_DIR}/version.h) endif() @@ -31,7 +29,7 @@ find_package(BISON REQUIRED) # Create flex and bison files and build the lib parse static library BISON_TARGET(thrifty ${CMAKE_CURRENT_SOURCE_DIR}/src/thrifty.yy ${CMAKE_CURRENT_BINARY_DIR}/thrifty.cc) -FLEX_TARGET(thriftl ${CMAKE_CURRENT_SOURCE_DIR}/src/thriftl.ll ${CMAKE_CURRENT_BINARY_DIR}/thriftl.cc COMPILE_FLAGS ${FLEX_FLAGS}) +FLEX_TARGET(thriftl ${CMAKE_CURRENT_SOURCE_DIR}/src/thriftl.ll ${CMAKE_CURRENT_BINARY_DIR}/thriftl.cc) ADD_FLEX_BISON_DEPENDENCY(thriftl thrifty) # HACK: Work around the fact that bison crates a .hh file but we need a .h file |