Using your main engine and it's alternator to charge RV batteries occasionally when solar won't provide enough, is good advice if your main engine idles quiet and smooth.
You can fuel an idling main engine an awful long time - total hours for many battery charges - for what you might pay up-front for a generator that you only use here and there over the same long time.
We once had a superb Chinook Class C motorhome that came with no solar or generator. It was intended by design that we idle the main (GMC 350 V8) here and there to charge it's coach battery.