Added buildShapefileSelection function