On Mon, Aug 22, 2016 at 04:12:33PM -0700, Peter Snyder wrote:
> Hi there,
>
> I just got a new MacBook and needed to install the Mynewt toolchain.
> The native gcc version installed by brew has recently changed
> requiring that a yml configuration file in the newt source tree be
> changed as well as reporting some minor compilation errors that cause
> sim (native mac) builds to fail. This only affects new toolchain
> installs, there are no issues with existing installs.
[...]
Thanks for the heads up, Peter. There is an alternative solution:
just use OS X's native "gcc" (clang). I just did a quick test, and
aside from a few warnings that clang reports, everything works. Here is
what I tried:
* newt test all
* newt build blinky_sim
* execute blinky_sim
It's quite irritating that Apple named their clang executable "gcc", but
maybe it's time to stop fighting it.
One issue with this solution is that it means OS X sim builds would use
a different compiler from firmware builds. I am not sure how big of a
problem this is, so I'll let others weigh in. In the meantime, I'll
commit some fixes for the warnings that clang helpfully generated.
Chris