I have looked but I can't find it for you, but what you need is an SDL utility called "controllermap". You may even need to compile it from source for macOS.
Once you have controllermap, you can run it and map your buttons using the built-in utility. This will generate a controller definition that looks something like this:
030000004c050000c405000011810000,Sony Computer Entertainment Wireless Controller,platform:Linux,x:b3,a:b0,b:b1,y:b2,back:b8,guide:b10,start:b9,dpleft:h0.8,dpdown:h0.0,dpdown:h0.4,d pright:h0.0,dpright:h0.2,dpup:h0.0,dpup:h0.1,leftshoulder:h0.0,leftshoulder:b4,lefttrigger:a2,rightshoulder:b6 ,rightshoulder:b5,righttrigger:a5,leftstick:b7,leftstick:b11,rightstick:b12,leftx:a0,lefty:a1,rightx:a3,righty :a4,
030000004c050000c405000011810000,Sony Computer Entertainment Wireless Controller,platform:Linux,x:b3,a:b0,b:b1,y:b2,back:b8,guide:b10,start:b9,dpleft:h0.8,dpdown:h0.0,dpdown:h0.4,d pright:h0.0,dpright:h0.2,dpup:h0.0,dpup:h0.1,leftshoulder:h0.0,leftshoulder:b4,lefttrigger:a2,rightshoulder:b6 ,rightshoulder:b5,righttrigger:a5,leftstick:b7,leftstick:b11,rightstick:b12,leftx:a0,lefty:a1,rightx:a3,righty :a4,
Once you have your definition, you need to create a "gamecontrollerdb.txt" file in your "game/assets" directory. Paste your definition in there and save the file. HyperLightDrifter should then detect your controller.
As I said, I have looked around for a controllermap app for macOS (I use Linux and the package is precompiled) but I couldn't find one for you. Good hunting.