Gluing gravitational blocks for AdS black holes