diff options
author | Jan Tattermusch <jtattermusch@google.com> | 2017-08-25 12:59:11 +0200 |
---|---|---|
committer | Jan Tattermusch <jtattermusch@google.com> | 2017-09-11 11:03:05 +0200 |
commit | 4caadb9205bcb9f745cda2e3c310b27837cfd636 (patch) | |
tree | ffe08d8773bb09166d09b672455c3a832d3ae772 /examples/cpp | |
parent | 5a2a792509af457322b8fc63eff3ec1ee360b0a0 (diff) |
fix helloworld cmake build
Diffstat (limited to 'examples/cpp')
-rw-r--r-- | examples/cpp/helloworld/CMakeLists.txt | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/examples/cpp/helloworld/CMakeLists.txt b/examples/cpp/helloworld/CMakeLists.txt index 8f098c91a6..71a8db4f24 100644 --- a/examples/cpp/helloworld/CMakeLists.txt +++ b/examples/cpp/helloworld/CMakeLists.txt @@ -2,7 +2,11 @@ cmake_minimum_required(VERSION 2.8)
# Project
-project(HelloWorld CXX)
+project(HelloWorld C CXX)
+
+if(NOT MSVC)
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
+endif()
# Protobuf
set(protobuf_MODULE_COMPATIBLE TRUE)
|