Here is the simplest yet effective fan mout I could think of. This is meant to cool the heat break , not the print.
It's made for 30mm ones but by scaling and using shims you should be able to use a 40mm one.