updates to fix make_ndx bugs, pass mainselection to eq and md setups