have you tried the following three-part post (I don't know if bare metal suits your need - does not require X server):
A pre-built Qt 5.2.1 is provided there (check at the top of the second post)
I know it's not exactly Debian but steps should be the same for Ubuntu.
I was trying to compile Qt 4.8.5 because I couldn't find a package for the BBB. Using make, I ran across a number of errors during the build process. Each time the make results in different errors. I have been following these instructions for compiling Qt4 on the bbb. Is a compiled module available? Later, I may want to rebuild for a minimal Xorg.
The host computer is running OS X (Mavericks). If I need to cross-compile, is there a good guide?