Rocking response of rigid blocks subjected to ground motion