cmake: link the libImap.a with the QtSql explicitly

This will hopefully fix the breakage of travis builds.