Browse Source

Fix msvc detection + prevent range library from pulling in boost::regex

nemerle 3 years ago
parent
commit
1df7cb3be4
7 changed files with 7 additions and 7 deletions
  1. 1 1
      CMakeLists.txt
  2. 1 1
      src/BasicBlock.cpp
  3. 1 1
      src/RegisterNode.cpp
  4. 1 1
      src/ast.cpp
  5. 1 1
      src/backend.cpp
  6. 2 1
      src/dataflow.cpp
  7. 0 1
      src/graph.cpp

+ 1 - 1
CMakeLists.txt

@@ -7,7 +7,7 @@ find_package(Qt5Core)
 OPTION(dcc_build_tests "Enable unit tests." OFF)
 #SET(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR})
 ADD_DEFINITIONS(-D_CRT_SECURE_NO_WARNINGS -D__UNIX__ -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS)
-IF(CMAKE_BUILD_TOOL MATCHES "(msdev|devenv|nmake)")
+IF("${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC")
     ADD_DEFINITIONS(-D_CRT_SECURE_NO_WARNINGS -D__UNIX__ -D_CRT_NONSTDC_NO_DEPRECATE -DNOMINMAX)
     ADD_DEFINITIONS(/W4)
 ELSE()

+ 1 - 1
src/BasicBlock.cpp

@@ -10,7 +10,7 @@
 #include <string>
 #include <boost/range/rbegin.hpp>
 #include <boost/range/rend.hpp>
-#include <boost/range/adaptors.hpp>
+
 using namespace std;
 using namespace boost;
 

+ 1 - 1
src/RegisterNode.cpp

@@ -10,8 +10,8 @@
 #include <sstream>
 #include <iostream>
 #include <cassert>
+#include <boost/range/adaptor/filtered.hpp>
 #include <boost/range.hpp>
-#include <boost/range/adaptors.hpp>
 //#include <boost/range/algorithm.hpp>
 //#include <boost/assign.hpp>
 

+ 1 - 1
src/ast.cpp

@@ -14,7 +14,7 @@
 
 #include <QtCore/QTextStream>
 #include <boost/range.hpp>
-#include <boost/range/adaptors.hpp>
+#include <boost/range/adaptor/filtered.hpp>
 #include <boost/range/algorithm.hpp>
 #include <boost/assign.hpp>
 #include <stdint.h>

+ 1 - 1
src/backend.cpp

@@ -17,7 +17,7 @@
 #include <cassert>
 #include <string>
 #include <boost/range.hpp>
-#include <boost/range/adaptors.hpp>
+#include <boost/range/adaptor/filtered.hpp>
 #include <boost/range/algorithm.hpp>
 
 #include <fstream>

+ 2 - 1
src/dataflow.cpp

@@ -10,7 +10,8 @@
 #include "msvc_fixes.h"
 
 #include <boost/range.hpp>
-#include <boost/range/adaptors.hpp>
+#include <boost/range/adaptor/filtered.hpp>
+#include <boost/range/adaptor/reversed.hpp>
 #include <boost/range/algorithm.hpp>
 #include <boost/assign.hpp>
 #include <stdint.h>

+ 0 - 1
src/graph.cpp

@@ -11,7 +11,6 @@
 
 #include <boost/range/rbegin.hpp>
 #include <boost/range/rend.hpp>
-#include <boost/range/adaptors.hpp>
 #include <string.h>
 
 using namespace std;