Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

C++11 Flags #7

Closed
fabolhak opened this issue Oct 6, 2017 · 2 comments
Closed

C++11 Flags #7

fabolhak opened this issue Oct 6, 2017 · 2 comments

Comments

@fabolhak
Copy link

fabolhak commented Oct 6, 2017

Hello,
thank you for the great tool. It is pretty cool :). However I have problems building it on my Ubuntu 16.04. machine because is is not compiling with C++11 by default (a lot of warnings coming up). Is there any compiler flag I have to configure? :)

@fabolhak fabolhak changed the title Segfault when connecting to VESC C++ Flags Oct 6, 2017
@fabolhak fabolhak changed the title C++ Flags C++11 Flags Oct 6, 2017
@fabolhak
Copy link
Author

fabolhak commented Oct 6, 2017

I got it compiling correctly by adding CONFIG += c++11 to the vesc_tool.pro file :)

@rewolff
Copy link

rewolff commented Nov 8, 2017

It compiles without any additions. However, the warning:

vescinterface.h:132:27: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11
     bool mSendCanBefore = false;

indicates to me that it is ignoring the intializer! As, in this case, it is likely that the "false" turns into zero anyway, chances are that it will still work. But with hundreds of these warnings, it is entirely possible that a non-zero initializer is required somewhere....

In fact, the compiled binary (with the warnings) locks up quite quickly in my case, Not sure what the cause is, but I'm going to try adding the C++11....

Update: The C++11 compiled version crashes (segmentation fault) when I click on "connect".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants