Functional planned obsolescence. Hardware vendors will find a way to break hardware abstraction layers... so they can sell more hardware. Its the business model.
The Nexus 4 still works, but its battery is puffing out.
The Nexus S has no hardware problems at all, but it's too underpowered to run modern software.
The model "phone vendors nefariously build products with short lifespans, regardless of what people want to buy, so that they can sell more hardware" has trouble explaining why the longest-lived phones are the earliest ones. It seems more likely that the phone vendors of today build phones with short lifespans because bitter experience tells them that building a robust, long-lived phone is all cost and no benefit -- the phone costs more, it's heavier, it's fatter, and all your customers replace it before the cheaper, sleeker, more attractive phone would have failed anyway, meaning they actually get zero minutes of extended lifespan.
> The model "phone vendors nefariously build products with short lifespans, regardless of what people want to buy, so that they can sell more hardware" has trouble explaining why the longest-lived phones are the earliest ones.
Maybe because first you try to make your earlier products good to get customers, and then once your business is going and you've grabbed a portion of the market you find it profitable to take risks like this?
This doesn't make any sense. It assumes there's no competition between manufacturers, and that users don't switch. If older phones were actually "better", manufacturers would just make those and steal customers from anyone making the newer devices.
The phones of today aren't "built with shorter lifespans in mind", but they are built with more tightly packed components, more energy-dense batteries (to support their power-hungry CPUs and large amount of RAM), etc. Because that's what you need to do so you're not "too underpowered to run modern software." Which is necessary to sell phones to people.
If you made a phone and said "hey, this will live as long as a Nexus S, but it's not going to run FB or Clash of Clans or VR or take very good pictures (HDR is compute intensive)".... good luck selling that.
The Nexus S appears to be immortal. That means that when young, it was terrible (by modern standards), and now that it's old, it's still terrible, but no worse.
The Nexus 5 is mortal. When young, it is good. When old, it is even worse than an old Nexus S. Just like an animal, it's strong in youth and decrepit in age.