A related question. Not an exact duplicate, because there it was assumed that $B$ is invertible. Studying the answers given there will get you started anyway (more or less along the lines of Matt Pressland's +1 answer).
–
Jyrki Lahtonen♦Dec 19 '12 at 14:10

@sun Nope, although that would also be a good question to ask. Answering the question I asked should lead to an answer to your suggested modification, if I've understood correctly.
–
Matthew PresslandDec 19 '12 at 13:59