The board of trustees of any municipal public library, or any group of municipal public libraries, and the board of trustees of any county public library system, may, with the consent of the governing body of said municipality, or municipalities, and with the consent of the board of supervisors of said county, contract with each other or among themselves, to create, maintain and support a joint city-county public library system. Such a contract shall contain such terms, agreements and conditions as may be agreed upon by the board of trustees of the municipal public library, or the public library boards of trustees of the several municipalities, and by the board of trustees of the county public library.