REQUIRING ALL CITIZENS to buy a gun would, if passed at the Federal level, meet constitutional muster, given that Article 1, Section 8 includes the following:
To provide for organizing, arming, and disciplining, the Militia, and for governing such Part of them as may be employed in the Service of the United States, reserving to the States respectively, the Appointment of the Officers, and the Authority of training the Militia according to the discipline prescribed by Congress;
What the South Dakotans are doing is right in line with the definition of a militia by 18th Century terms. (Remember that the Constitution predates the advent of professional police services by one or two years.)
And, in fact, that Congress as a body can be anticipated to resist such a move can be seen as a strong indictment of the un-American character of some of its members.