0
試圖編譯中間層的RENDLER在C++與make all
後,我收到以下錯誤:編譯錯誤隨着中層RENDLER
$ make all
g++ -g -O2 -pthread -o rendler rendler.cpp -lmesos -lpthread -lprotobuf
In file included from /usr/local/include/stout/stringify.hpp:26:0,
from /usr/local/include/stout/bytes.hpp:26,
from /usr/local/include/mesos/resources.hpp:29,
from rendler.cpp:30:
/usr/local/include/stout/hashmap.hpp:43:32: error: expected ‘)’ before ‘<’ token
hashmap(std::initializer_list<std::pair<Key, Value>> list)
^
rendler.cpp:345:1: error: expected ‘}’ at end of input
}
^
In file included from /usr/local/include/stout/stringify.hpp:26:0,
from /usr/local/include/stout/bytes.hpp:26,
from /usr/local/include/mesos/resources.hpp:29,
from rendler.cpp:30:
/usr/local/include/stout/hashmap.hpp:40:14: error: expected unqualified-id at end of input
hashmap() {}
^
make: *** [rendler] Error 1
我都安裝以及在相關的第三方庫列出的依賴關係正確包含路徑。嘗試編譯mesos/src/examples
目錄中的示例框架時收到相同的錯誤。什麼導致了這個錯誤?
你忘了包括'-std = C++ 11' – NathanOliver
修復了它;謝謝。 – atheatos