Эх сурвалжийг харах

add `-std=c++11` to make it compile

make cpp won't compile since it requires `-std=c++11` com
Zhao Junwang 5 жил өмнө
parent
commit
c562c93ad6
1 өөрчлөгдсөн 2 нэмэгдсэн , 2 устгасан
  1. 2 2
      examples/Makefile

+ 2 - 2
examples/Makefile

@@ -41,11 +41,11 @@ protoc_middleman_dart: addressbook.proto
 
 add_person_cpp: add_person.cc protoc_middleman
 	pkg-config --cflags protobuf  # fails if protobuf is not installed
-	c++ add_person.cc addressbook.pb.cc -o add_person_cpp `pkg-config --cflags --libs protobuf`
+	c++ -std=c++11 add_person.cc addressbook.pb.cc -o add_person_cpp `pkg-config --cflags --libs protobuf`
 
 list_people_cpp: list_people.cc protoc_middleman
 	pkg-config --cflags protobuf  # fails if protobuf is not installed
-	c++ list_people.cc addressbook.pb.cc -o list_people_cpp `pkg-config --cflags --libs protobuf`
+	c++ -std=c++11 list_people.cc addressbook.pb.cc -o list_people_cpp `pkg-config --cflags --libs protobuf`
 
 add_person_dart: add_person.dart protoc_middleman_dart