Skip to content

Commit

Permalink
Merge pull request #33 from LogicalKnight/msvc-cmake-c++11-fix
Browse files Browse the repository at this point in the history
Don't use C++11/14 flags when compiling with MSVC
  • Loading branch information
jaredgrubb committed Nov 26, 2015
2 parents a6d4652 + b40325d commit af1e5c8
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,12 @@ if(WITH_STATIC)
endif()
add_library(docopt SHARED ${DOCOPT_SRC})

if(WITH_CPP14)
add_definitions("-std=c++14")
elseif(WITH_CPP11)
add_definitions("-std=c++11")
if (NOT MSVC)
if(WITH_CPP14)
add_definitions("-std=c++14")
elseif(WITH_CPP11)
add_definitions("-std=c++11")
endif()
endif()

########################################################################
Expand Down

0 comments on commit af1e5c8

Please sign in to comment.