jkuhlmann / gainput

Cross-platform C++ input library supporting gamepads, keyboard, mouse, touch
http://gainput.johanneskuhlmann.de/
MIT License
858 stars 103 forks source link

Make Error on Ubuntu #52

Closed ThybeVB closed 6 years ago

ThybeVB commented 6 years ago

Hey! I have an error when running the make command in the build folder. I get an error that I should use C++ 11, But i'm unsure how to do this, I read you do it in the Makefile, but how?

from /home/thybe/Desktop/gainput/lib/source/gainput/GainputAllocator.cpp:2:
/usr/include/c++/7/bits/c++0x_warning.h:32:2: error: #error This file requires compiler and library support for the ISO C++ 2011 standard. This support must be enabled with the -std=c++11 or -std=gnu++11 compiler options.
 #error This file requires compiler and library support \

screenshot from 2018-03-14 19-30-29

RicoP commented 6 years ago

Do you build it using make or cmake?

ThybeVB commented 6 years ago

I started by cmake .. and followed up with make, Like the README says

RicoP commented 6 years ago

make sure you have a recent version of gcc and clang installed

ThybeVB commented 6 years ago

Ubuntu Version: 17.10 GCC Version: 7.2.0 Clang Version: 4.0.1-6

I'm pretty sure all of these are up to date.

jkuhlmann commented 6 years ago

Hi,

I'll admit that I find this error message a bit confusing. It complains that gainput.h includes cstdint on line 8. But this doesn't seem to be the case, at least not in the last version. Can you confirm that this also the case for you?

Cheers,

Johannes

ThybeVB commented 6 years ago

Hey! I checked out my version of gainput.h. Turns out it actually does include . I then looked at the code on GitHub, and it's not there. So as you said i'm using an outdated version. I will now clone the latest version and see how it goes.

Thanks in advance!

ThybeVB commented 6 years ago

Using the latest version of the repository fixed the problem. FYI i was using the 1.0.0 release before. Maybe you can make another release with the current version, as people usually resort the the Releases tab. Thanks alot! :+1:

jkuhlmann commented 6 years ago

Awesome, that's good to hear. You're right. I should do another release. Thank you!