Pull the front roof surface back so it is behind the wall (i.e. the orange line in your last image).
Ensure the side of the slab tough the back surface of the wall.
Now click on the front edge of the roof and use the 'Add to Area' option in the pet palette and magic wand in the space between the front of the roof and the back of the wall.
The roof should now extend to the back of the wall no matter what shape it is.
Barry.
One of the forum moderators.
Versions 6.5 to 27
i7-10700 @ 2.9Ghz, 32GB ram, GeForce RTX 2060 (6GB), Windows 10
Lenovo Thinkpad - i7-1270P 2.20 GHz, 32GB RAM, Nvidia T550, Windows 11