The county commissioners of any two or more counties may join in establishing a joint industrial farm and workhouse for the confinement of:
(1) Persons sentenced by the courts of those counties, after conviction, of any misdemeanor or felony, except murder, voluntary manslaughter, rape and arson.
(2) Persons who are in default of payment of any fine or penalty, or for nonpayment of costs, or for default in complying with any order of court entered in any prosecution for desertion or nonsupport, or for the violation of any municipal ordinance.