erincatto / box2d

Box2D is a 2D physics engine for games
https://box2d.org
MIT License
8.09k stars 1.52k forks source link

2.4.0: error: no member named 'linjs' in 'struct _GLFWjoystick' #644

Closed yurivict closed 3 years ago

yurivict commented 4 years ago
/usr/ports/misc/box2d/work/box2d-2.4.0/extern/glfw/src/linux_joystick.c:51:34: error: no member named 'linjs' in 'struct _GLFWjoystick'
                             js->linjs.keyMap[code - BTN_MISC],
                             ~~  ^
/usr/ports/misc/box2d/work/box2d-2.4.0/extern/glfw/src/linux_joystick.c:51:54: error: use of undeclared identifier 'BTN_MISC'
                             js->linjs.keyMap[code - BTN_MISC],
                                                     ^
/usr/ports/misc/box2d/work/box2d-2.4.0/extern/glfw/src/linux_joystick.c:59:27: error: no member named 'linjs' in 'struct _GLFWjoystick'
    const int index = js->linjs.absMap[code];
                      ~~  ^

OS: FreeBSD 12.1

erincatto commented 3 years ago

It is defined here: https://github.com/erincatto/box2d/blob/e6a8a5df00bdc7a69bea9ed072b120cc3341190e/extern/glfw/src/linux_joystick.h#L31 I don't run Linux so you will have to debug it yourself. If you find a fix needed in Box2D, please reopen this issue.