Adding support for 3rd party remote controller

Do we have to rebuild the entire Android image if we want to add support for 3rd party remote controllers?

I would like to try to use the old MXQ Pro remote controllers on the Khadas VIM.
This remote

What do we need to do?

Which version of your rom ? Mmallow or Nougat ?

I have the exact same IR controller and it does not work out the box. As soon as my device is recognised I will post my findings with this remote

Currently using marshmallow. I havent updated yet to Nougat.
Do you know if it would work with nougat?

About the Remote, You can look this