I am all for personal accountability, as I believe we all really are the captains of our own success.
But those are some real issues. A boss that gives mixed signals is never fun, and would upset me. I would probably find alternative employment. If that is not feasible, I would (very nicely) point out his contradicting instructions. That's just bad management.
As for your coworker, you should just confront him about his behaviour. He already hates you. At least if you confront him he will respect you a bit.
You can either choose action, or decide let the status quo carry on. Your boss being **** is something that you may never be able to change. But your coworker who is undermining you should really be dealt with. Don't be afraid of confrontation and standing up for yourself.
I like what @Emjay said. Just remember, there is HR if you need to put in a grievance against somebody.
In situations like this, I remain calm by telling myself that neither myself nor the surrounding people are in control. Nobody is in control at any point in time. We all only live under the illusion of control and decision. The universe and every being in it is governed by the laws of cause and effect (See: Determinism. 9 times out of 10 you aren't even remotely the cause of a situation going sour but usually people (yourself included) tend to get in the firing line.
In any case, one day your boss and your co-worker is going to die. I take solace in knowing they will not gain any sort of post-death "eternal life" etc etc, but then again, nor do any of us
HR departments are there for the company's interests, and not for the employee. Always approach HR with only the most serious issues. And always, always, keep a detailed record of what is going on, with follow up emails backed up off your company equipment.
So yes we all have these annoying experiences and no work place is without these people who have their quirks.However, how i react to it is entirely within my control. And with attention being the main driver of our daily lives its easy to lose perspective, and then focus all attention on the 2 people and creating bad karma by thinking negative thoughts towards them and even posting online about them.
Surely the answer is to first fix myself and train my mind to shift attention away and give my awareness more room to play. This should allow for more mindfulness. And by mindfullness i mean keeping in mind why they might be reacting the way they do, so that i can rather empathize with them, instead of becoming them.
Both situations you landed up dealing with ego's , the boss's due his feeling of self importance and your co-workers due to his embarrasment.
It has nothing to do with empathy, but about learning to read peoples ego's.
Once you manage to do that, getting a positive response is fairly easy.
Office politics , while tedious, is game of ego. Stroke the ego's and your time spent there will be less stressfull.
You dont have to live with them, you dont have to socialise with them, you dont even have to like them, but the occasional bit of feigned interest in your co-workers petty little lives or interests goes a long way towards maintaining a peaceful work environment.