Update November 2025: I updated my controller-ps4.cfg below, as the button assignments changed over time, maybe through an SDL update. Otherwise, everything should still be valid as back in 2018 :-).
Update December 2018: First thing to do is to test whether your joystick is fully functional under MacOS. The easiest way to do is to use an
online Gamepad Tester like this one:
http://html5gamepad.com/
This gives you a basic understanding of whether your gamepad works in your OS or not. In the case of the PS4 controller, for example, everything shows up under Safari (Google Chrome misses out on the PS Button as B12), which gives you a good first feeling that this joypad should work in MacOS software.
Second, if it works, you have two choices:
1. Leave it as is: My first joypad, for example was a
Logitech F310 Gamepad, a good choice. Switched on the backside to
Direct Input, it runs out of the box in QMC2. No drivers under MacOSX required.
Update November 2016: Since the
X Input mode emulates XBox controllers, I gave
this XBox driver from Github a try - and
it works! The immediate advantage is that all things are configurable in the MacOS System Settings, and RetroArch automatically assigns the joypad to XBox configuration, which is nice. Further insights will follow, but that's a good thing.
It is fully compatible with MacOS Sierra.
As a second joypad, I went for a
PS4 controller, and this thing rocks, both on USB and Bluetooth. No additional drivers required. Build quality is superb, this is a clear recommendation. It is still my favorite joypad for MAME.
Read further for MAME Joystick settings...