Where such county and such city shall unite in the construction and maintenance of a jail, or in the purchase of land for farm or other purposes and erect public buildings thereon, the sheriff of such county or such other person as may be charged with the administrative direction of the jail and the chief police officer of such city shall jointly conduct and manage said jail for the detention of prisoners and said land for the employment of prisoners, except as otherwise provided by agreement between such county and city; Provided, where any such county or any such city shall build such jail or purchase such land independently of the other, such county or such city as does not own or manage a jail for the detention of prisoners, or land for the employment of prisoners, shall have the right to contract with the other for its use, with payment made as provided in any such contract.
Neb. Rev. Stat. §§ 47-306