Next-to-Leading Order QCD Corrections to Inclusive Heavy-Flavor Production in Polarized Deep-Inelastic Scattering