It has been a while, but if I remember correctly, in Illustrator go to the menu for Object → Path → Outline Stroke.
The point being, you need to convert the stroke defined into paths, then the export will produce shapes that form the dashed lines you’d like.