问题
mac OS X has failed to generate a make file and gives me a problem
DOLATs-MacBook-Air:~ dolatsingh$ cd Documents/ardupilot/ArduCopter/
DOLATs-MacBook-Air:ArduCopter dolatsingh$ make apm2
// BUILDROOT=/var/folders/16/slzp9s_s741cb0cgqtcddc_h0000gn/T/ArduCopter.build HAL_BOARD=HAL_BOARD_APM2 HAL_BOARD_SUBTYPE=HAL_BOARD_SUBTYPE_AVR_APM2 TOOLCHAIN=AVR EXTRAFLAGS=-DGIT_VERSION="705d3d56"
%% AP_State.o
**cc1plus: error: unrecognized command line option "-std=gnu++11" make: ***** [/var/folders/16/slzp9s_s741cb0cgqtcddc_h0000gn/T/ArduCopter.build/AP_State.o] Error 1
i have checked GCC version and it's 4.2.1
回答1:
You'll need to upgrade your IDE (if you're using the Arduino IDE).
Since version 1.5.8 of the IDE, GCC has been version 4.8.1. However, you'll need to manually enable it with the command line switch you were using.
If you grab the latest (1.6.2 and above, currently 1.6.9) C++11 is enabled by default.
来源:https://stackoverflow.com/questions/36678263/cc1plus-error-unrecognized-command-line-option-std-gnu11