The governing bodies of the cities of this state are hereby empowered and authorized to enter into a contract with the county commissioners of the county in which such city is located for the purpose of erecting, maintaining or operating a building to be used for a city hall and courthouse purpose or for a county and city jail or either or both of them, upon such terms or conditions as may be agreed upon between the two contracting bodies.
Okla. Stat. tit. 19, § 751