It's all matter of mindset, changing work and challenges often, learning something new and stay away from all non-core discussions, specially politics.
But the reason I got into this wasn't because I had some idealistic reason behind it. I got into this because it provides a job that gives you the salary, mobility, and time to yourself that lets you do anything you want when you walk out of the office.
I love my job, I like doing software development, but for me it's never been about the ideals behind it. It's always been about what being a developer lets me do with my life.
Looking at it that way, there's really nothing to be disillusioned by.