(1) For purposes of this section, “farm structure” means a structure that is constructed on a farm, other than a residence or a structure attached to it, for use on the farm, including, but not limited to, barns, sheds and poultry houses, but not public livestock areas. For purposes of this section, “farm structure” does not include a structure originally qualifying as a “farm structure” but later converted to another use.
(2) The governing body of a county or municipality shall not enforce that portion of any building code established and/or imposed under Sections 17-2-1 through 17-2-5 that regulates the construction or improvement of a farm structure.
(3) The provisions of this section do not apply unless, before constructing or improving a farm structure, the person owning the property on which the structure is to be constructed files an affidavit with the county or municipal official responsible for enforcing the building code stating that the structure is being constructed as a farm structure. The affidavit must include a statement of purpose or intended use of the proposed structure or addition.
(4) This section does not affect the authority of the governing body of a county or municipality to issue building permits before an affidavit for the construction or improvement of a farm structure is filed under subsection (3) of this section.
(5) The provisions of this section shall not apply to any floodplain management ordinances or regulations necessary for eligibility for the National Flood Insurance Program, and such floodplain management ordinances or regulations shall apply retroactively to any construction or improvement permit granted for any structure exempted under this section before May 22, 2012.