I guess there are different types of "life sucks" that can or cannot contribute to depression, my current understanding is that a lot of it depends on whether you feel you have some control over the situation or if you think you have absolutely no power over it
Isn't people in the past had less control? There were dying from infections and not only had no vaccines and drugs they didn't understand how infections are spread. They also suffered from various natural disasters not having a protection a modern civilization gives us.
According to Victor Frankl (psychiatrist concentration camp survivor, author of Man's Search for Meaning) being in a shitty situation without any control over it isn't necessarily bad. Humans can still be mentally okay in the face of extreme unavoidable suffering like in the camps. The key thing is that you need to have some purpose / meaning in life (often a loved one or dependent).