Currently, your best option may be to always have those extra bones, animate a "generic form" of each weapon type, and put the images of that weapon into Skins so they are not visible by default, and so you can replace them by making a custom skin at runtime. Use the visibility dot in the tree to make unused bones invisible in your viewport.
Then at runtime, swap the skins out, or create modified skins out of the generic forms to make more custom weapons.
Beyond that, this is something you have to test and figure out for yourself to know if the system works for you both in code and in workflow.
This will of course get really messy if your custom weapons have lots of extra unique bones and movements, or you have a LOT of base weapon types.