/usr/include/boost/property_tree/detail/json_parser_read.hpp:257:264: error: ‘type name’ declared as function returning an array
方法:因为gcc版本太低了,升级到5.3即可解决
- sudo add-apt-repository ppa:ubuntu-toolchain-r/test
- sudo apt-get update
- #如果提示未安装,还需要先安装它的包:
- sudo apt-get install software-properties-common
- sudo apt-get install gcc-5 g++-5
- cd /usr/bin
- sudo rm gcc
- sudo ln -s gcc-5 gcc
- sudo rm g++
- sudo ln -s g++-5 g++
重新编译即可解决