Sayyiduna Abu Ayyub (may Allah be pleased with him) said: The Messenger of Allah (peace and blessings be upon him) forbade the one going to relieve himself from facing the qiblah, and he said: "Turn towards the east or the west."
Hadith Referenceالمعجم الكبير للطبراني / باب الخاء / 3925