HID device communication

I’ve written some code for a Teensy which allows communcation with an HID device for the display of a MIDI controller. I’m thinking about porting this code to a module for Rack.
Has anyone done a Makefile for building/linking the necessary dependencies for making the API available within a module?