Well I never considered needing to change stuff.
If you had a reasonable concept of if it was a large or small auto or revolver, you could make a proper sized hole and go with some foam and felt for a generic fit.
Example, I have glocks. So 9mm and all other small framed stuff has different length butts, but all same dimensions other than that. And the large frames are the same as well, so I could make a hole to fit all 10mm or 45acp glocks, except the funky 36.
1911 types are roughly close in size.
My ruger revolvers are close as well, redhawks and even super blackhawk could wind up in same hole with right amount of padding covered with felt.
I often go to home depot and look around, you might look at some of the systems mechanics use for holding tools in tool boxes as sometimes they roll the box around everything needs to remain in place.
I also have to say fabric stores often give me ideas, I love being able to just buy a roll of fabric and make something that looks like it cost a few hundred bucks. This is for lining cabinets and stuff to cover the cheap plywood or whatever I used to make it. Good wood is expensive.
Just rambling and tossing ideas.