The standard approach is to create a synthetic aka adjusted price series. Usually this is done by backwards adjusting prices of older contracts to align with newer ones. This price series then mimics the price of a trading strategy. You can then create a series of returns based on this strategy. Exactly how to do the adjustments (mostly it's just a straight delta plus / minus for each contract expiry roll) is the topic of research, but bloomberg et al can give you pretty decent series directly (eg, "RX1 comdty", etc).
Exactly what the denominator for the returns calc is also kinda up to you, given the leveraged / cash paradigm of futures. Just using the notional is a weak approach though, as it's not easily comparable across contracts. Some measure of delivered risk is better. How you calculate that, is again up to you.