@nodles91 I really don't let my dogs choose their food. If it is good quality, I get it. Most dogs really won't starve, they will eat what you have. Honestly, I wouldn't work on a food change while dealing with the pottying issue, just cut him down to two set meals a day. He may go hungry a few meals but then he will learn to eat on schedule. That should help control when he has to potty. He shouldn't need to potty more than once or twice a day.
Then, I would use the match stick method. outside, in your yard in a spot you want him to go. A gal told me instead, she uses wax birthday candles or small Shabbat ones, clear/white, instead. I hadn't thought of it, but that would work great. While there are a few "I don't care, my feet are wet"... biologically most cannot resist the urge to push it out and with it poop. When he poops, instant praise, then a short walk for reward.
Putting a belly band usually is to stop marking, but it has the advantage of making peeing in the house a "self anointing" thing. While getting him to mark to empty his bladder (and hollow leg) works, again you'll be using your life up with it. Put a little flavoring in his water, like chicken stock, to get him to drink a LOT so he has to go. Go out often, sing his praise when he pees, not marking. Reward with a great (but small) treat.. like a small bite of actual meat.
But also, get him tested for a UTI or any issues, even thyroid. Make sure you aren't working uphill against a medical problem. It doesn't sound medical, but it's always good to be sure.