A variational formulation of the coupled thermo-mechanical boundary-value problem for general dissipative solids