Harish-Chandra modules over generalized Heisenberg-Virasoro algebras