If you want the 40 hours and treat like a human not a code producing robot I found the best way is to work as a techie for a none-tech company.
I handle the internal ERP and related software (android terminals, sandblast machines etc)
I get to work on varied problems in multiple languages where my contribution is immediately visible and then go home at 5pm.
It's glorious, I'll give up programming as a career rather than go back to 60hr+ weeks.