I'd ask around to find the owners. Maybe that was his house and his family moved away and left him. Or maybe he is a community cat and is welcome in other homes like that.
But yes, cats do know who loves them.